If you're not from hackclub and you're trying to build a j2me application in 2025, I question your motives but heres the most up to guide on the internet for it.
Extract this tarball file and move its contents into /usr/lib/jvm/java-8-openjdk-32.
Set it as your default jre with sudo archlinux-java set java-8-openjdk-32
- I don't know exactly what you need installed but libraries reported to me include
- lib32-libxtst
- lib32-libxrender
- Self explanatory
- Download this zip file
- extract this file
- You'll use this later
Install Netbeans 8.2. This requires an oracle account so I posted it here.
- Run the installer I linked here
- When asked for jvm, use the java-8-openjdk-32 you installed
- finish installation
- Open tools > plugins
- Install the Mobility Plugin
- Go back to Tools > Plugins
- Open the Downloaded tab
- click Add Plugins
- Select all the plugins from the zip file you used earlier except for the following:
- Java ME SDK CPU Profiler Snapshot Viewer
- Profiler (Java ME Projects Support)
- Profiler Ant Support
- Toolbar core
- Java ME SDK Welcome Screen.
- Install these plugins
- Go back to the main page and select Tools > Java Platforms
- Click
Add Platform
- Select Platform Type: Java ME CLDC Emulators
- Select
/opt/sun-wtk
- Proceed and finish
If this fails, try setting your WTK_JRE_PATH="/usr/lib/jvm/java-8-openjdk-32/" environment variable, and then launching netbeans. If this works, you can add it to /etc/environment
- The examples plugin didn't install for you most likely, but I have extracted the Samples and put them in
Samples/
of this repo - You can also just create a new project (Box icon), select Java ME, and have your fun that way
- I recommend just running Microemulator as its less problematic but the inbuilt emulator can usually be fixed by running
sudo execstack -c /opt/sun-wtk/bin/*.so
. This requires the aur package https://aur.archlinux.org/packages/execstack. Some people report still having issues with Malloc, this seems to be system dependent.
- The run button is broken, install microemulator and build every time you need to run, running
microemulator (yourthing).jad
in the commandline - If you have images to submit to this guide, open a github issue and I'll be happy to add them
- I didn't test this guide exactly in this order, but its still the correct steps to my knowledge