@@ -610,6 +610,35 @@ def _create_launchers(self):
610
610
611
611
self ._print_done ()
612
612
613
+ def _create_batch_scripts_initial (self ):
614
+ """Create batch scripts"""
615
+ self ._print ("Creating batch scripts initial" )
616
+ conv = lambda path : ";" .join (['%WINPYDIR%\\ ' + pth for pth in path ])
617
+ path = conv (self .prepath ) + ";%PATH%;" + conv (self .postpath )
618
+ self .create_batch_script ('env.bat' , """@echo off
619
+ set WINPYDIR=%~dp0..\\ """ + self .python_name + r"""
620
+ set WINPYVER=""" + self .winpyver + r"""
621
+ set HOME=%WINPYDIR%\..\settings
622
+ set WINPYARCH="WIN32"
623
+ if "%WINPYDIR:~-5%"=="amd64" set WINPYARCH="WIN-AMD64"
624
+
625
+ rem handle R if included
626
+ if not exist "%WINPYDIR%\..\tools\R\bin" goto r_bad
627
+ set R_HOME=%WINPYDIR%\..\tools\R
628
+ if %WINPYARCH%=="WIN32" set R_HOMEbin=%R_HOME%\bin\i386
629
+ if not %WINPYARCH%=="WIN32" set R_HOMEbin=%R_HOME%\bin\x64
630
+ :r_bad
631
+
632
+ rem handle Julia if included
633
+ if not exist "%WINPYDIR%\..\tools\Julia\bin" goto julia_bad
634
+ set JULIA_HOME=%WINPYDIR%\..\tools\Julia\bin\
635
+ set JULIA_EXE=julia.exe
636
+ set JULIA=%JULIA_HOME%%JULIA_EXE%
637
+ set JULIA_PKGDIR=%WINPYDIR%\..\settings\.julia
638
+ :julia_bad
639
+
640
+ set PATH=""" + path )
641
+
613
642
def _create_batch_scripts (self ):
614
643
"""Create batch scripts"""
615
644
self ._print ("Creating batch scripts" )
@@ -935,12 +964,12 @@ def _create_batch_scripts(self):
935
964
936
965
self ._print_done ()
937
966
938
- def _run_complement_batch_scripts (self ):
967
+ def _run_complement_batch_scripts (self , this_batch = "run_complement.bat" ):
939
968
""" tools\..\r un_complement.bat for final complements"""
940
- print ('now run_complement.bat in tooldirs\..' )
969
+ print ('now %s in tooldirs\..' % this_batch )
941
970
for post_complement in list (set ([osp .dirname (s )
942
971
for s in self ._toolsdirs ])):
943
- filepath = osp .join (post_complement , "run_complement.bat" )
972
+ filepath = osp .join (post_complement , this_batch )
944
973
if osp .isfile (filepath ):
945
974
print ('launch "%s" for "%s"' % (filepath , self .winpydir ))
946
975
try :
@@ -999,6 +1028,9 @@ def make(self, remove_existing=True):
999
1028
if remove_existing :
1000
1029
if not self .simulation :
1001
1030
self ._add_msvc_files ()
1031
+ if not self .simulation :
1032
+ self ._create_batch_scripts_initial ()
1033
+ self ._run_complement_batch_scripts ("run_required_first.bat" )
1002
1034
self ._install_required_packages ()
1003
1035
self ._install_all_other_packages ()
1004
1036
if not self .simulation :
@@ -1164,6 +1196,8 @@ def make_all(build_number, release_level, pyver,
1164
1196
# verbose=False, archis=(32, ))
1165
1197
make_all (3 , '' , pyver = '3.4' , rootdir = r'D:\Winpython' ,
1166
1198
verbose = False , archis = (64 , ), flavor = '' )
1199
+ #make_all(3, '', pyver='3.4', rootdir=r'D:\Winpython\basedirQt5',
1200
+ # verbose=False, archis=(64, ))
1167
1201
#make_all(8, '', pyver='3.3', rootdir=r'D:\Winpython',
1168
1202
# verbose=False, archis=(32, ))
1169
1203
#make_all(8, '', pyver='3.3', rootdir=r'D:\Winpython',
0 commit comments