Nativescript-cli: [ios] Unable to find included file "../plugins-release.xcconfig"

Created on 10 Dec 2016  路  8Comments  路  Source: NativeScript/nativescript-cli

When upgrading to 2.4.X cli, the plugins-release.xcconfig file is never created in platforms/ios/ folder.

I'm thinking it has to do with these errors when trying to archive my project:
error
http://i.imgur.com/w0itMOc.png

Running pod install does not resolve these errors.

feature CocoaPods

Most helpful comment

I've also been seeing the same errors listed above whilst trying to produce an archive in xcode.

I finally got the app to Archive by doing the following:

  1. Open the xcworkspace in xcode.
  2. Add ${SRCROOT}/Pods to the PODS_ROOT Release key under Build Settings - this was only set for Debug and not Release in my workspace. This removes the pod errors but introduces may others.
  3. Run $ tns build ios --release in Terminal
  4. Go back to xcode and archive the app. All errors are now gone and the archive succeeds.

I don't know where in the process this is failing but I've tried many things to get the app to archive. The above steps are the only way I've managed to get an archive to succeed.

Edit:
Validating the archive throws up a number of other errors. Back to square one.

All 8 comments

@roblav96 We changed the build process in 2.4.0. Now plugins-release.xcconfig is created only when using the --release flag. Please, could you confirm that everything works as expected when using this flag?

@tzraikov Yes i can confirm that using the --release flag does build. Although I'm not able to publish the ipa because it was never signed with a distribution profile unlike the publish command.

I've also been seeing the same errors listed above whilst trying to produce an archive in xcode.

I finally got the app to Archive by doing the following:

  1. Open the xcworkspace in xcode.
  2. Add ${SRCROOT}/Pods to the PODS_ROOT Release key under Build Settings - this was only set for Debug and not Release in my workspace. This removes the pod errors but introduces may others.
  3. Run $ tns build ios --release in Terminal
  4. Go back to xcode and archive the app. All errors are now gone and the archive succeeds.

I don't know where in the process this is failing but I've tried many things to get the app to archive. The above steps are the only way I've managed to get an archive to succeed.

Edit:
Validating the archive throws up a number of other errors. Back to square one.

The current behavior of the build command when using --release flag is to build in release. Unlike the publish command it doesn't create an archive. The best option in this scenario is to use the workflow described by @3rror404. We will consider adding an option to produce archive.

In the latest releases CLI creates archive in both debug and release builds and creates ipa from these archives. Can we consider this issue as resolved? @roblav96 @3rror404

I'm closing this due to inactivity. Please feel free to write here or open an another issue in case you have some problems.

As @3rror404 suggested, running tns build ios --release fixed the issue for me

I got this error when I was trying to use the Profile build option in Xcode to debug the app with Instruments. What fixed the issue for me was running this command:

tns run ios --bundle --env.oat --env.snapshot --release

After running it with this command, open the .xcworkspace file in the platforms/ios directory, and then you'll be able to run the iOS app with Instruments attached.

Was this page helpful?
0 / 5 - 0 ratings