I already built an android project of react native which is working fine. I then started with iOS part. I am using react-native-cli: 2.0.1 react-native: 0.60.4 and Xcode 10 and Mac OS Mojave
The default pod file had some issues installing glog It gave error /bin/bash: ./configure: /bin/sh^M: bad interpreter: No such file or directory
when pod install
was executed. Even after doing everything answered on GitHub and stack overflow like installing Cocoapods, reinstalling, ruby installation, linking cocoapods. Then later on GitHub I found out that pod file had some issues so replaced it with correct content specified on GitHub for react-native. Still did not work then according to this link : https://forums.expo.io/t/pod-install-errors-on-newly-detached-app-on-macos-installing-glog-bin-bash-configure-bin-sh-m-bad-interpreter-no-such-file-or-directory/10054 and then I modified the glog file and then it installed the glog successfully.
After that another issue with glog Need to implement mutex.h for your architecture, or #define NO_THREADS
which I corrected by adding define no_thread
in ios/Pods/glog/src/config.h file
And now stuck with this
/Volumes/Projects/derive-mobile/ios/Pods/glog/src/utilities.h:148:1: Unknown type name '_START_GOOGLE_NAMESPACE_'
/Volumes/Projects/derive-mobile/ios/Pods/glog/src/utilities.h:168:1: Unknown type name 'int64'; did you mean 'google::int64'?
/Volumes/Projects/derive-mobile/ios/Pods/glog/src/utilities.h:170:20: Unknown type name 'int64'; did you mean 'google::int64'?
/Volumes/Projects/derive-mobile/ios/Pods/glog/src/utilities.h:175:1: Unknown type name 'int32'; did you mean 'google::int32'?
/Volumes/Projects/derive-mobile/ios/Pods/glog/src/utilities.h:236:1: Unknown type name '_END_GOOGLE_NAMESPACE_'
/Volumes/Projects/derive-mobile/ios/Pods/glog/src/utilities.h:150:1: Expected unqualified-id
I think my glog installation did not go well. I am using project workspace already.
I have checked overall GitHub Facebook react-native and stack overflow but did not found anything. I have tried legacy build, clearing derived data. I have also tried pod deintegrate and pod install. for glog I have also tried cd ./node_modules/react-native/third-party/glog-0.3.4 && ../../scripts/ios-configure-glog.sh
How can I solve this issue ? is there any way to remove the glog completely and install it again without having the /bin/bash: ./configure: /bin/sh^M: bad interpreter: No such file or directory
as none of the solutions works as mentioned above