I’m using Iceberg to create the packages since that’s what I’m familiar with–there may be better tools in Leopard, but I haven’t had a chance to explore them.
You probably already have a shell script you want to run, so grab Iceberg:
[url]http://s.sudre.free.fr/Software/Iceberg.html[/url]
Create a new “Package” project. Tip open the disclosure triangle and select “Scripts” (there seems to be a GUI issue, you may need to select “Settings” and then “Scripts” before the available “Installation Scripts” appears correctly). Under “Installation Scripts”, check “postflight” and “Choose…” your script. Keep an eye on exactly what your shell script assumes about the environment it’s running in–even though Installer is targeting /Volumes/Instadmg_Target, postflights run with a root of “/”. To rewrite the scripts appropriately, see the variables listed at “Some information is passed by the installer to these scripts when they are launched” here:
[url]http://s.sudre.free.fr/Stuff/PackageMaker_Howto.html[/url]
Also, you may need to install a single dummy file to make the package work–I’ve seen reports that packages will complain if they don’t have files to drop. A “touch”ed file at /private/tmp is sufficient for me.
– Patrick
Comments are closed