Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error Itms-90339: This bundle is invalid . The info.plist contains an invalid key 'CFBundleResourceSpecification’ in app bundle

Tags:

xcode

ios

I am trying to upload my application on iTunes for iOS 9. I used Xcode 7 beta 6 to build my IPA , but iTunes failed to upload my IPA by following error message .enter image description here

like image 485
Anupam Mishra Avatar asked Sep 10 '15 14:09

Anupam Mishra


3 Answers

Project settings under Build Settings > Code Signing > Code Signing Resource Rules Path - Delete the value for Code Signing Resource Rules Path. That fixed issue for me

like image 87
Kaushal Panjwani Avatar answered Nov 18 '22 10:11

Kaushal Panjwani


I am the same boat as DongHui Li. I am using Jenkins too. If I remove CODE_SIGN_RESOURCE_RULES_PATH=$(SDKROOT)/ResourceRules.plist I am NOT able to build. And if I add it, I can build but NOT able to submit to Apple.

UPDATE -> I am able to build and upload to apple using Jenkins now.
What I did is:

  1. Remove CODE_SIGN_RESOURCE_RULES_PATH=$(SDKROOT)/ResourceRules.plist
  2. Find the /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/PackageApplication script and update it.
    Find the lines including the following code in the script

    my @codesign_args = ("/usr/bin/codesign", "--force", "--preserve-metadata=identifier,entitlements,resource-rules",
                      "--sign", $opt{sign},
                      "--resource-rules=$destApp/ResourceRules.plist");
    

    change it to:

    my @codesign_args = ("/usr/bin/codesign", "--force", "--preserve-metadata=identifier,entitlements",
                      "--sign", $opt{sign});
    
like image 37
Rishi Goel Avatar answered Nov 18 '22 09:11

Rishi Goel


The problem lies in the Xcode integration plugin for Jenkins. Specifically, there is a checkbox in build details pane called : "Pack application and build .ipa?"

This feature will call 'xcrun PackageApplication' with the optional '--embed' and '--sign' flags set.

for the most part you will have already run codesign, and also in most cases the embedding of the provisioning profile is redundant. unfortunately the author of the plugin has not taken this into consideration, and these two optional parameters are not configurable through the GUI of the jenkins plugin.

the solution:

DO NOT SELECT THIS OPTION!

This option has three parameters:

  • '.ipa filename pattern' : ex: MyApplication

  • 'Output directory' : ex: OUTPUT

  • 'manifest plist URL' ( I've not used this... )

instead, manually package your .ipa file by adding the 'execute shell' after the build using the parameters you would in the 'pack' option of the GUI:

/bin/mkdir $(PWD)/build/OUTPUT    
/usr/bin/xcrun -sdk iphoneos PackageApplication -v $(PWD)/build/MyApplication.app -o $(PWD)/build/OUTPUT/MyApplication.ipa
like image 5
kent Avatar answered Nov 18 '22 10:11

kent