Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8444509
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T09:24:37+00:00 2026-06-10T09:24:37+00:00

For installation of my Windows desktop application I create an installer using izpack and

  • 0

For installation of my Windows desktop application I create an installer using izpack and then call it from an exe using winrun4j, also part of the izpack installation add another winrun4j wrapper for actually running the application once installed.

The trouble is that for the win4runj.exe to work it needs to be using the correct Java type, i.e if exe is 64bit it must run 64 bit jvm, if exe is 32 bit it must run 32bit jvm. This can be confusing for the user so I was going to take advantage of winrun4j to use an embedded jvm and then make two downloads available

  • widgetinstaller.exe (32-bit)
  • widgetinstaller64.exe (64-bit)

But my confusion is that for each download I only want to embed the jvm once but cannot work out how to do this because i have two exes (the installer, and the program itself) , can this be done ?

Update

Have it working if I install JVM twice (once included in install.jar when built with izpack, and once added to the zip file so can be used by widgetinstaller.exe).

  • widgetinstaller.exe resides in c:\code\widget\installer
  • Download 32bit jre from Oracle
  • Install into c:\code\widget\32bitJVM
  • Edit izpack.xml, adding <file src="C:/code/widget/JVM32bit" targetdir="$INSTALL_PATH"/>
  • Add for installer vm.location=32bitJVM/bin/client/JVM.dll to c:\code\widget\installer\widgetinstaller.ini
  • Add for widget itself vm.location=../32bitJVM/bin/client/JVM.dll to c:\code\widget\widget.ini
  • Rebuild code, and zip up including 32bitJVM in the zip file to create widgetinstaller.zip (this contains 32bitJVM, widgetinstaller.ini,widgetinstaller.exe, widgetinstaller.ico and install.jar)
  • Unzip and double-click on widgetinstaller.exe to install

But I only want JVM once, I know I need to remove the <file src="C:/code/widget/JVM32bit" targetdir="$INSTALL_PATH"/> from izpack.xml, but then how do I copy my 32bitJVM into program installation folder

that same JVM needs to be saved to the program folder.

Seems this has to be done outside of izpack itself ?

EDIT

Solution is to use Izpack loose packs described at at Can I install a file using Izpack 5 without it being part of the install.jar built by izpack

but it is quite confusing what must be set for the path, documentation incorrectly implies you put in a relative link http://izpack.org/documentation/installation-files.html#the-packs-element-packs.

Example

izpack install.xml is in C:\code\Widget\installer

<pack name="Base" loose="true" required="yes" preselected="yes">
   <description>JVM</description>
   <file src="C:\Code\Widget\JVM" targetdir="$INSTALL_PATH"/>
</pack>

When package up izpack installation should have:

JVM
install.jar
setup.exe
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T09:24:38+00:00Added an answer on June 10, 2026 at 9:24 am

    If the JVM is embedded in the installer then the program cannot use it.
    And again if the JVM is embedded in the program then the installer cannot use it.

    However you can still do it with only one JVM. This is done by coping the JVM to a local file.

    So when you launch the installer with the winrun4j it will launch from the embedded JVM, then at the end of the installation, that same JVM needs to be saved to the program folder.

    Your program winrun4j exe can then use the JVM that you saved to the folder to launch the program, you do this by setting the “vm.location” in winrun4j to the location of the saved JVM.

    Process:
    1) Run the installer exe with the required JVM
    2) During the installation save the embedded JVM to a file
    3) Once the instillation is complete the program exe can launch using the saved JVM
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Upon installation of a Windows Service, an application is using a custom action to
I have set up a Redmine installation on a Windows server using the BitNami
I have a 32-bit application and a 32-bit installer, written in Wise Installation Studio.
I'm using the default Cygwin installation on a Windows 7 machine. When I try
I tested my installer on netbook running Windows 7 Starter logged in using a
Our company recently upgraded from Windows XP to Windows 7 Enterprise. The JDK installation
I am starting the RoR 3 Video Tutorial, doing the windows installation using cygwin
I have a windows 7 x64 desktop with vs2010 and a virtual box installation
I have an existing python3 installation in Windows, but things aren't really configured right.
1)how can i find out the Windows Installation drive in which the user is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.