Skip to content
New issue

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

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

Already on GitHub? # to your account

🛠 fix for xcode 12 #482

Merged
merged 1 commit into from
Mar 29, 2021
Merged

🛠 fix for xcode 12 #482

merged 1 commit into from
Mar 29, 2021

Conversation

irminakacz
Copy link
Contributor

I was trying to use @rebox on Xcode 12.4 with additional dependencies react-native-svg and lottie-react-native, but it was resulting in an errors like this one:

The following build commands failed:
        Ld /Users/user.name/Library/Developer/Xcode/DerivedData/rebox-byjvpkhoayqrwpfsuipmqmyqgpzv/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNSVG.build/Objects-normal/x86_64/Binary/RNSVG normal x86_64
(1 failure)

After some research, I found that this specific fix seems to work:react-native-svg/react-native-svg#1510
(replacing 'React' with 'React-Core' inside ./node_modules/react-native-svg/RNSVG.podspec and other respective podspec files)

So far adding a simple postinstall script seems to be fastest solution:

  "scripts": {
    "postinstall": "perl -pi -e \"s/'React'/'React-Core'/g\" ./node_modules/react-native-svg/RNSVG.podspec ./node_modules/lottie-react-native/lottie-react-native.podspec"
  },

Works on ios and android, tests pass locally, svgs and animations work 👍

@irminakacz irminakacz merged commit 0670fd5 into master Mar 29, 2021
@irminakacz irminakacz deleted the fix-xcode-12 branch March 29, 2021 13:26
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant