views:

591

answers:

1

My PackageMaker project was generating a .mpkg file, but then, all of the sudden, when I go to build, it only generates .pkg files. The .mpkg files are actually directories into which I place my custom installer bundle along with an InstallerSections.plist file to specify the order in which my custom view should display. The .pkg files are not directories and I have no way to add my custom installer bundle to it.

Anyhow, something is awry as PackageMaker no longer lets me generate a .mpkg file. Any idea why that might be? Is there some other way I should be approaching this?

Thanks.

p.s. If you are thinking of suggesting I ought to check out this tutorial, please don't bother. It's way out of date. Thanks.

+2  A: 

Your pmdoc is a distribution project, and you've set the pmdoc's minimum system version to 10.5. PackageMaker always generates flat packages in this case.

There are three solutions:

  1. Choose “Install Properties…” from the Project menu, and set the pmdoc's minimum system version to 10.4. This is the go-back-to-.mpkg solution.
  2. Use the Flat Package Editor (hidden inside the PackageMaker bundle) to add the custom installer bundle. The contents of a .pkg file are the same as, and lain out similarly to, those of a .mpkg bundle.
  3. Since flat packages are xar archives, use xar to extract the contents of the .pkg file to a temporary directory, add the custom installer bundle in that directory, then use xar to re-assemble the .pkg file from the temporary directory.
Peter Hosey
Thanks Peter. I appreciate it.
Matt Long
Very thorough and helpful answer, Peter. Thanks again. I'm back in business getting this thing done by Monday. Gracias!
Matt Long