logo separator

Background

The mkgmap program is distributed in Java archive format compiled for use under the Java Runtime Environment 8. You will need the Java SE Runtime Environment 8 installed on your system in order to run mkgmap.

Garmin maps consist of a series of .img files, with each file containing the data for one tile of the map. Unless you intend to build a very small map, you will need to use the accompanying splitter program to split your map into smaller tiles. The individual tiles can be joined together to produce a single gmapsupp.img file which contains the whole map and can be copied into the /Garmin folder of an SD card for use by a GPS device. If you want to create more than one map for use on your GPS, the gmapsupp.img files can be renamed to be unique, for example gmapsupp1.img, gmapsupp2.img.

A typical simple example using both splitter and mkgmap:

java.exe -Xmx2g -jar splitter.jar england-latest.o5m
java.exe -jar mkgmap.jar --gmapsupp -c template.args

The first command splits the Open Street Map data into smaller files with each file containing the data for one tile of the map. It also produces a file named template.args that contains the names of all the generated files.

The second command takes as input all the individual files listed in the template.args file generated by splitter, produces a .img file for each tile, then merges all the tiles together into a single gmapsupp.img file.

Documentation

The documentation that is currently available on this site is listed below.

Command line options The mkgmap command line options. This is also available using the command:

mkgmap --help=options

Style Manual [pdf] This is the complete documentation of the style rules that determine how the OSM tagged features are converted into Garmin features.

TYP Compiler Manual This documents the language that is accepted by the TYP compiler that is included within mkgmap.

Logging Instructions on how to control messages that are logged and to where they are written.

Tuning Instructions on how to minimise execution time and avoid running out of memory.

Further information can be found in the Open Street Map wiki

Latest commits

  • mkgmap-r4767 raise minimum resolution of overview map to 13 to match the alignment of tiles produced by splitter with default resolution ....
    11 jun 2021
  • mkgmap-r4766 map-split.patch - fix possible "Problem writing line ..." message which caused data loss of huge polygons.
    11 jun 2021
  • mkgmap-r4765 rework roundabout checks (roundaboutchecks4.patch by Mike Baggaley).
    10 jun 2021
  • mkgmap-r4763 - fix bug in Coord.distToLineSegment(Coord a, Coord b), it returned Double.NaN when a and b are the same.
    08 jun 2021
  • mkgmap-r4760 minor performance tweak: only create node instance when it is needed.
    06 jun 2021
See more...