azesmway / react-native-unity

MIT License
287 stars 74 forks source link

Use of undeclared identifier 'BASELIB_API' #140

Open thechaudharysab opened 4 days ago

thechaudharysab commented 4 days ago

I'm using

   "@azesmway/react-native-unity": "^1.0.10",
    "react": "18.3.1",
    "react-native": "0.75.4"

Configured my iOS and Android projects according to the README. It works fine for Android, but when I build for iOS I get these errors:

Screenshot 2024-11-28 at 11 39 54 PM

Some of these errors are:

MyApp/node_modules/@azesmway/react-native-unity/ios/Il2CppOutputProject/IL2CPP/external/baselib/Include/C/Baselib_Debug.h:17:1 Use of undeclared identifier 'BASELIB_API'

MyApp/node_modules/@azesmway/react-native-unity/ios/Il2CppOutputProject/IL2CPP/external/baselib/Include/C/Baselib_Debug.h:4:1 A type specifier is required for all declarations

Not sure if it's relevant, but in the folder where UnityFramework.framework was created there were also libGameAssembly.a and libil2cpp.a which I didn't copy when I copied the UnityFramework.framework folder.

Another screenshot of the same errors:

Screenshot 2024-11-29 at 12 47 27 AM

thechaudharysab commented 4 days ago

Downgrading to "@azesmway/react-native-unity": "^1.0.7" worked for iOS.