react-native-unity icon indicating copy to clipboard operation
react-native-unity copied to clipboard

Use of undeclared identifier 'BASELIB_API'

Open thechaudharysab opened this issue 1 year ago • 6 comments

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 avatar Nov 28 '24 15:11 thechaudharysab

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

thechaudharysab avatar Nov 28 '24 17:11 thechaudharysab

@thechaudharysab i am already on this version still facing this error could you guide me

yudizhemal avatar Mar 06 '25 07:03 yudizhemal

@thechaudharysab i am facing same problem .did you find any work around

varunsdcet avatar Apr 04 '25 09:04 varunsdcet

@varunsdcet see the react-native version that I have shared. It should work with that particular react/RN version.

thechaudharysab avatar Apr 04 '25 10:04 thechaudharysab

@thechaudharysab i am already on this version still facing this error could you guide me

Hello i am still this issue have you any idea how to fix

varunsdcet avatar Apr 04 '25 11:04 varunsdcet

@thechaudharysab i am already on this version still facing this error could you guide me

Hello i am still this issue have you any idea how to fix

@varunsdcet I Gave up on this lib and used this lib its working fine just make sure you properly do setup given here

hemaljoshi avatar Apr 04 '25 12:04 hemaljoshi