You are here

[Fixed] jdkPortable doesn't "unpack" .pack files.

2 posts / 0 new
Last post
3D1T0R
3D1T0R's picture
Offline
Last seen: 15 hours 47 min ago
Developer
Joined: 2006-12-29 23:48
[Fixed] jdkPortable doesn't "unpack" .pack files.

Limeroli posted a comment on the release thread for jdkPortable 8 Update 131, indicating that our jdkPortable installer is currently missing a step. Specifically, that it should use "unpack200.exe", which is included in the JDK, to "unpack" several .jar files from the .pack files that come in the JDK installer.

Upon further inspection, I believe that this is correct, and (using existing installers with special requirements as a guide) I wrote the following two files to be inserted into the Other\Source directory in order to satisfy this requirement:

PortableApps.comInstallerPluginCustom.nsh

!macro CustomCodePostInstall
	nsExec::ExecToLog `"$INSTDIR\Other\Source\unpack200.bat"`
!macroend

unpack200.bat

:: This gets run by the installer from the root of the installation
:: to "unpack" the .pack files into proper .jar files.
@for /R %%f in (*.pack) do ("bin\unpack200.exe" -rv "%%f" "%%~dpnf.jar" | find "Unpacking")

Seeing as the lack of this step makes the JDK effectively unusable as a JDK, I feel we should make a "Rev 2" release, however seeing as jdkPortable is not currently in the PortableApps.com Updater/App Directory, I don't feel it's a particularly high priority.

Also, please note that I did see that there was disabled code for this purpose in the Java CommonFiles Plugin installer, however the code above is more concise and readable, it shows updates the install log (which is nice for us users who click "Show details"), and it's more future proof as new releases of the JDK may come with other .pack files which will also need to be unpacked.

John T. Haller
John T. Haller's picture
Offline
Last seen: 5 hours 45 min ago
AdminDeveloperModerator
Joined: 2005-11-28 22:21
Fixed in 8u144

This is fixed with today's jdkPortable release.

Sometimes, the impossible can become possible, if you're awesome!

Log in or register to post comments