This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Support JVM bundling with other than Info-Zip | ||
---|---|---|---|
Product: | apisupport | Reporter: | phansson |
Component: | NBI | Assignee: | Libor Fischmeistr <lfischmeistr> |
Status: | NEW --- | ||
Severity: | normal | ||
Priority: | P3 | ||
Version: | 7.4 | ||
Hardware: | PC | ||
OS: | Windows 7 | ||
Issue Type: | ENHANCEMENT | Exception Reporter: | |
Attachments: | JRE bundle size test |
Description
phansson
2013-12-08 13:11:45 UTC
Created attachment 143081 [details]
JRE bundle size test
Results of test: Info-ZIP will create an archive of approx 38 MBytes while 7Zip can do the same archive in approx 24 MBytes. This is a very significant difference !
JRE bundle size test: Info-ZIP : 38 MBytes 7Zip : 24 MBytes See attachment for further details. This explains why this RFE will bring a *significant* benefit. Here's how to fix. You only need to REMOVE code. In the "NBI Native Launcher : Windows" project locate source file JavaUtils.c. Locate function installJVM() within that file. Locate the two lines: appendCommandLineArgument(&command, L"-d"); appendCommandLineArgument(&command, jvmDir); and replace instead with: // Adding "-d" to command line on self-extracting archive is not a very // good idea because it means NBI will only work with self-extracting archives // binaries that actually understands this option (for example Info-ZIP will understand it, // 7Zip will not). The argument means "extract to this directory", but that // is unnecessary as the executeCommand() below will already have a 'working directory' // argument attached to it ... so even without the -d option we still get our // archive extracted into the right location. For this reason the following two // lines have been removed. //appendCommandLineArgument(&command, L"-d"); //appendCommandLineArgument(&command, jvmDir); The comments I've added above hopefully explains why the change is solely a benefit and has no adverse effects. I've used the change successfully in my own projects. (where I package with 7Zip, not Info-Zip, in order to save the extra 40-50% on package size). Just for the record: The equivalent change is *not* required in launcher.sh (for Unix/linux/MacOSX) since the launcher.sh is not trying to add "-d" option to the command. Any updates on this? |