diff options
author | Ryan Dahl <ry@tinyclouds.org> | 2018-11-27 17:21:42 -0500 |
---|---|---|
committer | Ryan Dahl <ry@tinyclouds.org> | 2018-11-27 15:47:31 -0800 |
commit | 89096c92104ab89b1fd8ba273cbbf441dcfe5a84 (patch) | |
tree | 889f1cf4a60dfc63b89ffdadb3d7eb78d6a8a65d /tools/prebuilt.py | |
parent | 65cce40a8960727955061aae35670443ca9b8c46 (diff) |
Use prebuilt V8 library by default.
This still retains the ability to build V8 from scratch, with an number
of configurations. The prebuilt binaries were created using
DENO_BUILD_MODE=release ./tools/build.py v8
Diffstat (limited to 'tools/prebuilt.py')
-rw-r--r-- | tools/prebuilt.py | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/tools/prebuilt.py b/tools/prebuilt.py new file mode 100644 index 000000000..7542d7aa6 --- /dev/null +++ b/tools/prebuilt.py @@ -0,0 +1,31 @@ +import sys +from util import run +from third_party import tp, google_env + + +def download_v8_prebuilt(): + if sys.platform == 'win32': + sha1_file = "prebuilt/win/v8.lib.sha1" + elif sys.platform.startswith('linux'): + sha1_file = "prebuilt/linux64/libv8.a.sha1" + elif sys.platform == 'darwin': + sha1_file = "prebuilt/mac/libv8.a.sha1" + + run([ + "python", + tp('depot_tools/download_from_google_storage.py'), + '--platform=' + sys.platform, + '--no_auth', + '--bucket=denoland', + '--sha1_file', + sha1_file, + ], + env=google_env()) + + +def load(): + download_v8_prebuilt() + + +if __name__ == '__main__': + sys.exit(load()) |