On Fri, 3 Oct 2025 23:50:07 GMT, Alexander Matveev <[email protected]> wrote:

>> - Removed pre- and post- installation PKG scripts.
>> - This code is not needed and PKG should create destination folder and set 
>> correct permissions.
>> - If for some reason it is not happens, permissions issues should be fixed 
>> when jpackage prepares application bundle. PKG should keep all permissions 
>> unchanged when packaging and installing bundle.
>> - Users will have ability to provide pre- and post- installation PKG scripts 
>> if needed.
>> - `INSTALL_LOCATION` and `APP_LOCATION` substitution is removed, since `$2` 
>> argument in scripts is same as `INSTALL_LOCATION`.
>> - I think code in these scripts are some legacy leftovers.
>> - Added test to test that pre- and post-scripts are no longer exist and can 
>> be added via `--resource-dir`.
>
> Alexander Matveev has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   8356047: [macos] jpackage produces confusing post- and pre- installation 
> PKG scripts [v5]

test/jdk/tools/jpackage/macosx/PkgScriptsTest.java line 114:

> 112:         if (exists) {
> 113:             TKit.assertFileExists(scriptPath);
> 114:             TKit.assertTrue(Files.isExecutable(scriptPath), String.format

Should we check that the owner can execute the file instead of checking if the 
JVM can execute it?

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/25510#discussion_r2408162200

Reply via email to