Explorar el Código

winGRASS: fix bat wrapper generation for addons (patch provided by glynn, see https://trac.osgeo.org/grass/ticket/2150)

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@61715 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa hace 10 años
padre
commit
f6c33aadb5
Se han modificado 2 ficheros con 3 adiciones y 2 borrados
  1. 2 1
      include/Make/Script.make
  2. 1 1
      scripts/windows_launch.bat

+ 2 - 1
include/Make/Script.make

@@ -20,12 +20,13 @@ include $(MODULE_TOPDIR)/include/Make/ScriptRules.make
 SCRIPT_ACTIONS = $(SCRIPT) $(ETCPYFILES) $(ETCPYCFILES) html scriptstrings
 ifdef MINGW
 SCRIPT_ACTIONS += $(BIN)/$(PGM).bat
+SCRIPT_DIR = %GISBASE%/scripts
 endif
 
 script: $(SCRIPT_ACTIONS)
 
 $(BIN)/$(PGM).bat: $(MODULE_TOPDIR)/scripts/windows_launch.bat
-	sed -e "s#SCRIPT_NAME#$(PGM)#" $(MODULE_TOPDIR)/scripts/windows_launch.bat > $@
+	sed -e "s#SCRIPT_NAME#$(PGM)#" -e "s#SCRIPT_DIR#$(SCRIPT_DIR)#" $(MODULE_TOPDIR)/scripts/windows_launch.bat > $@
 	unix2dos $@
 
 scriptstrings: $(STRINGDIR)/$(PGM)_to_translate.c

+ 1 - 1
scripts/windows_launch.bat

@@ -1 +1 @@
-@"%GRASS_PYTHON%" "%GISBASE%/scripts/SCRIPT_NAME.py" %*
+@"%GRASS_PYTHON%" "SCRIPT_DIR/SCRIPT_NAME.py" %*