Bug 1485485 - Followup: Fix which function definition in derrived classes. r=froydnj
authorBas Schouten <bschouten@mozilla.com>
Tue, 28 Aug 2018 18:24:50 +0200
changeset 488760 7eb7606a2b12990e8ef5e470db27838d5f5af612
parent 488759 4292aeb328da7fa052bec34a635248e849400a58
child 488761 292e35a4377f5f6c5534dad4f4df349010de41b9
push id9734
push usershindli@mozilla.com
push dateThu, 30 Aug 2018 12:18:07 +0000
treeherdermozilla-beta@71c71ab3afae [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersfroydnj
bugs1485485
milestone63.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1485485 - Followup: Fix which function definition in derrived classes. r=froydnj
python/mozboot/mozboot/mozillabuild.py
python/mozboot/mozboot/windows.py
--- a/python/mozboot/mozboot/mozillabuild.py
+++ b/python/mozboot/mozboot/mozillabuild.py
@@ -13,18 +13,18 @@ from mozboot.base import BaseBootstrappe
 
 class MozillaBuildBootstrapper(BaseBootstrapper):
     '''Bootstrapper for MozillaBuild to install rustup.'''
     def __init__(self, no_interactive=False, no_system_changes=False):
         BaseBootstrapper.__init__(self, no_interactive=no_interactive,
                                   no_system_changes=no_system_changes)
         print("mach bootstrap is not fully implemented in MozillaBuild")
 
-    def which(self, name):
-        return BaseBootstrapper.which(self, name + '.exe')
+    def which(self, name, *extra_search_dirs):
+        return BaseBootstrapper.which(self, name + '.exe', *extra_search_dirs)
 
     def install_system_packages(self):
         pass
 
     def ensure_mercurial_modern(self):
         # Overrides default implementation to always run pip because.
         print('Running pip to ensure Mercurial is up-to-date...')
         self.run([self.which('pip'), 'install', '--upgrade', 'Mercurial'])
--- a/python/mozboot/mozboot/windows.py
+++ b/python/mozboot/mozboot/windows.py
@@ -45,18 +45,18 @@ class WindowsBootstrapper(BaseBootstrapp
                                       'Windows. If you are testing Windows Bootstrap support, '
                                       'try `export MOZ_WINDOWS_BOOTSTRAP=1`')
         BaseBootstrapper.__init__(self, **kwargs)
         if not self.which('pacman'):
             raise NotImplementedError('The Windows bootstrapper only works with msys2 with '
                                       'pacman. Get msys2 at http://msys2.github.io/')
         print('Using an experimental bootstrapper for Windows.')
 
-    def which(self, name):
-        return BaseBootstrapper.which(self, name + '.exe')
+    def which(self, name, *extra_search_dirs):
+        return BaseBootstrapper.which(self, name + '.exe', *extra_search_dirs)
 
     def install_system_packages(self):
         self.pacman_install(*self.SYSTEM_PACKAGES)
 
     def upgrade_mercurial(self, current):
         self.pip_install('mercurial')
 
     def upgrade_python(self, current):