#19659 closed defect (othersoftware)
Unpacking josm-macosx.zip with unzip or Archive Utility cause broken JOSM.app
| Reported by: | andygol | Owned by: | team |
|---|---|---|---|
| Priority: | critical | Milestone: | |
| Component: | Core | Version: | tested |
| Keywords: | MacOS, zip, unzip | Cc: | Stereo |
Description
This problem was spotted in the recent 2 releases (16812 and 16731)
Running next command or using brew cask upgrade josm produce broken JOSM.app
➜ unzip josm-macosx.zip
Archive: josm-macosx.zip
inflating: CONTRIBUTION
inflating: LICENSE
inflating: README
creating: JOSM.app/
creating: JOSM.app/Contents/
creating: JOSM.app/Contents/Java/
creating: JOSM.app/Contents/MacOS/
creating: JOSM.app/Contents/PlugIns/
creating: JOSM.app/Contents/Resources/
inflating: JOSM.app/Contents/Info.plist
inflating: JOSM.app/Contents/Java/josm-snapshot-16812.jar
inflating: JOSM.app/Contents/MacOS/JOSM
inflating: JOSM.app/Contents/PkgInfo
inflating: JOSM.app/Contents/Resources/.none
inflating: JOSM.app/Contents/Resources/JOSM.icn
Only way that I found is to use 3rd party app BetterZip to unpack the archive to get valid JOSM.app
This issue was also confirmed by other MacOS fellow mapper.
In case if there were some changes in packaging software could you consider rolling it back or investigate the root cause of the problem to eliminate it.
Attachments (0)
Change History (7)
comment:1 by , 5 years ago
comment:2 by , 5 years ago
| Cc: | added |
|---|
comment:3 by , 5 years ago
Hi @andygol,
It's not clear to me how the zip is borken - what are you expecting, and what is the actual result? In any case, the way josm.openstreetmap.de prepares macOS releases hasn't changed as far as I'm aware.
I've been producing beta-quality releases of JOSM which you can try. It zips so well that it's actually a .zip.zip (actually a github side effect) :).
https://github.com/thomersch/josm/actions/runs/237702945 has my most recent build, where it says "JOSM.app revision 17004". It includes Java 14 and support for Retina displays. You should also install the http2 plugin in it.
comment:4 by , 5 years ago
Hi @Stereo,
I really don't know what is the root of the problem.
I've tested JOSM.app on your link, and I was able to unpack it using different approaches but not unzip.
- I've downloaded your
JOSM.app revision 17004.zipvia Chrome and then tried to unzip it:unzip JOSM.app revision 17004.zip- failed to produce usable JOSM.app, after running unpacked JOSM.app macOS thrown dialogue with the suggestion to move the app to the Trash. (“JOSM” is damaged and can’t be opened. You should move it to the Bin.) 🙅♂️- unpack with
Archive Utility- right click *.zip in Finder and choose "Open With…" - I've got usable JOSM.app 👍 - unpack with
The Unarchiver- right click *.zip in Finder and choose "Open With…" - I've got usable JOSM.app 👍 - unpack with
BetterZip- I've got usable JOSM.app 👍
- Downloading
JOSM.app revision 17004.zipvia Safari, that cause auto extraction files from the archive, produces working JOSM.app. - Downloading current
josm-macosx.zipfrom josm.openstreetmap.de- Safari caused unusable JOSM.app
- Chrome - only
BetterZipcan unpack archive and produce usable JOSM.app, all other tools produce broken JOSM.app
comment:5 by , 5 years ago
It looks like the issue I faced with - https://github.com/electron-userland/electron-builder/issues/4299#issuecomment-544997415
Apple developer support recommended ditto to create the zip, but I'm not sure if this is our end goal... I have not looked into how to fix/work-around electron-builder. Looking for help with that! 😅
/usr/bin/ditto -c -k --keepParent "$APP_PATH" "$ZIP_PATH"
According to instructions from
https://blog.verslu.is/development/appnamis-damaged-and-cant-be-opened-you-should-move-it-to-the-bin/
I run following commands on josm-macosx.zip downloaded from josm.openstreetmap.de and it fix the JOSM.app and it became to be run.
unzip josm-macosx.zip cd ~/Downloads/josm-macosx xattr -d -r com.apple.quarantine ./
also running zip -FF helps to obtain working JOSM.app after unpacking
zip -FF josm-macosx.zip --out josm-macosx-f.zip unzip josm-macosx-f.zip
comment:6 by , 5 years ago
| Resolution: | → othersoftware |
|---|---|
| Status: | new → closed |
Ah! Yes, unzip will strip the Apple signature stuff, and there's not much JOSM can do about it. I ran into that in the github actions too, and, long story short, that's why we currently have the .zip.zip format there.



Additional info