f111fei / react-native-unity-demo

103 stars 80 forks source link

react-native-unity-demo/ios/UnityExport/Classes/UnityAppController.mm:519:13: no matching function for call to 'objc_msgSend' #13

Closed fedegl closed 6 years ago

fedegl commented 6 years ago

Hello!

First I would like to thanks you for this effort!

I have been trying to run the demo on iOS but haven't been able to do it. Initially I got this error:

Scanning folders for symlinks in /Users/federico/code/react-native-unity-demo/node_modules (12ms)
Found Xcode project rnunitydemo.xcodeproj
We couldn't boot your defined simulator due to an already booted simulator. We are limited to one simulator launched at a time.
Launching iPhone 6 (iOS 11.4)...
Building using "xcodebuild -project rnunitydemo.xcodeproj -configuration Debug -scheme rnunitydemo -destination id=1CB7B72C-5493-4834-A164-E16E25D0C743 -derivedDataPath build"
xcodebuild: error: The project named "rnunitydemo" does not contain a scheme named "rnunitydemo". The "-list" option can be used to find the names of the schemes in the project.

Installing build/Build/Products/Debug-iphonesimulator/rnunitydemo.app
An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=22):
Failed to install the requested application
The bundle identifier of the application could not be determined.
Ensure that the application's Info.plist contains a value for CFBundleIdentifier.
Print: Entry, ":CFBundleIdentifier", Does Not Exist

Command failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/rnunitydemo.app/Info.plist
Print: Entry, ":CFBundleIdentifier", Does Not Exist

Then to fix it I duplicated the rndemo schema and named it rnunitydemo. After that I get the following error:

▸ Check Dependencies
▸ Precompiling UnityExport/Classes/Prefix.pch
▸ Compiling rnunitydemo_vers.c
▸ Compiling AppDelegate.m
▸ Compiling main.m
▸ Compiling CrashReporter.mm
▸ Compiling UnityAppController+UnityInterface.mm
▸ Compiling UnityAppController+Rendering.mm
▸ Compiling UnityAppController.mm

❌  /Users/federico/code/react-native-unity-demo/ios/UnityExport/Classes/UnityAppController.mm:519:13: no matching function for call to 'objc_msgSend'

            UNITY_OBJC_CALL_ON_SELF(_self, @selector(setFrameInterval:), SetFrameIntervalFunc, (int)(60.0f / fps));
                       ^

▸ Compiling iPhone_Sensors.mm
▸ Compiling main.mm
▸ Compiling Bulk_Assembly-CSharp_0.cpp
▸ Compiling Bulk_Generics_0.cpp
▸ Compiling Bulk_Generics_1.cpp
▸ Compiling Bulk_Generics_2.cpp
▸ Compiling Bulk_Generics_3.cpp
▸ Compiling Bulk_Generics_4.cpp
** BUILD FAILED **

The following commands produced analyzer issues:

    Analyze Base/RCTModuleMethod.mm normal x86_64
(1 command with analyzer issues)

The following build commands failed:
    CompileC build/Build/Intermediates.noindex/rnunitydemo.build/Debug-iphonesimulator/rnunitydemo.build/Objects-normal/x86_64/UnityAppController.o UnityExport/Classes/UnityAppController.mm normal x86_64 objective-c++ com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)

Installing build/Build/Products/Debug-iphonesimulator/rnunitydemo.app
An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=22):
Failed to install the requested application
The bundle identifier of the application could not be determined.
Ensure that the application's Info.plist contains a value for CFBundleIdentifier.
Print: Entry, ":CFBundleIdentifier", Does Not Exist

Command failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/rnunitydemo.app/Info.plist
Print: Entry, ":CFBundleIdentifier", Does Not Exist

error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Any help is very much appreciated, and I am willing to contribute to the project. Let me know how can I help!

f111fei commented 6 years ago

duplicate https://github.com/f111fei/react-native-unity-view/issues/15