CodeSigning pkg file with Installer Certificate in Mac

I have one Mac Desktop Cocoa based application which i have signed succesfully by mac Certificates.

To generate .pkg installer file i am using the following command:

productbuild --component 'App.app' /Applications --sign '3rd Party Mac Developer Installer: Some Name' App.pkg

which generates .pkg file succesfully with proper signing. No complaints about it.

But now i want to include some precheck installation scripts in that .pkg which can perform some validations on user's system prioir to installation. How to do it once i have my pkg generated already? I can easily include such scripts in the package through Package Maker but then how to sign .pkg file with Installer Certificate. As this process does not signs my pkg file and hence unacceptable to upload to AppStore


First, I'm not sure you're allowed to include such scripts in an App Store package in the first place.

But if you are, the manpage for productbuild explains how to generate a package from a custom Distribution file by using the --distribution option instead of --component. And, if you don't know how to write a Distribution file, you can look at the ones inside any package (just "xar xf App.pkg" to extract the contents, and Distribution will be at the top level) and/or use productbuild with the --synthesize option.

链接地址: http://www.djcxy.com/p/87260.html

上一篇: Atlassian Bamboo:持续执行计划

下一篇: 在Mac中使用安装者证书对pkg文件进行代码签名