Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the replacement for Xcode's PackageApplication?

Tags:

xcode

xcode8

With Xcode 8.3 PackageApplication is gone. I did use it to convert an *.app package/directory to a *.ipa file (after re-signing):

xcrun -sdk iphoneos PackageApplication -v "MyApp.app" -o "MyApp.ipa"

Is there any replacement for this, so I can continue to convert .app to .ipa?

like image 345
asp_net Avatar asked Mar 29 '17 13:03

asp_net


1 Answers

Apparently there is no need to use any other tool, and it's also not necessary to change the process that leads to the *.app package (in other words: no need to use xcodebuild -exportArchive).

All we have to do, is to zip that *.app package:

pushd "/build"
mkdir ./Payload
cp -R "$PATH_TO_SIGNED_APP_PACKAGE.app" ./Payload
zip -qyr MyApp.ipa ./Payload
rm -r ./Payload
popd

Note:

  1. Jump into the target directory, here /build. This ensures we don't have the full path in the zip archive later.
  2. Create a folder named Payload (important, this cannot vary)
  3. Copy the *.app bundle to the Payload folder
  4. Zip the folder and instead of *.zip use *.ipa as extension
  5. Jump back to where you came from
like image 151
asp_net Avatar answered Dec 20 '22 05:12

asp_net