On Sat, Jul 4, 2015 at 3:57 AM, Heikki Linnakangas wrote:
> Hmm. Why is install.bat not like build.bat, i.e. just a thin wrapper that
> just calls install.pl, passing all arguments?

I guess we just haven't noticed it. And indeed it makes everything
more simple, and fixes as well the error reported when install path
contains a space.
-- 
Michael
diff --git a/src/tools/msvc/install.bat b/src/tools/msvc/install.bat
index bed08f1..d03277e 100644
--- a/src/tools/msvc/install.bat
+++ b/src/tools/msvc/install.bat
@@ -1,27 +1,6 @@
 @echo off
 REM src/tools/msvc/install.bat
-
-if NOT "%1"=="" GOTO RUN_INSTALL
-
-echo Invalid command line options.
-echo Usage: "install.bat <path>"
-echo.
-REM exit fix for pre-2003 shell especially if used on buildfarm
-if "%XP_EXIT_FIX%" == "yes" exit 1
-exit /b 1
-
-:RUN_INSTALL
-
-SETLOCAL
-
-IF NOT EXIST buildenv.pl goto nobuildenv
-perl -e "require 'buildenv.pl'; while(($k,$v) = each %%ENV) { print qq[\@SET $k=$v\n]; }" > bldenv.bat
-CALL bldenv.bat
-del bldenv.bat
-:nobuildenv
-
-perl install.pl "%1" %2
-
-REM exit fix for pre-2003 shell especially if used on buildfarm
-if "%XP_EXIT_FIX%" == "yes" exit %ERRORLEVEL%
-exit /b %ERRORLEVEL%
+REM all the logic for this now belongs in install.pl. This file really
+REM only exists so you don't have to type "perl install.pl"
+REM Resist any temptation to add any logic here.
+@perl install.pl %*
-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to