mirror of
https://github.com/denoland/rusty_v8.git
synced 2025-01-11 08:34:01 -05:00
Specify custom URL for binary downloads with 'RUSTY_V8_MIRROR' env var (#446)
This commit is contained in:
parent
1ccabcc650
commit
fa8f636397
2 changed files with 6 additions and 1 deletions
|
@ -39,6 +39,9 @@ Binaries builds are turned on by default: `cargo build` will initiate a download
|
|||
from github to get the static lib. To disable this build using the
|
||||
`V8_FROM_SOURCE` environmental variable.
|
||||
|
||||
If you prefer another location for downloading binaries,
|
||||
use the`RUSTY_V8_MIRROR` environmental variable.
|
||||
|
||||
When making changes to rusty_v8 itself, it should be tested by build from
|
||||
source. The CI always builds from source.
|
||||
|
||||
|
|
4
build.rs
4
build.rs
|
@ -174,7 +174,9 @@ fn download_ninja_gn_binaries() {
|
|||
}
|
||||
|
||||
fn static_lib_url() -> (String, String) {
|
||||
let base = "https://github.com/denoland/rusty_v8/releases/download";
|
||||
let default_base = "https://github.com/denoland/rusty_v8/releases/download";
|
||||
let base =
|
||||
env::var("RUSTY_V8_MIRROR").unwrap_or_else(|_| default_base.into());
|
||||
let version = env::var("CARGO_PKG_VERSION").unwrap();
|
||||
let target = env::var("TARGET").unwrap();
|
||||
if cfg!(target_os = "windows") {
|
||||
|
|
Loading…
Reference in a new issue