Re: Expected behavior for upgrades with changed file locations
site_archiver@lists.apple.com Delivered-To: installer-dev@lists.apple.com Generally speaking, files that exist in the payload of version n of a package that do not exist in the payload of version m (where m > n) of the package (where both packages share the same package id) are _removed_ when version m of the package is installed. That's the intended behavior. Your mention of "local domain" has me a bit confused though. If by this phrase you are referring to the /Library/LaunchAgents and /Library/LaunchDaemons directories, then what I wrote above still stands. Things may (will) get more complicated if/when the installer writes to a user's home directory. Pre- and post- scripts should be avoided except when absolutely necessary, if for no other reason than they are frequently written with assumptions that are incorrect, especially when the package is installed by a method other than a user double-clicking it to run it interactively with Installer.app. Bad assumptions on the part of the script writer are the #1 reason packages fail to install correctly in an InstaDMG workflow, via the command line, when at the loginwindow with no GUI user, and when applied to a non-boot volume. -Greg On Jan 25, 2011, at 10:51 AM, Jeremy Reichman wrote:
What is the expected behavior for upgrades of existing packages -- specifically packages in 10.4 format -- that have changed file layouts since the last version was installed? If there is a difference in behavior for packages in 10.4 vs. 10.5 format, I'd be interested in knowing about that.
For example, let's say package version 2.1 installed a LaunchAgent in the local domain, but version 2.5 no longer needs that and does _not_ come with it in its package payload. Version 2.5 happens to install a local domain LaunchDaemon instead. Both packages have the same ID. There are no installer components or user choices available. Without any scripts, would the upgrade of version 2.5 over 2.1 be expected to remove the no-longer-in-payload LaunchAgent or not?
I have seen plenty of examples of installers removing (as well as adding, obviously) files during upgrades, but I haven't investigated whether those removals were driven by scripts or the package payload. I tend to see a lot of talk about reliance on scripts for upgrades and I want to know whether that is really necessary or not.
Thanks!
-- Jeremy
_______________________________________________ Do not post admin requests to the list. They will be ignored. Installer-dev mailing list (Installer-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/installer-dev/greg.neagle%40disneyani...
This email sent to greg.neagle@disneyanimation.com
_______________________________________________ Do not post admin requests to the list. They will be ignored. Installer-dev mailing list (Installer-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/installer-dev/site_archiver%40lists.a... This email sent to site_archiver@lists.apple.com
participants (1)
-
Greg Neagle