B4J Question B4j - How to generate 32bit .exe

WebQuest

Active Member
Licensed User
Hello community,
I try to generate the 32bit executable file.
Through the Bulid standalone Packager I successfully generate the 64-bit .exe. I need the executable which runs on win10 at 32bit.
I have followed several discussions but without success.
I used Packager 1.50 with jdk.1.8.0_131 as described in a discussion by Erel.
When I compile I am shown this log:

LOG:
Waiting for debugger to connect ...
Program started.
App identifier: b4j.List.main
No JDK base. Package will use system JRE.
No JDK base. Package will use system JRE.
Running [C: \ Program Files \ Java \ jdk1.8.0_131 \ jre \ bin \ java, -version]
Bundler EXE Installer skipped because of a configuration p
Bundler EXE Installer skipped because of a configuration problem: Can not find Inno Setup Compiler (iscc.exe).
Advice to fix: Download Inno Setup 5 or later from http://www.jrsoftware.org and add it to the PATH.
Success: true
ExitCode: 0

I downloaded Inno Setup.
But despite everything I don't know how to detect the path
Has anyone ever compiled at 32bit?
 

agraham

Expert
Licensed User
Longtime User
You are not really compiling for 32bit - a jar is usually size independent, it is the Java Runtime Environment that is size dependent. There are JREs for Java 8 in 32 and 64 bit but Java 11 is 64 bit only. If you compile using Java 8 if a suitable JRE is installed on the computer then double clicking the jar should run it - this is not the case for Java 11.

For the installer the PATH referenced is either of the user or system environment Path variables and I guess it should b set to the path of the folder where iscc.exe is located.
 
Upvote 0

WebQuest

Active Member
Licensed User
Hi agraham,
I tried to follow your advice but the .jar file does not work on win 10 64bit nor on win 10 32 bit. I compiled the app with jdk ver 8 but it doesn't work.
 
Upvote 0

Gandalf

Member
Licensed User
Longtime User
Several years ago I needed 32bit standalone package. The way it worked for me:
1. Download and install Java 8 32bit on PC where B4J is installed.
2. Add this to #Region Project Attributes (change the path to where Java 8 is installed):
#JavaCompilerPath: 8, C:\java\jdk1.8.0_291\bin\javac.exe
3. Run in Release mode to generate jar file.
4. Use Launch4J to make standalone package. Here is the tutorial (press Spoiler button to see it).

On 32bit old Linux PC I was able to run this jar file using Liberica Java 8 32bit JRE for Linux.
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…