0

For a react-native project, I am compiling the IOS by running

npx react-native run-ios --configuration Release

it generates an app file, but then there is no much documentation further in official react documentation. Then I follow the instruction here to generate ipa file. Then when I upload the ipa file to transporter for upload, it complains about the provision profile is missing.

enter image description here

I have set the provision profile in Xcode, the question here is that, does following line use the provision profile?

npx react-native run-ios --configuration Release 

the reason that I am using react cli instead of Xcode for compiling is due to this linear-gradient library

there has been linking problems with this library, and it complains about

Library not found for -lBVLinearGradient

enter image description here

Originally this problem occurs when I run the react cli release compile and on Xcode as well. but after some unlinking/relinking, it starts to work using react cli but still fail at Xcode. This problem is blocking us to release the app now. So the questions here are now I have a app file what is the next step to convert it into a ipa file with provision profile attached? or even better, why is the project have this behaviour that the react cli compile works but not on Xcode, since react cli is just running the Xcode compiler underneath.

user3453552
  • 199
  • 1
  • 2
  • 11

1 Answers1

0

I realize that app file is not really signed using provision profile, so following commands do the deployment for me, first generate main.jsbundle by running

react-native bundle --entry-file index.js --platform ios --dev false --bundle-output ios/main.jsbundle --assets-dest ios/assets

then main.jsbundle will show up in xcode project structure. Some tutorials out there shows that you need to modify the AppDelegate.m, but it worked without that for me. Afterwards I just archive, and generate ipa file, surprisingly after the archive, the build do not complain about the missing gradient library anymore. I can only imagine that part of the archive process actually bring in the library somehow. These steps work for me and app is on appstore.

user3453552
  • 199
  • 1
  • 2
  • 11