Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support a system root with correct on-disk directory layout #6267

Merged
merged 1 commit into from Jun 3, 2015
Merged
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

Support a system root with correct on-disk directory layout

The existing code for setting up the environment assumes that
the directory layout containing rust and cargo conforms to the
one used by rust-installer's tarballs. This makes overriding
the system root awkward for simple cases where I want to test
my own build directly from the rust build directory. This
patch just adds a second path to PATH and LD_LIBRARY_PATH
to accomodate both disk layouts.

Conflicts:
	python/servo/command_base.py
  • Loading branch information
brson committed Jun 2, 2015
commit 68d977c5f0d7fd8347cd4e3a3229a84a9c66c631
@@ -167,12 +167,21 @@ def build_env(self, gonk=False, hosts_file_path=None):
if not self.config["tools"]["system-rust"] \
or self.config["tools"]["rust-root"]:
env["RUST_ROOT"] = self.config["tools"]["rust-root"]
# These paths are for when rust-root points to an unpacked installer
extra_path += [path.join(self.config["tools"]["rust-root"], "rustc", "bin")]
extra_lib += [path.join(self.config["tools"]["rust-root"], "rustc", "lib")]
# These paths are for when rust-root points to a rustc sysroot
extra_path += [path.join(self.config["tools"]["rust-root"], "bin")]
extra_lib += [path.join(self.config["tools"]["rust-root"], "lib")]

if not self.config["tools"]["system-cargo"] \
or self.config["tools"]["cargo-root"]:
# This path is for when rust-root points to an unpacked installer
extra_path += [
path.join(self.config["tools"]["cargo-root"], "cargo", "bin")]
# This path is for when rust-root points to a rustc sysroot
extra_path += [
path.join(self.config["tools"]["cargo-root"], "bin")]

if extra_path:
env["PATH"] = "%s%s%s" % (
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.