diff options
author | Brian Gladman <brg@gladman.plus.com> | 2010-02-24 11:26:40 +0000 |
---|---|---|
committer | Brian Gladman <brg@gladman.plus.com> | 2010-02-24 11:26:40 +0000 |
commit | 40ab77b4d03c079010f66ce37355ec7e6ae253c1 (patch) | |
tree | 36c47f5fefb55fc8692835ce812cb0cc82ddf474 | |
parent | e6fd6d7af1d5fa6135d6c89de9ffd8832a80f145 (diff) | |
download | yasm-40ab77b4d03c079010f66ce37355ec7e6ae253c1.tar.gz |
Make a further attempt to use the Windows registry to find Python
svn path=/trunk/yasm/; revision=2294
-rw-r--r-- | Mkfiles/vc10/genperf/run.bat | 27 | ||||
-rw-r--r-- | Mkfiles/vc9/genperf/run.bat | 27 |
2 files changed, 12 insertions, 42 deletions
diff --git a/Mkfiles/vc10/genperf/run.bat b/Mkfiles/vc10/genperf/run.bat index dc39a570..b2aed9ed 100644 --- a/Mkfiles/vc10/genperf/run.bat +++ b/Mkfiles/vc10/genperf/run.bat @@ -1,33 +1,18 @@ 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 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
+del run_py.bat
+for /f "usebackq tokens=2*" %%f in (`reg query HKCR\Python.File\shell\open\command`) do (if %%f==REG_SZ echo %%g >run_py.bat)
+@echo on
+if exist run_py.bat goto pyfound
+echo ... building without Python ...
+goto end
:pyfound
-if not exist run_py.bat goto pynotfound
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
-
-:pynotfound
-echo ... building without Python ...
:end
-@echo on
%1 x86insn_nasm.gperf x86insn_nasm.c
%1 x86insn_gas.gperf x86insn_gas.c
%1 modules\arch\x86\x86cpu.gperf x86cpu.c
diff --git a/Mkfiles/vc9/genperf/run.bat b/Mkfiles/vc9/genperf/run.bat index dc39a570..b2aed9ed 100644 --- a/Mkfiles/vc9/genperf/run.bat +++ b/Mkfiles/vc9/genperf/run.bat @@ -1,33 +1,18 @@ 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 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
+del run_py.bat
+for /f "usebackq tokens=2*" %%f in (`reg query HKCR\Python.File\shell\open\command`) do (if %%f==REG_SZ echo %%g >run_py.bat)
+@echo on
+if exist run_py.bat goto pyfound
+echo ... building without Python ...
+goto end
:pyfound
-if not exist run_py.bat goto pynotfound
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
-
-:pynotfound
-echo ... building without Python ...
:end
-@echo on
%1 x86insn_nasm.gperf x86insn_nasm.c
%1 x86insn_gas.gperf x86insn_gas.c
%1 modules\arch\x86\x86cpu.gperf x86cpu.c
|