On a case-sensitive filesystem, React Native fails to build
See original GitHub issueDescription
Some issues with building yoga were discovered while using expo: https://github.com/expo/expo/issues/16283 but the root cause is in the way the Yoga pod is installed.
The build failure has the error
Use of undeclared identifier 'YGValue`
On a case-sensitive filesystem, the symlinks Yoga-umbrella.h
and Yoga.modulemap
are created in ios/Pods/Headers/Public/yoga
instead of ios/Pods/Headers/Public/Yoga
(note the case of yoga
), which causes the build failure.
If I change https://github.com/facebook/react-native/blob/main/ReactCommon/yoga/Yoga.podspec#L30 from 'yoga'
to 'Yoga'
, everything builds fine.
Version
0.63.0
Output of npx react-native info
$ npx react-native info info Fetching system and libraries information...
System:
OS: macOS 12.3
CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz
Memory: 883.43 MB / 16.00 GB
Shell: 5.8 - /bin/zsh
Binaries:
Node: 12.22.11 - ~/.volta/tools/image/node/12.22.11/bin/node
Yarn: 1.22.18 - ~/.volta/tools/image/yarn/1.22.18/bin/yarn
npm: 6.14.16 - ~/.volta/tools/image/node/12.22.11/bin/npm
Watchman: 2022.03.21.00 - /usr/local/bin/watchman
Managers:
CocoaPods: 1.10.1 - /Users/tngacker/.rbenv/shims/pod
SDKs:
iOS SDK:
Platforms: DriverKit 21.4, iOS 15.4, macOS 12.3, tvOS 15.4, watchOS 8.5
Android SDK:
API Levels: 28, 29, 30
Build Tools: 28.0.3, 29.0.2, 30.0.3
System Images: android-30 | Google APIs Intel x86 Atom
Android NDK: Not Found
IDEs:
Android Studio: 2021.1 AI-211.7628.21.2111.8193401
Xcode: 13.3.1/13E500a - /usr/bin/xcodebuild
Languages:
Java: 11.0.14 - /usr/bin/javac
npmPackages:
@react-native-community/cli: Not Found
react: 17.0.1 => 17.0.1
react-native: 0.64.3 => 0.64.3
react-native-macos: Not Found
npmGlobalPackages:
*react-native*: Not Found
Steps to reproduce
I believe this happens on multiple versions of react native, see https://github.com/expo/expo/issues/16283
I can follow up again if necessary.
Snack, code example, screenshot, or link to a repository
No response
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:5 (1 by maintainers)
Top Results From Across the Web
npx react-native run-ios doesn't work after initializing the project
In my case the issue was the case sensitive file system. You can search in terminal for fatal error: 'openssl/opensslv.h' file not found...
Read more >[Support Guide] Netlify app builds locally but fails on deploy ...
The file system used in Netlify builds is case sensitive, while your local environment is not. Unfortunately, the error messages that result may...
Read more >The Curious Case of Git, macOS Filesystem ... - Spektor?.dev
The Curious Case of Git, macOS Filesystem and Case Sensitivity ... I deployed but the build failed again . This time the error...
Read more >HowTo: Handle case sensitive file system on Mac OS
Repartition the entire hard drive with case sensitivity turned on. · Create a new partition and re-format only this new partition with the...
Read more >How do I resolve a 'module not found' error? - Vercel
One possible cause for this issue is the fact that some filesystems are case-insensitive, however Vercel deployments use a case-sensitive filesystem.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Same issue for us (pretty painful timesink). We are working around it by simply having a step after
yarn
and beforepod
installs:I’m not sure why noone made a PR to do this fix before now, but I went ahead and made one: https://github.com/facebook/react-native/pull/34058 so that at least we can test that it’s actually that and there are no other side effects