Set icon for application launched by AppleScript?


EDIT: This problem seems to have cleared up when I changed the logic of my script so that all user data and options are stored in their own ~/Library/Application Support folder, and I don’t have to prompt the user to enter a password to make some settings inside the app writable. The change doesn’t seem to be directly related to the icon problem described below, and maybe something else cleared up the problem, but the issue below is not an issue any longer, and this message can be deleted with no loss to the world.

Original message:
I’ve been modifying an AppleScript that I use for launching the SheepShaver emulator (stored inside the AppleScript application), and I’ve been modifying it so that it can be used by multiple users (though not at the same time). One problem I’ve encountered is this:

When I copy the AppleScript application to the Applications folder, and launch it, it launches SheepShaver, and the SheepShaver icon appears in the dock.

But when I log in as a different (admin) user, and launch the AppleScript application (already installed by me in the Applications folder), it launches the SheepShaver app correctly, but only a generic icon appears in the dock.

I can fix this (as the other user) by opening the icns file in Preview, copying it, then using Get Info on and pasting the icon into the generic icon at the top of the Get Info window, but I don’t want to ask users to do this.

I’d like to make the AppleScript set the correct icon before launching SheepShaver, but I can’t figure out a way to accomplish this. I tried building the osxiconsutil package, but it won’t build in Sierra (at least not on my system). Is there any other method available?