Re: PackageMaker Installer
Re: PackageMaker Installer
- Subject: Re: PackageMaker Installer
- From: "Bryan S. Lee" <email@hidden>
- Date: Wed, 17 Dec 2008 22:57:14 -0500
- Thread-topic: PackageMaker Installer
Title: Re: PackageMaker Installer
Try this script. Does basically what you want. The distribution package installs the .dmg file to a /tmp location, then this is called as a postscript that will put the contents where you want them. In this case, it’s installing a Telnet application (TN3270X) in the /Applications/TN3270X folder and also copies a preset preferences file to the user’s Library/Preferences folder.
#!/bin/bash
PATH=/bin:/usr/bin:/sbin:/usr/sbin export PATH
###################################################
### Install Tn3270X ###
###################################################
### make directories for files
mkdir -p /private/tmp/myinstaller/tn3270x
mkdir -p /Applications/TN3270X
chmod 775 /Applications/TN3270X
### mount dmg silently to temp directory
hdiutil attach -private -mountpoint /private/tmp/myinstaller/tn3270x/tn3270x /private/tmp/myinstaller/tn3270x/tn3270x.dmg
### copy
ditto /private/tmp/myinstaller/tn3270x/tn3270x /Applications/TN3270X
cp /private/tmp/myinstaller/tn3270x/tn3270\ preferences /Users/$USER/Library/Preferences/tn3270\ preferences
## unmount dmg
hdiutil detach -force /private/tmp/myinstaller/tn3270x/tn3270x
### remove files from system
rm -rf /private/tmp/myinstaller/tn3270x
--
Bryan S. Lee
--
Bryan S. Lee
Information Resource Consultant II
Computer Support Services
Clemson Computing and Information Technology
Clemson University
864-656-3716
email@hidden
ACHDS 10.4, MCP NTS/NTW
From: Dave <email@hidden>
Date: Tue, 16 Dec 2008 12:58:07 -0500
To: <email@hidden>
Subject: PackageMaker Installer
Hi All,
Prior to MacOS 10.5.x I had an AppleScript based installer as so:
1. A .dmg file containing an Installer AppleScript Application
(called "Double Click to Install & Launch".app) and a Folder. The
Installer copies the folder from the image to "/Applications" on the
system volume.
2. Once the folder had been copied, it launches another AppleScript
App (called "CleanUp.app"). This ejects the image and launches the
main application.
This has worked wonderfully since MacOS X 10.3.x.
There 10.5.x was released and the above still works BUT, we get 4 or
5 security dialogs as so:
When the user attempts to mount the Image file, the OS displays the
"File downloaded from Internet" dialog, this is ok, however, after
that, when the user launches "Install.app" a similar dialog appears,
the same goes for "Cleanup.app" and for "RealApp.app", so we get 4
dialogs in total. Obviously this is unacceptable so I posted to the
Cocoa list and was advised to use PackageMaker to build an installer.
So I built an installer but I can't get it to install the folder
containing the files, so far I have only managed to get it to install
the myApp.app file.
I have read "PackageMaker User Guide" and AFAIK have following the
instructions given there. Basically I just drag the folder containing
the files to the PackageMaker project window and then set the setting
as appropriate.
So, my question is:
Is it possible to create an installer with PackageMaker that does the
same as the AppleScript, e.g. installs a folder in "/Applications"
that contains the Application and other files?
Thanks a lot
All the Best
Dave
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden