mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 05:41:12 +00:00
Bug 1275437 - Fixed some offending version checks that were inhereted from the BaseBootstrapper r=gps
Overrode BaseBootstrapper.which to append '.exe' to any which checks since (hopefully) anything the bootstrapper looks for, must be a windows executable. Changed base bootstrapper class to use str instead of unicode to avoid a bug in the MinGW version of Python where subprocces.Popen will not accept environment variables that are in unicode instead of str. MozReview-Commit-ID: 4m8xNifawYS --HG-- extra : rebase_source : 455b518b099fdba347626ab93b85ddbd44f1f977
This commit is contained in:
parent
ee6484c3fa
commit
452a80bc35
@ -299,7 +299,8 @@ class BaseBootstrapper(object):
|
||||
making it suitable for use in scripts.
|
||||
"""
|
||||
env = os.environ.copy()
|
||||
env['HGPLAIN'] = '1'
|
||||
env[b'HGPLAIN'] = b'1'
|
||||
|
||||
return env
|
||||
|
||||
def is_mercurial_modern(self):
|
||||
|
@ -42,11 +42,14 @@ class WindowsBootstrapper(BaseBootstrapper):
|
||||
'to set up a build environment on Windows. If you are testing Windows Bootstrap support, '
|
||||
'try `export MOZ_WINDOWS_BOOTSTRAP=1`')
|
||||
BaseBootstrapper.__init__(self, **kwargs)
|
||||
if not self.which('pacman.exe'):
|
||||
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 install_system_packages(self):
|
||||
self.pacman_install(*self.SYSTEM_PACKAGES)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user