@@ -561,9 +561,11 @@ def source_to_wininst(fname, python_exe=None,
561561 architecture = architecture , verbose = verbose )
562562
563563
564- def build_wheel (this_whl , python_exe = None , copy_to = None ,
565- architecture = None , verbose = False , install_options = None ):
566- """Execute the wheel (without dependancies)"""
564+ def wheel_pip_install (fname , python_exe = None ,
565+ architecture = None , verbose = False , install_options = None ):
566+ """direct install via pip !"""
567+ copy_to = osp .dirname (fname )
568+
567569 if python_exe is None :
568570 python_exe = sys .executable
569571 assert osp .isfile (python_exe )
@@ -574,7 +576,7 @@ def build_wheel(this_whl, python_exe=None, copy_to=None,
574576 if install_options :
575577 cmd += install_options # typically ['--no-deps']
576578 print ('wheel install_options' , install_options )
577- cmd += [this_whl ]
579+ cmd += [fname ]
578580 # print('build_wheel', myroot, cmd)
579581
580582 if verbose :
@@ -586,12 +588,12 @@ def build_wheel(this_whl, python_exe=None, copy_to=None,
586588 the_log = ("%s" % stdout + "\n %s" % stderr )
587589
588590 if ' not find ' in the_log or ' not found ' in the_log :
589- print ("Failed to Install: \n %s \n " % this_whl )
591+ print ("Failed to Install: \n %s \n " % fname )
590592 print ("msg: %s" % the_log )
591593 raise RuntimeError
592594 p .stdout .close ()
593595 p .stderr .close ()
594- src_fname = this_whl
596+ src_fname = fname
595597 if copy_to is None :
596598 return src_fname
597599 else :
@@ -629,15 +631,6 @@ def do_script(this_script, python_exe=None, copy_to=None,
629631 return 'ok'
630632
631633
632- def wheel_to_wininst (fname , python_exe = None ,
633- architecture = None , verbose = False , install_options = None ):
634- """Just install a wheel !"""
635- return build_wheel (fname , python_exe = python_exe ,
636- copy_to = osp .dirname (fname ),
637- architecture = architecture , verbose = verbose ,
638- install_options = install_options )
639-
640-
641634if __name__ == '__main__' :
642635 gcc = get_gcc_version (osp .join (BASE_DIR , 'tools.win32' , 'mingw32' , 'bin' ))
643636 print (("gcc version: %r" % gcc ))
0 commit comments