summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Gladman <brg@gladman.plus.com>2010-02-23 08:15:43 +0000
committerBrian Gladman <brg@gladman.plus.com>2010-02-23 08:15:43 +0000
commitc85781d095dc47a812bf68d3fd22c84408d534cf (patch)
tree9b3d7871c96862a7f41821307e26f5b9b8645167
parentd28f2a03a7bfc15d9e783d9421eb759a2ad3e197 (diff)
downloadyasm-c85781d095dc47a812bf68d3fd22c84408d534cf.tar.gz
Hopefully remove python discovery issue in Windows build
svn path=/trunk/yasm/; revision=2292
-rw-r--r--Mkfiles/vc10/genperf/run.bat23
-rw-r--r--Mkfiles/vc9/genperf/run.bat23
2 files changed, 36 insertions, 10 deletions
diff --git a/Mkfiles/vc10/genperf/run.bat b/Mkfiles/vc10/genperf/run.bat
index 4582e28e..f2295c5d 100644
--- a/Mkfiles/vc10/genperf/run.bat
+++ b/Mkfiles/vc10/genperf/run.bat
@@ -1,18 +1,31 @@
cd ..\..\..
@echo off
for /f "usebackq tokens=2,3,4,5,6" %%f in (`reg query HKCR\Python.File\shell\open\command`) do (if %%f==REG_SZ echo %%g %%h %%i %%j >run_py.bat)
-goto answer%errorlevel%
-:answer0
-if not exist run_py.bat goto answer1
+goto ftry%errorlevel%
+
+:ftry0
+goto pyfound
+:ftry1
+for /f "usebackq tokens=2,3,4" %%f in (`reg query HKCR\Python.File\shell\open\command`) do (if %%f==REG_SZ echo %%g %%h >run_py.bat)
+goto stry%errorlevel%
+
+:stry0
+goto pyfound
+:stry1
+goto pynotfound
+
+:pyfound
+if not exist run_py.bat goto notfound
echo ... building with Python ...
@echo on
call run_py.bat modules\arch\x86\gen_x86_insn.py
del run_py.bat
@echo off
goto end
-:answer1
+
+:pynotfound
echo ... building without Python ...
-goto end
+
:end
@echo on
%1 x86insn_nasm.gperf x86insn_nasm.c
diff --git a/Mkfiles/vc9/genperf/run.bat b/Mkfiles/vc9/genperf/run.bat
index 4582e28e..f2295c5d 100644
--- a/Mkfiles/vc9/genperf/run.bat
+++ b/Mkfiles/vc9/genperf/run.bat
@@ -1,18 +1,31 @@
cd ..\..\..
@echo off
for /f "usebackq tokens=2,3,4,5,6" %%f in (`reg query HKCR\Python.File\shell\open\command`) do (if %%f==REG_SZ echo %%g %%h %%i %%j >run_py.bat)
-goto answer%errorlevel%
-:answer0
-if not exist run_py.bat goto answer1
+goto ftry%errorlevel%
+
+:ftry0
+goto pyfound
+:ftry1
+for /f "usebackq tokens=2,3,4" %%f in (`reg query HKCR\Python.File\shell\open\command`) do (if %%f==REG_SZ echo %%g %%h >run_py.bat)
+goto stry%errorlevel%
+
+:stry0
+goto pyfound
+:stry1
+goto pynotfound
+
+:pyfound
+if not exist run_py.bat goto notfound
echo ... building with Python ...
@echo on
call run_py.bat modules\arch\x86\gen_x86_insn.py
del run_py.bat
@echo off
goto end
-:answer1
+
+:pynotfound
echo ... building without Python ...
-goto end
+
:end
@echo on
%1 x86insn_nasm.gperf x86insn_nasm.c