react-native: Reliable build on `^0.39.2` fails when upgrading to `^0.40.0`
** BUILD FAILED **
The following build commands failed:
CompileC /XXX-FULLPATH-XXX/ios/build/Build/Intermediates/RCTSettings.build/Debug-iphonesimulator/RCTSettings.build/Objects-normal/x86_64/RCTSettingsManager.o RCTSettingsManager.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 9
- Comments: 37 (11 by maintainers)
Links to this issue
Commits related to this issue
- 升级到40版本出了各种问题,以后升级版本可以参考试一下几个命令: ·react-native upgrade ·react-native-git-upgrade 还可以参考这篇讨论:https://github.com/facebook/react-native/issues/11721 ===================================我是分割线===============... — committed to AmatsuZero/NeteaseNews by deleted user 7 years ago
- fix xcode along with react-native 0.4X.X xcode https://github.com/facebook/react-native/issues/11721#issuecomment-270672904 react-native upgrade https://github.com/oblador/react-native-vector-icons/... — committed to okmttdhr/Miss-YT by okmttdhr 7 years ago
I solved it doing this:
BTW, I am using https://github.com/beefe/react-native-picker and it also works without updating the import format in the library. Strange, but it is working…
I am also running into trouble going from 0.39.2 -> 0.40.0, with several “file not found” issues.
The underlying issue is that the sub-projects like RCTVibration, RCTWebSocket, etc all depend on things in the React project, but do not have it as a build dependency, so it is possible for them to try to build before the things they depend on have built.
I actually found that if you make the React project a dependency of all the other RCT* sub-projects, you can turn parallel builds back on and it works fine.
To add the React project as a dependency, do the following:
If somebody could go through these steps and verify it solves the issue for them AND allows them to turn parallel builds back on, that would be greatly appreciated. Once I verify that this works for other people’s projects, I would be fine with making a PR against React Native to make this happen by default.
I have encounter same issue after upgrade from 0.39.2 to 0.40, but @SandroMachado 's workaround not work for me. use
react-native-git-upgrade
to upgrade, but no file change Should I update the search path? And how?+1 @SandroMachado’s solution. It worked for me. Thank you!
@binchik I have the same problem and https://github.com/facebook/react-native/issues/2685 fix my issue:
libReact.a
is listed-lc++
flagI went thru https://github.com/ncuillery/rn-diff/compare/rn-0.39.2...rn-0.40.0 and moved over what seemed to be meaningful, but not what I assume to be compile results.
My remaining issues may be specific to my project, but also likely affect others. Does anyone know how to solve these?
how is disabling parallelization a good thing? isnt the packager slow enough, now we slow down xcode too? why? i really dont think this should be turned off.
this change happened here https://github.com/facebook/react-native/commit/e1577df1fd70049ce7f288f91f6e2b18d512ff4d
Take a look on the release note:
https://github.com/facebook/react-native/releases/tag/v0.40.0
I recommend to use this tool: https://github.com/ncuillery/rn-diff
^ ha! oops, I meant to mention @tanmynguyen – autocomplete ftw
@yoniji Thanks for the suggestion. I tried it, Xcode still can’t find React libs.
I stopped using CocoaPods, imported everything the usual way, now everything works fine. I’d like to use CocoaPods though 😦