[iOS] Fix build fail when "ipconfig getifaddr" does not have IP#41823
[iOS] Fix build fail when "ipconfig getifaddr" does not have IP#41823nochkin wants to merge 1 commit intofacebook:mainfrom nochkin:main
Conversation
The script used fail when IP is assigned to non-en0 interface because "ipconfig getifaddr en0" exits with 1 when IP is not assigned. That produced "PhaseScriptExecution failed with a nonzero exit code" in Xcode. The patch fixes this issue by removing "set -e" and re-enabling it later in the script.
|
Hi @nochkin! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks! |
Base commit: eb661df |
|
Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks! |
|
Unfortunately this is not the right fix. The purpose of having |
|
@dmytrorykun |
|
@nochkin sorry, you're right, I somehow missed that |
One of the build phase scripts fails when IP is assigned to non-en0 interface because "ipconfig getifaddr en0" exits with 1 when IP is not assigned to en0. That produced "PhaseScriptExecution failed with a nonzero exit code" in Xcode. The patch fixes this issue by removing "set -e" and re-enabling it later in the script.
Summary:
iOS build fails during
Bundle React Native code and imagesphase.The actual error message is
PhaseScriptExecution failed with a nonzero exit code.After doing some debugging it appears the issue is within
scripts/react-native-xcode.shand was introduced in the commit a56e5daThe patch removes "set -e" and re-enables it after looping through interfaces. Also, added the original commit comment to explain why it's been added there initially.
Changelog:
[IOS][FIXED] Fix the build failure when "en0" does not have IP assigned
Test Plan: