Inquiry Regarding Gatekeeper Behavior During Application Upgrade

Can you please help us with the scenario below, including details and Apple’s recommendations?

I've already read through the Notarization and Gatekeeper documentation.

The installed version of our application is 1.2.3, located in /Applications/XYZSecurity.app.

We created an upgrade package for version 1.2.4. As part of the pre-install script in the 1.2.4 installer, we explicitly deleted some obsolete .dylib files from /Applications/XYZSecurity.app/Contents/Frameworks and some executable files from /Applications/XYZSecurity.app/Contents/MacOS that were no longer needed in version 1.2.4.

The installation of version 1.2.4 completed successfully, but we see the below error logs in installer.log:

PackageKit: Failed to unlinkat file reference /Applications/XYZSecurity.app/Contents/Frameworks/libhelper.dylib

PackageKit: Failed to unlinkat file reference /Applications/XYZSecurity.app/Contents/MacOS/helper-tool

Our Key Questions:

  1. Is it the right practice to remove obsolete files in the pre-install script during an upgrade?
  2. Is this approach recommended by Apple?
  3. Can this cause any issues with Apple Gatekeeper? Is there a possibility of my application getting blocked by Gatekeeper as a result?
  1. Is it the right practice to remove obsolete files in the pre-install script during an upgrade?

No. In general, you should leave the installing to the installer. Modifying a previously installed app from a pre-install script is likely to bump in to app bundle protection. I have a link to the WWDC session discussing that in Trusted Execution Resources.

Just to be clear, you’re trying to create a delta installer, right? That is, an installer package that upgrades version 1.2.3 to version 1.2.4?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Inquiry Regarding Gatekeeper Behavior During Application Upgrade
 
 
Q