fastlane: Gym got stuck at xcrun after successfully archiving and got "Xcode 7 `provisioning_profile_path` will be ignored" warning though the Xcode version is 8

New Issue Checklist

Issue Description

Although I am using Xcode 8, I got these warnings/errors after Archive Succeeded:

You're using Xcode 7, the `provisioning_profile_path` value will be ignored
Please follow the Code Signing Guide: https://codesigning.guide (for match) or https://docs.fastlane.tools/codesigning/GettingStarted/

and then I got stuck at xcrun

/usr/bin/xcrun /usr/local/lib/ruby/gems/2.3.0/gems/gym-1.10.0/lib/assets/wrap_xcodebuild/xcbuild-safe.sh -exportArchive -exportOptionsPlist '/var/folders/77/zxlvnwsj3dv3nc6kt_szls2w0000gn/T/gym_config20161003-2651-1jka4zc.plist' -archivePath /Users/archy/Library/Developer/Xcode/Archives/2016-10-03/LittleDragonPoC\ 2016-10-03\ 11.30.20.xcarchive -exportPath '/var/folders/77/zxlvnwsj3dv3nc6kt_szls2w0000gn/T/gym_output20161003-2651-qfr7ei'

more info

My iOS project 1. contains a custom nested framework (there are many custom frameworks inside one custom framework that the app uses) 2. is generated by Unity (the app project is exported by Unity, and we just do some code injection to get swift to take control and imported our custom nested framework to it). Before updating my xcode to xcode 8 I am able to build it and put it up on testflight just fine in xcode (after some tinkering). But after updating it to xcode 8 I get this error that I have never encountered in my life before (despite all these build errors I have encountered).

ERROR ITMS-90171: "Invalid Bundle Structure - The binary file 'MyApp.app/libswiftRemoteMirror.dylib' is not permitted. Your app can't contain standalone executables or libraries, other than the CFBundleExecutable of supported bundles. Refer to the Bundle Programming Guide at https://developer.apple.com/go/?id=bundle-structure for information on the iOS app bundle structure." 

It complains about a file named libswiftRemoteMirror.dylib. And it exists in all my frameworks and the app.

After googling I found this SO post. So I decided to give gym a try to see if it can build it without the annoying libswiftRemoteMirror.dylib.

Complete output when running fastlane, including the stack trace and command used
INFO [2016-10-03 11:32:29.47]: ▸ Archive Succeeded
DEBUG [2016-10-03 11:32:29.62]: Stored the archive in: /Users/archy/Library/Developer/Xcode/Archives/2016-10-03/LittleDragonPoC 2016-10-03 11.30.20.xcarchive
ERROR [2016-10-03 11:32:29.62]: You're using Xcode 7, the `provisioning_profile_path` value will be ignored
ERROR [2016-10-03 11:32:29.62]: Please follow the Code Signing Guide: https://codesigning.guide (for match) or https://docs.fastlane.tools/codesigning/GettingStarted/
+-------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------+
|                                                                                            Generated Package Command                                                                                             |
+-------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------+
| Option                                                                                                                  | Value                                                                                  |
+-------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------+
| /usr/bin/xcrun /usr/local/lib/ruby/gems/2.3.0/gems/gym-1.10.0/lib/assets/wrap_xcodebuild/xcbuild-safe.sh -exportArchive |                                                                                        |
| -exportOptionsPlist                                                                                                     | /var/folders/77/zxlvnwsj3dv3nc6kt_szls2w0000gn/T/gym_config20161003-2651-1jka4zc.plist |
| -archivePath /Users/archy/Library/Developer/Xcode/Archives/2016-10-03/LittleDragonPoC\ 2016-10-03\ 11.30.20.xcarchive   |                                                                                        |
| -exportPath                                                                                                             | /var/folders/77/zxlvnwsj3dv3nc6kt_szls2w0000gn/T/gym_output20161003-2651-qfr7ei        |
+-------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------+
INFO [2016-10-03 11:32:29.63]: $ /usr/bin/xcrun /usr/local/lib/ruby/gems/2.3.0/gems/gym-1.10.0/lib/assets/wrap_xcodebuild/xcbuild-safe.sh -exportArchive -exportOptionsPlist '/var/folders/77/zxlvnwsj3dv3nc6kt_szls2w0000gn/T/gym_config20161003-2651-1jka4zc.plist' -archivePath /Users/archy/Library/Developer/Xcode/Archives/2016-10-03/LittleDragonPoC\ 2016-10-03\ 11.30.20.xcarchive -exportPath '/var/folders/77/zxlvnwsj3dv3nc6kt_szls2w0000gn/T/gym_output20161003-2651-qfr7ei'

Configuration Files

Fastfile:

lane :beta do
  cert
  sigh
  gym(scheme: "Unity-iPhone")
  testflight
end

Environment

fastlane version (run fastlane -v): 1.104.0

Do you use bundler to execute fastlane (i.e. bundle exec fastlane)? Nope.

Do you use a Ruby environment manager (e.g. chruby, rbenv, rvm)? Nope.

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 22

Most upvoted comments

@hjanuschka I actually found out that OS X server had generated up 357 certificates in my keychain!

So indeed this StackOverflow answer was right

Deleting duplicate certificates decreased time from 21 minutes to less than 4 minutes.

Unfortunately it’s not my issue. When I call xrun directly it works like a charm. And I tried to wait a lot, nearly a few hours, and it also didn’t help 😦 will dig it bit later today

@Sajjon i had same troubles on a few CI machines, after sierra upgrade, i ended up creating a new blank keychain, and setting this to default.