changeset 86:2ea7fe9f9c1d gmap2

Include configuration after we have updated/cloned the maputils repo.
author Matti Hamalainen <ccr@tnsp.org>
date Sun, 16 Oct 2011 01:28:22 +0300
parents c9a78b6a212b
children 4e7d0bc500c4
files tools/makegmaps.php
diffstat 1 files changed, 11 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/tools/makegmaps.php	Sun Oct 16 01:27:33 2011 +0300
+++ b/tools/makegmaps.php	Sun Oct 16 01:28:22 2011 +0300
@@ -26,7 +26,6 @@
 $tradelaneOutXML = $markerPath."tradelane.xml";
 $tradelaneOverXML = $markerPath."troverlay.xml";
 $mkloc = $mapUtils."mkloc";
-require $mapUtils."www/config.inc.php";
 
 $modes = array(
   "xml"     => "markers.xml",
@@ -121,6 +120,17 @@
 $tmp = "cd ".escapeshellarg($rawPath)." && make fetch 2> /dev/null";
 passthru($tmp) == 0 or die("Error executing: ".$tmp."\n");
 
+
+/*
+ * Include continent and tradelane configuration 
+ */
+$config = $mapUtils."www/config.inc.php";
+if (!file_exists($config))
+  die("Required continent/tradelane configuration file '$config' not found.\n");
+
+require $config;
+
+
 /*
  * Generate continents JavasScript file
  */