Home > Back-end >  Amplitude Unity iOS 'Amplitude\Amplitude.h' file not found
Amplitude Unity iOS 'Amplitude\Amplitude.h' file not found

Time:11-04

I added the Amplitude SDK to an existing Unity project, on Android it was fine, but for iOS when I try to build I get this error in xcode ... "'Amplitude\Amplitude.h' file not found"

Project uses Unity 2021.3.9f1 and Ar foundation

I get the same issue with a brand new Unity 2021.3.9f1 project, with nothing in it but the Amplitude SDK. I used the 2.6.0 amplitude-unity.unitypackage file from here enter image description here

CodePudding user response:

So they had two unitypackages available to download on their github site. On Amplitudes website they say "Download the latest amplitude-unity.unitypackage" This is the smaller file, the one I used.

But it seems for ios you must.

  1. Download the bigger file called "amplitude-unity-all.unitypackage"
  2. In unity goto Assets\External Dependency manager\iOS resolver\Install cocoapods
  3. build xcode project
  4. In xcode click on unity framework target, then Build Settings\Build Options and set enable bitcode to No

After taking these steps I was able to build and Amplitude worked on iOS

  • Related