Changeset: e12a7a699162 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=e12a7a699162
Modified Files:
        monetdb4/ChangeLog.Oct2010
        monetdb4/NT/Mserver.bat
        monetdb5/ChangeLog.Oct2010
        monetdb5/NT/M5server.bat
Branch: default
Log Message:

Merge with Oct2010 branch.


diffs (131 lines):

diff --git a/clients/ChangeLog.Oct2010 b/clients/ChangeLog.Oct2010
--- a/clients/ChangeLog.Oct2010
+++ b/clients/ChangeLog.Oct2010
@@ -1,3 +1,7 @@
 # ChangeLog file for clients
 # This file is updated with Maddlog
 
+* Thu Jan 20 2011 Sjoerd Mullender <[email protected]>
+- Fix problem with Windows cmd script if installation folder name
+  contains parentheses.
+
diff --git a/clients/NT/mclient.bat b/clients/NT/mclient.bat
--- a/clients/NT/mclient.bat
+++ b/clients/NT/mclient.bat
@@ -9,10 +9,10 @@
 rem we depend on pthreadVCE.dll having been copied to the lib folder
 set PATH=%MONETDB%\bin;%MONETDB%\lib;%MONETDB%\lib\bin;%PATH%
 
-if "%1"=="/STARTED-FROM-MENU" (
+if not "%1"=="/STARTED-FROM-MENU" goto skip
 shift
 if "%DOTMONETDBFILE%"=="" if exist "%MONETDB%\etc\.monetdb" set 
DOTMONETDBFILE=%MONETDB%\etc\.monetdb
-)
+:skip
 
 rem start the real client
 "%MONETDB%\bin\mclient.exe" %1 %2 %3 %4 %5 %6 %7 %8
diff --git a/monetdb4/ChangeLog.Oct2010 b/monetdb4/ChangeLog.Oct2010
--- a/monetdb4/ChangeLog.Oct2010
+++ b/monetdb4/ChangeLog.Oct2010
@@ -1,3 +1,7 @@
 # ChangeLog file for MonetDB4
 # This file is updated with Maddlog
 
+* Thu Jan 20 2011 Sjoerd Mullender <[email protected]>
+- Fix problem with Windows cmd script if installation folder name
+  contains parentheses.
+
diff --git a/monetdb4/NT/Mserver.bat b/monetdb4/NT/Mserver.bat
--- a/monetdb4/NT/Mserver.bat
+++ b/monetdb4/NT/Mserver.bat
@@ -14,28 +14,25 @@
 
 rem prepare the arguments to Mserver to tell it where to put the dbfarm
 
-rem do this in two if statements because of weird command interpreter
-if "%APPDATA%" == "" (
+if "%APPDATA%" == "" goto usevar
+rem if the APPDATA variable does exist, put the database there
+set MONETDBDIR=%APPDATA%\MonetDB4
+set MONETDBFARM="--dbfarm=%MONETDBDIR%\dbfarm"
+goto skipusevar
+:usevar
 rem if the APPDATA variable does not exist, put the database in the
 rem installation folder (i.e. default location, so no command line argument)
 set MONETDBDIR=%MONETDB%\var\MonetDB4
-) else (
-rem if the APPDATA variable does exist, put the database there
-set MONETDBDIR=%APPDATA%\MonetDB4
-)
-if "%APPDATA%" == "" (
 set MONETDBFARM=
-) else (
-set MONETDBFARM="--dbfarm=%MONETDBDIR%\dbfarm"
-)
+:skipusevar
 
 rem the XQuery log directory used to be in %MONETDBDIR%, but we now
 rem prefer it inside the dbfarm, so move it there
 
-if exist "%MONETDBDIR%\xquery_logs" (
+if not exist "%MONETDBDIR%\xquery_logs" goto skipmove
 for /d %%i in ("%MONETDBDIR%"\xquery_logs\*) do move "%%i" 
"%MONETDBDIR%\dbfarm"\%%~ni\xquery_logs
 rmdir "%MONETDBDIR%\xquery_logs"
-)
+:skipmove
 
 rem start the real server
 "%MONETDB%\bin\Mserver.exe" --set "prefix=%MONETDB%" --set 
"exec_prefix=%MONETDB%" %MONETDBFARM% %*
diff --git a/monetdb5/ChangeLog.Oct2010 b/monetdb5/ChangeLog.Oct2010
--- a/monetdb5/ChangeLog.Oct2010
+++ b/monetdb5/ChangeLog.Oct2010
@@ -1,3 +1,7 @@
 # ChangeLog file for MonetDB5
 # This file is updated with Maddlog
 
+* Thu Jan 20 2011 Sjoerd Mullender <[email protected]>
+- Fix problem with Windows cmd script if installation folder name
+  contains parentheses.
+
diff --git a/monetdb5/NT/M5server.bat b/monetdb5/NT/M5server.bat
--- a/monetdb5/NT/M5server.bat
+++ b/monetdb5/NT/M5server.bat
@@ -14,28 +14,25 @@
 
 rem prepare the arguments to mserver5 to tell it where to put the dbfarm
 
-rem do this in two if statements because of weird command interpreter
-if "%APPDATA%" == "" (
+if "%APPDATA%" == "" goto usevar
+rem if the APPDATA variable does exist, put the database there
+set MONETDBDIR=%APPDATA%\MonetDB5
+set MONETDBFARM="--dbfarm=%MONETDBDIR%\dbfarm"
+goto skipusevar
+:usevar
 rem if the APPDATA variable does not exist, put the database in the
 rem installation folder (i.e. default location, so no command line argument)
 set MONETDBDIR=%MONETDB%\var\MonetDB5
-) else (
-rem if the APPDATA variable does exist, put the database there
-set MONETDBDIR=%APPDATA%\MonetDB5
-)
-if "%APPDATA%" == "" (
 set MONETDBFARM=
-) else (
-set MONETDBFARM="--dbfarm=%MONETDBDIR%\dbfarm"
-)
+:skipusevar
 
 rem the SQL log directory used to be in %MONETDBDIR%, but we now
 rem prefer it inside the dbfarm, so move it there
 
-if exist "%MONETDBDIR%\sql_logs" (
+if not exist "%MONETDBDIR%\sql_logs" goto skipmove
 for /d %%i in ("%MONETDBDIR%"\sql_logs\*) do move "%%i" 
"%MONETDBDIR%\dbfarm"\%%~ni\sql_logs
 rmdir "%MONETDBDIR%\sql_logs"
-)
+:skipmove
 
 rem start the real server
 "%MONETDB%\bin\mserver5.exe" --set "prefix=%MONETDB%" --set 
"exec_prefix=%MONETDB%" %MONETDBFARM% %*
_______________________________________________
Checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list

Reply via email to