You are not logged in.


*** NOTICE: By 30th of September 2022 the will be retired, please request a category for your community in the new ones as soon as possible using this process, which will allow you to propose your community moderators. We expect the migration of data will be finished by that date, you can follow its progress here.***

#1 2014-03-26 02:21:07

From: SE Queensland, Australia
Registered: 2013-04-11
Posts: 447

mkgmap & Unsupported major.minor version 51.0

After editing late in the day, I am trying to make a new map to load on my eTrex that highlights the remaining un-named ways for the next day, using mkgmap and a download of an .osm file using Josm of part of a suburb, using the following command as an initial trial.

java -jar /Applications/mkgmap-r3118/mkgmap.jar --gmapsupp --style=noname /Users/xxxx/Documents/JOSM/Save_OSM_file/nonametest.osm

and I get the following advice...

Exception in thread "main" java.lang.UnsupportedClassVersionError: uk/me/parabola/mkgmap/main/Main : Unsupported major.minor version 51.0
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClassCond(
    at java.lang.ClassLoader.defineClass(
    at Method)
    at java.lang.ClassLoader.loadClass(
    at sun.misc.Launcher$AppClassLoader.loadClass(
    at java.lang.ClassLoader.loadClass(

I assume a version incompatibility with mkgmap and my java version

java -version
java version "1.6.0_65"
Java(TM) SE Runtime Environment (build 1.6.0_65-b14-462-10M4609)
Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-462, mixed mode)

I can't run java 1.7 on this machine (would it help if I used a later mac that could?)

System Version:    Mac OS X 10.6.8 (10K549) Snow Leopard
Kernel Version:    Darwin 10.8.0

I also tried these commands with the same result...
java -jar /Applications/mkgmap-r3118/mkgmap.jar --list-styles
java -jar /Applications/mkgmap-r3118/mkgmap.jar --version

I would appreciate a point in the next direction please...

Does the info below confirm that I must run java 7 for mkgmap?

major version number of the class file format being used.
J2SE 8 = 52 (0x34 hex),
J2SE 7 = 51 (0x33 hex),
J2SE 6.0 = 50 (0x32 hex),
J2SE 5.0 = 49 (0x31 hex),
JDK 1.4 = 48 (0x30 hex),
JDK 1.3 = 47 (0x2F hex),
JDK 1.2 = 46 (0x2E hex),
JDK 1.1 = 45 (0x2D hex).

Further Edit:

...belatedly found this


You need to download the following software / tools:

    Java Runtime Environment 1.7 from

Install Java Runtime Environment 1.7. Both mkgmap and splitter depend upon it.

That seems plain enough even for me now - I must have a later Java version installed and this can't be done on this machine?
Is it likely that the developers of mkgmap will recompile a version of the program in the near future so that it runs under java 1.6?

Last edited by nevw (2014-03-26 04:45:35)


#2 2014-03-26 09:39:25

Registered: 2008-10-09
Posts: 5,353

Re: mkgmap & Unsupported major.minor version 51.0

As far as I know Java 1.6 isnt supported anymore, better ask it on the mkgmap development list:


Board footer

Powered by FluxBB