Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linking error on iOS #396

Closed
jkomyno opened this issue Feb 1, 2017 · 6 comments
Closed

Linking error on iOS #396

jkomyno opened this issue Feb 1, 2017 · 6 comments

Comments

@jkomyno
Copy link

jkomyno commented Feb 1, 2017

Env info:

  • Mac OS Sierra 10.12
  • Node v6.9.4
  • npm 3.10.10
  • react-native: 0.38.0
  • XCode 8.2.1

Error

CompileC /%project-directory%/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-
iphonesimulator/RNVectorIcons.build/Objects-normal/x86_64/RNVectorIconsManager.o 
RNVectorIconsManager/RNVectorIconsManager.m normal x86_64 objective-c 
com.apple.compilers.llvm.clang.1_0.compiler

Description

I followed what your documentation says: at first I tried react-native link (which actually works well with Android), and discovered that the plist file and the font used by application section were alright. However, I had to manually add libRNVectorIcons.a to "Link Binary With Libraries". After all this steps, still no results at all. The same project can be built successfully on Android, an the iOS project did too until I added react-native-vector-icons. Please, I'm open to any suggestion. Also, thank you for your time spent developing this library.

@oblador
Copy link
Owner

oblador commented Feb 1, 2017

Your error doesn't really look like an error, do you have any more info?

@jkomyno
Copy link
Author

jkomyno commented Feb 1, 2017

Give me a couple of minutes man, I'll show you the complete log

@jkomyno
Copy link
Author

jkomyno commented Feb 1, 2017

Found Xcode project example.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 10.2)...
Building using "xcodebuild -project example.xcodeproj -scheme example -destination id=B4D81FA2-24AD-4549-BE33-952D413469F6 -derivedDataPath build"
User defaults from command line:

IDEDerivedDataPathOverride = /myproject/ios/build

=== BUILD TARGET RCTWebSocket OF PROJECT RCTWebSocket WITH CONFIGURATION Debug ===

Check dependencies

=== BUILD TARGET ReactNativeNavigation OF PROJECT ReactNativeNavigation WITH CONFIGURATION Debug ===
Check dependencies

=== BUILD TARGET RCTVibration OF PROJECT RCTVibration WITH CONFIGURATION Debug ===

Check dependencies

=== BUILD TARGET RNVectorIcons OF PROJECT RNVectorIcons WITH CONFIGURATION Debug ===
Check dependencies

CompileC /myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/Objects-normal/x86_64/RNVectorIconsManager.o RNVectorIconsManager/RNVectorIconsManager.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
cd /myproject/node_modules/react-native-vector-icons
export LANG=en_US.US-ASCII
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x objective-c -arch x86_64 -fmessage-length=0 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit=0 -std=gnu99 -fobjc-arc -fmodules -fmodules-cache-path=/myproject/ios/build/ModuleCache -fmodules-prune-interval=86400 -fmodules-prune-after=345600 -fbuild-session-file=/myproject/ios/build/ModuleCache/Session.modulevalidation -fmodules-validate-once-per-build-session -Wnon-modular-include-in-framework-module -Werror=non-modular-include-in-framework-module -Wno-trigraphs -fpascal-strings -O0 -fno-common -Wno-missing-field-initializers -Wno-missing-prototypes -Werror=return-type -Wunreachable-code -Wno-implicit-atomic-properties -Werror=deprecated-objc-isa-usage -Werror=objc-root-class -Wno-arc-repeated-use-of-weak -Wduplicate-method-match -Wno-missing-braces -Wparentheses -Wswitch -Wunused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wempty-body -Wconditional-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wconstant-conversion -Wint-conversion -Wbool-conversion -Wenum-conversion -Wshorten-64-to-32 -Wpointer-sign -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wundeclared-selector -Wno-deprecated-implementations -DDEBUG=1 -DOBJC_OLD_DISPATCH_PROTOTYPES=0 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator10.2.sdk -fasm-blocks -fstrict-aliasing -Wprotocol -Wdeprecated-declarations -mios-simulator-version-min=7.0 -g -Wno-sign-conversion -Wno-infinite-recursion -fobjc-abi-version=2 -fobjc-legacy-dispatch -iquote /myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/RNVectorIcons-generated-files.hmap -I/myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/RNVectorIcons-own-target-headers.hmap -I/myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/RNVectorIcons-all-target-headers.hmap -iquote /myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/RNVectorIcons-project-headers.hmap -I/myproject/ios/build/Build/Products/Debug-iphonesimulator/include -I/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include -I/myproject/node_modules/react-native-vector-icons/../../React -I../react-native/React -I../react-native/React/Base -I../react-native/React/CSSLayout -I../react-native/React/Executors -I../react-native/React/Modules -I../react-native/React/Profiler -I../react-native/React/Views -I/myproject/node_modules/react-native-vector-icons/node_modules/react-native/React -I/myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/DerivedSources/x86_64 -I/myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/DerivedSources -F/myproject/ios/build/Build/Products/Debug-iphonesimulator -MMD -MT dependencies -MF /myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/Objects-normal/x86_64/RNVectorIconsManager.d --serialize-diagnostics /myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/Objects-normal/x86_64/RNVectorIconsManager.dia -c /myproject/node_modules/react-native-vector-icons/RNVectorIconsManager/RNVectorIconsManager.m -o /myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/Objects-normal/x86_64/RNVectorIconsManager.o

In file included from /myproject/node_modules/react-native-vector-icons/RNVectorIconsManager/RNVectorIconsManager.m:9:
/myproject/node_modules/react-native-vector-icons/RNVectorIconsManager/RNVectorIconsManager.h:9:9: fatal error: 'React/RCTBridgeModule.h' file not found
#import <React/RCTBridgeModule.h>
^
1 error generated.

=== BUILD TARGET React OF PROJECT React WITH CONFIGURATION Debug ===
Check dependencies

=== BUILD TARGET RCTActionSheet OF PROJECT RCTActionSheet WITH CONFIGURATION Debug ===

Check dependencies

=== BUILD TARGET RCTLinking OF PROJECT RCTLinking WITH CONFIGURATION Debug ===

Check dependencies

=== BUILD TARGET RCTSettings OF PROJECT RCTSettings WITH CONFIGURATION Debug ===

Check dependencies

=== BUILD TARGET RCTGeolocation OF PROJECT RCTGeolocation WITH CONFIGURATION Debug ===

Check dependencies

=== BUILD TARGET RCTAnimation OF PROJECT RCTAnimation WITH CONFIGURATION Debug ===

Check dependencies

=== BUILD TARGET RCTNetwork OF PROJECT RCTNetwork WITH CONFIGURATION Debug ===

Check dependencies

** BUILD FAILED **

The following build commands failed:
CompileC /myproject/ios/build/Build/Intermediates/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/Objects-normal/x86_64/RNVectorIconsManager.o RNVectorIconsManager/RNVectorIconsManager.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler

(1 failure)

Installing build/Build/Products/Debug-iphonesimulator/example.app
Launching org.reactjs.native.example.example
org.reactjs.native.example.example: 2465

@jkomyno
Copy link
Author

jkomyno commented Feb 1, 2017

I've also tried with the podfile (clearly with the relative path, as you suggest in #394), however I ended up with errors anyway

@oblador
Copy link
Owner

oblador commented Feb 1, 2017

OK, you need to upgrade RN to 0.40 or downgrade RNVI to 3.0

@jkomyno
Copy link
Author

jkomyno commented Feb 4, 2017

Thanks you for your patience, I'm closing this one. I've also pulled a request where I added some related info to the README file.

@jkomyno jkomyno closed this as completed Feb 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants