Xcode 8 Beta: aps-environment entitlement is missing
| Originator: | yakimant | ||
| Number: | rdar://28076333 | Date Originated: | 30/08/16 |
| Status: | Closed | Resolved: | Behaves correctly |
| Product: | Developer Tools | Product Version: | Xcode 8.0 Build version 8S201h |
| Classification: | Serious Bug | Reproducible: | Yes |
Summary:
After running xcodebuild archive,
<key>aps-environment</key>
<string>production</string>
entitlement is missing even if we have it in provisioning profile.
Steps to Reproduce:
Run xcodebuild archive:
xcodebuild PROVISIONING_PROFILE_SPECIFIER='...' -workspace App.xcworkspace -scheme "App" -derivedDataPath "Output/iphoneos10" -sdk iphoneos -configuration Beta CODE_SIGN_IDENTITY="..." -archivePath "Output/iphoneos10/App.xcarchive" clean archive
Expected Results:
⇒ codesign --display --entitlements :- ./Output/iphoneos/App.xcarchive/Products/Applications/App.app
Executable=/Users/yakimant/Workspace/app/Output/App/iphoneos/App.xcarchive/Products/Applications/App.app/App
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>application-identifier</key>
<string>SOMEID.com.some.App</string>
<key>aps-environment</key>
<string>production</string>
<key>beta-reports-active</key>
<true/>
<key>com.apple.developer.team-identifier</key>
<string>TEAMID</string>
<key>get-task-allow</key>
<false/>
<key>keychain-access-groups</key>
<array>
<string>SOMEID.com.some.App</string>
</array>
</dict>
</plist>
Actual Results:
⇒ codesign --display --entitlements :- ./Output/iphoneos10/App.xcarchive/Products/Applications/App.app
Executable=/Users/user/Workspace/app/Output/iphoneos10/App.xcarchive/Products/Applications/App.app/App
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>application-identifier</key>
<string>SOMEID.com.some.App</string>
<key>beta-reports-active</key>
<true/>
<key>com.apple.developer.team-identifier</key>
<string>TEAMID</string>
<key>get-task-allow</key>
<false/>
<key>keychain-access-groups</key>
<array>
<string>SOMEID.com.some.App</string>
</array>
</dict>
</plist>
Version:
Xcode 8.0
Build version 8S201h
Notes:
Looks, like ProcessProductPackaging step is changed.
Xcode 7:
ProcessProductPackaging /Applications/Xcode-7.3.1.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS9.3.sdk/Entitlements.plist Output/iphoneos/Build/Intermediates/ArchiveIntermediates/App/IntermediateBuildFilesPath/App.build/Beta-iphoneos/App.build/App.app.xcent
Xcode 8:
ProcessProductPackaging "" Output/iphoneos10/Build/Intermediates/ArchiveIntermediates/App/IntermediateBuildFilesPath/App.build/Beta-iphoneos/App.build/App.app.xcent
Configuration:
Attachments:
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!
Here is Apple's response:
Engineering has requested the following information in order to further investigate this issue:
You need to add the entitlement to your entitlements file. Xcode will no longer automatically merge it from the provisioning profile. You can enable the capability in the project editor to have Xcode do this automatically.
We are now closing this bug report.
If you have questions or comments about the resolution, please update your bug report with that information so we can respond.