summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Moritz <chrmoritz@gmail.com>2019-05-24 00:58:15 +0200
committerRyan Dahl <ry@tinyclouds.org>2019-05-30 13:18:30 -0400
commit15dadf812c95c3dd2b93b1ba41ef488baeeac0c1 (patch)
tree49e33ea60524aa41aaadc19d8690285eb9974728
parent4c80394f54bf68e8e961fbc6275cd536717bc7f6 (diff)
tools/third_party: add DENO_GN_PATH and DENO_NINJA_PATH env vars
-rw-r--r--tools/third_party.py11
-rw-r--r--website/manual.md8
2 files changed, 16 insertions, 3 deletions
diff --git a/tools/third_party.py b/tools/third_party.py
index 133f265c2..1dd54b872 100644
--- a/tools/third_party.py
+++ b/tools/third_party.py
@@ -24,9 +24,16 @@ third_party_path = tp()
depot_tools_path = tp("depot_tools")
rust_crates_path = tp("rust_crates")
python_packages_path = tp("python_packages")
-gn_path = tp(depot_tools_path, "gn")
clang_format_path = tp(depot_tools_path, "clang-format")
-ninja_path = tp(depot_tools_path, "ninja")
+
+if "DENO_GN_PATH" in os.environ:
+ gn_path = os.environ["DENO_GN_PATH"]
+else:
+ gn_path = tp(depot_tools_path, "gn")
+if "DENO_NINJA_PATH" in os.environ:
+ ninja_path = os.environ["DENO_NINJA_PATH"]
+else:
+ ninja_path = tp(depot_tools_path, "ninja")
python_site_env = None
diff --git a/website/manual.md b/website/manual.md
index ceb3a51b8..d8590e0f6 100644
--- a/website/manual.md
+++ b/website/manual.md
@@ -205,10 +205,16 @@ Extra steps for Windows users:
# Update third_party modules
git submodule update
+
+# Skip downloading binary build tools and point the build
+# to the system provided ones (for packagers of deno ...).
+./tools/setup.py --no-binary-download
+export DENO_BUILD_ARGS="clang_base_path=/usr clang_use_chrome_plugins=false"
+DENO_GN_PATH=/usr/bin/gn DENO_NINJA_PATH=/usr/bin/ninja ./tools/build.py
```
Environment variables: `DENO_BUILD_MODE`, `DENO_BUILD_PATH`, `DENO_BUILD_ARGS`,
-`DENO_DIR`.
+`DENO_DIR`, `DENO_GN_PATH`, `DENO_NINJA_PATH`.
## API reference