# Link time error for System::getCPUUsage on v2.02.19

**URL:** https://qa.fmod.com/t/link-time-error-for-system-getcpuusage-on-v2-02-19/20979
**Category:** FMOD Engine
**Tags:** ios, cpp
**Created:** [December 11, 2023, 9:07pm UTC](https://qa.fmod.com/t/link-time-error-for-system-getcpuusage-on-v2-02-19/20979 "2023-12-11T21:07:30Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![ChristopheBronner](https://avatars.discourse-cdn.com/v4/letter/c/7bcc69/32.png) [@ChristopheBronner](https://qa.fmod.com/u/ChristopheBronner)
#### Post date: [December 11, 2023, 9:07pm UTC](https://qa.fmod.com/t/link-time-error-for-system-getcpuusage-on-v2-02-19/20979/1 "2023-12-11T21:07:30Z")

</div>

Referencing `FMOD::System::getCPUUsage(FMOD_CPU_USAGE*)` fails with a link-time error. Building for iOS 17.0.1 using Xcode 15. Note that we are using it so I can’t just comment it out of the header.

I’m using an XCFramework packing the core libs. Both `libfmod_iphoneos.a` and `libfmod_iphonesimulator.a`.

There’s a similar post but its from `2.01.04` C# and was said to be fixed on the next update.

---

<div class="post-metadata">

### Author: ![jeff\_fmod](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/jeff_fmod/32/1766_2.png) [@jeff\_fmod](https://qa.fmod.com/u/jeff_fmod)
#### Post date: [December 14, 2023, 11:34pm UTC](https://qa.fmod.com/t/link-time-error-for-system-getcpuusage-on-v2-02-19/20979/2 "2023-12-14T23:34:46Z")

</div>

I have not been able to reproduce this issue. Can you please try running the iOS examples that came with the FMOD Engine download and let me know if it fails to link in them as well?

---

<div class="post-metadata">

### Author: ![ChristopheBronner](https://avatars.discourse-cdn.com/v4/letter/c/7bcc69/32.png) [@ChristopheBronner](https://qa.fmod.com/u/ChristopheBronner)
#### Post date: [December 15, 2023, 5:30pm UTC](https://qa.fmod.com/t/link-time-error-for-system-getcpuusage-on-v2-02-19/20979/3 "2023-12-15T17:30:54Z")

</div>

I’ve instead tried with a small test project and couldn’t reproduce it either, do you have any idea what could cause a single symbol to go missing like that?

---

<div class="post-metadata">

### Author: ![jeff\_fmod](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/jeff_fmod/32/1766_2.png) [@jeff\_fmod](https://qa.fmod.com/u/jeff_fmod)
#### Post date: [December 17, 2023, 10:15pm UTC](https://qa.fmod.com/t/link-time-error-for-system-getcpuusage-on-v2-02-19/20979/4 "2023-12-17T22:15:34Z")

</div>

It doesn’t look like it is the same issue from 2.01.04 you mentioned, otherwise the examples would be broken as well.  
We did change the signature of `FMOD::System::getCPUUsage` from 5 arguments to 1 in 2.02: [API Differences](https://fmod.com/docs/2.02/api/welcome-whats-new-202.html#api-differences). You could hit a linker error like this if you linked to a 2.01 version of the libs but had the 2.02 header. This seems unlikely, but it would still be worth comparing [`FMOD_VERSION`](https://fmod.com/docs/2.02/api/core-api-common.html#fmod_version) to the result of [`System::getVersion`](https://fmod.com/docs/2.02/api/core-api-system.html#system_getversion) to ensure your headers and libs are matching (temporarily removing `System::getCPUUsage` from your application and header as well to get it to compile).

---

<div class="post-metadata">

### Author: ![ChristopheBronner](https://avatars.discourse-cdn.com/v4/letter/c/7bcc69/32.png) [@ChristopheBronner](https://qa.fmod.com/u/ChristopheBronner)
#### Post date: [January 15, 2024, 8:10pm UTC](https://qa.fmod.com/t/link-time-error-for-system-getcpuusage-on-v2-02-19/20979/5 "2024-01-15T20:10:54Z")

</div>

The versions were fine, in fact it works well with other projects using the same lib/header combination. Unfortunately I can’t share the code of the main project but something in there is causing that single symbol to fail.

Thank you for your help, if I ever find the issue I’ll post it here!
