@@ -16,14 +16,16 @@ IF NOT EXIST "buildPaths.bat" (
1616
1717SET PYTHONSCRIPTDLLDIR = bin
1818SET INST_TEMP_DIR = temp
19- SET NAME_ADDON = " "
19+ SET NAME_ADDON =
20+ SET MSI_ARCH = x86
2021
2122CALL buildPaths.bat
2223
2324IF " %1 " == " x64" SET PYTHONBUILDDIR = %PYTHONBUILDDIR_X64%
2425IF " %1 " == " x64" SET PYTHONSCRIPTDLLDIR = x64
2526IF " %1 " == " x64" SET INST_TEMP_DIR = temp64
2627IF " %1 " == " x64" SET NAME_ADDON = _x64
28+ IF " %1 " == " x64" SET MSI_ARCH = x64
2729
2830IF NOT EXIST " %PYTHONBUILDDIR% \python.exe" (
2931 echo Your PYTHONBUILDDIR in buildPaths.bat does not contain python.exe. Please set PYTHONBUILDDIR to the root of a built Python 2.7
@@ -48,7 +50,7 @@ if NOT [%ERRORLEVEL%]==[0] (
4850)
4951
5052echo Compiling python lib WiX source
51- candle %INST_TEMP_DIR% \fullLib.wxs -o %INST_TEMP_DIR% \fullLib.wixobj -dpylibSource=..\pythonlib\full
53+ candle %INST_TEMP_DIR% \fullLib.wxs -o %INST_TEMP_DIR% \fullLib.wixobj -dpylibSource=..\pythonlib\full -arch %MSI_ARCH%
5254if NOT [%ERRORLEVEL% ]== [0] (
5355 goto error
5456)
@@ -60,7 +62,7 @@ if NOT [%ERRORLEVEL%]==[0] (
6062)
6163
6264echo Compiling python pyd lib WiX source
63- candle %INST_TEMP_DIR% \fullLib_dll%NAME_ADDON% .wxs -o %INST_TEMP_DIR% \fullLib_dll%NAME_ADDON% .wixobj -dpylibSource=..\pythonlib\full_dll%NAME_ADDON%
65+ candle %INST_TEMP_DIR% \fullLib_dll%NAME_ADDON% .wxs -o %INST_TEMP_DIR% \fullLib_dll%NAME_ADDON% .wixobj -dpylibSource=..\pythonlib\full_dll%NAME_ADDON% -arch %MSI_ARCH%
6466if NOT [%ERRORLEVEL% ]== [0] (
6567 goto error
6668)
@@ -72,7 +74,7 @@ if NOT [%ERRORLEVEL%]==[0] (
7274)
7375
7476echo Compiling extra lib WiX source
75- candle %INST_TEMP_DIR% \extra.wxs -o %INST_TEMP_DIR% \extra.wixobj -dpylibSource=..\pythonlib\extra
77+ candle %INST_TEMP_DIR% \extra.wxs -o %INST_TEMP_DIR% \extra.wixobj -dpylibSource=..\pythonlib\extra -arch %MSI_ARCH%
7678if NOT [%ERRORLEVEL% ]== [0] (
7779 goto error
7880)
@@ -84,7 +86,7 @@ if NOT [%ERRORLEVEL%]==[0] (
8486)
8587
8688echo Compiling extra lib WiX source
87- candle %INST_TEMP_DIR% \extra_dll%NAME_ADDON% .wxs -o %INST_TEMP_DIR% \extra_dll%NAME_ADDON% .wixobj -dpylibSource=..\pythonlib\extra_dll%NAME_ADDON%
89+ candle %INST_TEMP_DIR% \extra_dll%NAME_ADDON% .wxs -o %INST_TEMP_DIR% \extra_dll%NAME_ADDON% .wixobj -dpylibSource=..\pythonlib\extra_dll%NAME_ADDON% -arch %MSI_ARCH%
8890if NOT [%ERRORLEVEL% ]== [0] (
8991 goto error
9092)
@@ -96,7 +98,7 @@ if NOT [%ERRORLEVEL%]==[0] (
9698)
9799
98100echo Compiling tcl lib WiX source
99- candle %INST_TEMP_DIR% \tcl.wxs -o %INST_TEMP_DIR% \tcl.wixobj -dpylibSource=..\pythonlib\tcl
101+ candle %INST_TEMP_DIR% \tcl.wxs -o %INST_TEMP_DIR% \tcl.wixobj -dpylibSource=..\pythonlib\tcl -arch %MSI_ARCH%
100102if NOT [%ERRORLEVEL% ]== [0] (
101103 goto error
102104)
@@ -108,7 +110,7 @@ if NOT [%ERRORLEVEL%]==[0] (
108110)
109111
110112echo Compiling tcl lib WiX source
111- candle %INST_TEMP_DIR% \tcl_dll%NAME_ADDON% .wxs -o %INST_TEMP_DIR% \tcl_dll%NAME_ADDON% .wixobj -dpylibSource=..\pythonlib\tcl_dll%NAME_ADDON%
113+ candle %INST_TEMP_DIR% \tcl_dll%NAME_ADDON% .wxs -o %INST_TEMP_DIR% \tcl_dll%NAME_ADDON% .wixobj -dpylibSource=..\pythonlib\tcl_dll%NAME_ADDON% -arch %MSI_ARCH%
112114if NOT [%ERRORLEVEL% ]== [0] (
113115 goto error
114116)
@@ -120,38 +122,38 @@ if NOT [%ERRORLEVEL%]==[0] (
120122)
121123
122124echo Compiling Sample Scripts WiX source
123- candle %INST_TEMP_DIR% \sampleScripts.wxs -o %INST_TEMP_DIR% \sampleScripts.wixobj -dscriptSource=..\scripts\Samples
125+ candle %INST_TEMP_DIR% \sampleScripts.wxs -o %INST_TEMP_DIR% \sampleScripts.wixobj -dscriptSource=..\scripts\Samples -arch %MSI_ARCH%
124126if NOT [%ERRORLEVEL% ]== [0] (
125127 goto error
126128)
127129
128130
129131echo Generating WiX information for ..\PythonScript\python_tests
130- heat dir ..\PythonScript\python_tests -ag -cg CG_UnitTests -dr D_PythonScript -var var.unittestSource -t changeDirTests.xsl -o %INST_TEMP_DIR% \unittests.wxs
132+ heat dir ..\PythonScript\python_tests -ag -cg CG_UnitTests -dr D_PythonScript -var var.unittestSource -t changeDirTests.xsl -o %INST_TEMP_DIR% \unittests.wxs -platform= %NAME_ADDON%
131133if NOT [%ERRORLEVEL% ]== [0] (
132134 goto error
133135)
134136
135137echo Compiling Unit test WiX source
136- candle %INST_TEMP_DIR% \unittests.wxs -o %INST_TEMP_DIR% \unittests.wixobj -dunittestSource=..\PythonScript\python_tests
138+ candle %INST_TEMP_DIR% \unittests.wxs -o %INST_TEMP_DIR% \unittests.wixobj -dunittestSource=..\PythonScript\python_tests -arch %MSI_ARCH%
137139if NOT [%ERRORLEVEL% ]== [0] (
138140 goto error
139141)
140142
141143echo Generating WiX information for ..\docs\build\html
142- heat dir ..\docs\build\html -ag -cg CG_HtmlDocs -dr D_PythonScript -var var.htmldocsSource -t changeDirHtmlDoc.xsl -o %INST_TEMP_DIR% \htmldoc.wxs
144+ heat dir ..\docs\build\html -ag -cg CG_HtmlDocs -dr D_PythonScript -var var.htmldocsSource -t changeDirHtmlDoc.xsl -o %INST_TEMP_DIR% \htmldoc.wxs -platform= %NAME_ADDON%
143145if NOT [%ERRORLEVEL% ]== [0] (
144146 goto error
145147)
146148
147149echo Compiling Html doc WiX source
148- candle %INST_TEMP_DIR% \htmldoc.wxs -o %INST_TEMP_DIR% \htmldoc.wixobj -dhtmldocsSource=..\docs\build\html
150+ candle %INST_TEMP_DIR% \htmldoc.wxs -o %INST_TEMP_DIR% \htmldoc.wixobj -dhtmldocsSource=..\docs\build\html -arch %MSI_ARCH%
149151if NOT [%ERRORLEVEL% ]== [0] (
150152 goto error
151153)
152154
153155echo Compiling main PythonScript installer
154- candle pythonscript.wxs -o %INST_TEMP_DIR% \pythonscript.wixobj -dversion=%PYTHONSCRIPTVERSION% -dbaseDir=.. -dpythonDir=%PYTHONBUILDDIR% -dvariantDir=%PYTHONSCRIPTDLLDIR%
156+ candle pythonscript.wxs -o %INST_TEMP_DIR% \pythonscript.wixobj -dversion=%PYTHONSCRIPTVERSION% -dbaseDir=.. -dpythonDir=%PYTHONBUILDDIR% -dvariantDir=%PYTHONSCRIPTDLLDIR% -dPlatform= %MSI_ARCH% -arch %MSI_ARCH%
155157if NOT [%ERRORLEVEL% ]== [0] (
156158 goto error
157159)
0 commit comments