Specifying the installation location from the packagemaker command line

Being new to packagemaker, I guess I just missed something. It seems that all options in the GUI are not accessible from the command line. I read the man page, but maybe I just don’t understand.

The most interesting question for me: how to specify the installation location of files?

From the command line, do I also need to use the installer in conjunction with packagemaker to get the same packagemaker GUI results? If so, are there any examples you can recommend?

Thanks Vincent

+4
source share
2 answers

What I did to change the installation directory from the command line:

  • create package
  • extract the new package using pkgutil
  • search for the line for install-location="/" in the pkg PackageInfo file, replace it with the desired installation location
  • repacking with pkgutil

It works.

0
source

If you create packages using the packagemaker command line mode, you will need to create a dummy directory that contains all your files in the right place. For example, if you need to install files A and B in /Library/Applications/ and /Library/Application Support/ respectively, then you will create a structure as shown below.

Create a temporary directory, say SourceFiles . Add your files to this directory as follows:

 SourceFiles/Library/Applications/A SourceFiles/Library/Application Support/B 

Now use the -root flag in packagemaker command line mode.

 packagemaker --root SourceFiles/ OTHER_OPTIONS 

The idea is that instead of passing individual files to a command, you create a similar structure in a temporary directory and simply pass that directory as an argument to the -root flag.

More for command line mode for packagemaker: http://macinstallers.blogspot.in/

0
source

All Articles