Auto merge of #13486 - UK992:mach-bootstrap-2, r=larsbergstrom

Fix msvc packages download dir for custom `.servo` location

- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/13486)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2016-09-30 15:39:40 -05:00 committed by GitHub
commit 9acd7f390a
3 changed files with 4 additions and 3 deletions

View file

@ -145,7 +145,7 @@ class MachCommands(CommandBase):
def bootstrap(self, android=False, interactive=False, force=False):
from servo.bootstrapper.bootstrap import Bootstrapper
bootstrapper = Bootstrapper()
bootstrapper = Bootstrapper(self.context)
bootstrapper.bootstrap(android=android, interactive=interactive, force=force)
@Command('bootstrap-rust',

View file

@ -13,7 +13,7 @@ from windows_msvc import WindowsMsvcBootstrapper
class Bootstrapper(object):
"""Main class that performs system bootstrap."""
def __init__(self):
def __init__(self, context):
self.instance = None
cls = None
args = {}
@ -28,6 +28,7 @@ class Bootstrapper(object):
sys.exit('Bootstrap support is not yet available for your OS.')
self.instance = cls(**args)
self.instance.context = context
def bootstrap(self, android=False, interactive=False, force=False):
self.instance.interactive = interactive

View file

@ -23,7 +23,7 @@ class WindowsMsvcBootstrapper(BaseBootstrapper):
def install_system_packages(self, packages=deps):
from servo.bootstrap_commands import extract, download_file
deps_dir = os.path.join(".servo", "msvc-dependencies")
deps_dir = os.path.join(self.context.sharedir, "msvc-dependencies")
deps_url = "https://servo-rust.s3.amazonaws.com/msvc-deps/"
first_run = True