]> git.street.me.uk Git - andy/viking.git/blobdiff - win32/installer.bat
[WINDOWS] Enable optional install of GPSBabel 1.5.1
[andy/viking.git] / win32 / installer.bat
index 56bd33fcf0cb4e2f757ad1fde131a87956986b58..44b8dab490f00f6c7b1112c7456da510e0eb0915 100644 (file)
@@ -120,21 +120,15 @@ set /p PWD=<tmp.tmp
 del tmp.tmp\r
 cache\%GTK_RUNTIME% /sideeffects=no /setpath=no /dllpath=root /translations=no /compatdlls=yes /S /D=%PWD%\%DESTINATION%\r
 \r
+echo Copying GPSBabel Installer
+mkdir %DESTINATION%\Optional
+%MYCOPY% cache\GPSBabel-1.5.1-Setup.exe %DESTINATION%\Optional
+if ERRORLEVEL 1 goto Error
+
 ::\r
 echo Copying Translations\r
 %MYCOPY% installer\translations\*nsh %DESTINATION%\r
-\r
-echo Copying GPSBabel\r
-:: Install it from http://www.gpsbabel.org/download.html\r
-::  Thus GPSBabel should be here\r
-:: NB GPSBabel has standard GPL2 COPYING.txt file so don't need another copy\r
-if exist "%ProgramFiles%\GPSBabel\gpsbabel.exe" (\r
-       %MYCOPY% "%ProgramFiles%\GPSBabel\gpsbabel.exe" %DESTINATION%\r
-       %MYCOPY% "%ProgramFiles%\GPSBabel\libexpat.dll" %DESTINATION%\r
-) else (\r
-       echo GPSBabel missing\r
-       goto Tidy\r
-)\r
+if ERRORLEVEL 1 goto Error
 \r
 echo Running NSIS (command line version)\r
 pushd installer\r
@@ -145,6 +139,11 @@ if exist "%ProgramFiles%\NSIS" (
 )\r
 popd\r
 \r
-echo Tidy Up\r
+goto Tidy
+
+:Error
+echo Exitting due to error: %ERRORLEVEL%
+
 :Tidy\r
+echo Tidy Up
 rmdir /S /Q %DESTINATION%\r