logo separator

[mkgmap-dev] mkgmap -c problem (relative paths)

From Gerd Petermann gpetermann_muenchen at hotmail.com on Thu Mar 7 10:09:18 GMT 2019

Hi Ranko,

yes, this behavious is a bit confusing, but I think we cannot change it without breaking compability.
A typical scenario is this:
splitter is executed and creates a template.args file contining something like
mapname: 63240001
input-file: 63240001.o5m

mapname: 63240002
input-file: 63240002.o5m

When mkgmap processes the file it also presumes that file 63240001.o5m is in the same directory as template.args.
So, I'll change documentation but not the code. OK?


Von: mkgmap-dev <mkgmap-dev-bounces at lists.mkgmap.org.uk> im Auftrag von Ranko Jaksic <ranko.jaksic at zgi.hr>
Gesendet: Mittwoch, 6. März 2019 22:22
An: mkgmap-dev
Betreff: [mkgmap-dev] mkgmap -c problem (relative paths)


I use config files with mkgmap and define input-files using relative paths.
Example from my config file "osm-options":

mapname: 80100003
input-file: data/80100003.osm.pbf

This works well when the config file is in the same directory where mkgmap is started.
When invoked with "-c osm-options" mkgmap finds my input file just fine.

To tidy up my environment I moved all my config files into a config subdirectory.
Now when I invoke mkgmap with "-c config/osm-options" I get the following error:

SEVERE (Main): .\config\data\80100003.osm.pbf: file .\config\data\80100003.osm.pbf doesn't exist

It appears that mkgmap interprets my relative paths relative to the config file location,
and not (as I expected) the mkgmap cwd!

This seems to be a bug since the description for -c states:
"The options are included as arguments of the executed command as if they had been specified on the command line."

I tested using the latest r4282 on Windows.


mkgmap-dev mailing list
mkgmap-dev at lists.mkgmap.org.uk

More information about the mkgmap-dev mailing list