File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed
Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,8 @@ fn main() {
2727 // probably more than what is needed, but missing an important
2828 // variable can lead to broken links when switching rusty_v8
2929 // versions.
30+ let target = env:: var ( "TARGET" ) . unwrap ( ) . replace ( "-" , "_" ) ;
31+ let rusty_v8_archive_target = format ! ( "RUSTY_V8_ARCHIVE_{target}" ) ;
3032 let envs = vec ! [
3133 "CCACHE" ,
3234 "CLANG_BASE_PATH" ,
@@ -39,6 +41,7 @@ fn main() {
3941 "NINJA" ,
4042 "OUT_DIR" ,
4143 "RUSTY_V8_ARCHIVE" ,
44+ rusty_v8_archive_target. as_str( ) ,
4245 "RUSTY_V8_MIRROR" ,
4346 "RUSTY_V8_SRC_BINDING_PATH" ,
4447 "SCCACHE" ,
@@ -551,6 +554,11 @@ fn static_lib_name(suffix: &str) -> String {
551554}
552555
553556fn static_lib_url ( ) -> String {
557+ let target = env:: var ( "TARGET" ) . unwrap ( ) ;
558+ let rusty_v8_archive_target = format ! ( "RUSTY_V8_ARCHIVE_{target}" ) ;
559+ if let Ok ( custom_archive) = env:: var ( rusty_v8_archive_target) {
560+ return custom_archive;
561+ }
554562 if let Ok ( custom_archive) = env:: var ( "RUSTY_V8_ARCHIVE" ) {
555563 return custom_archive;
556564 }
You can’t perform that action at this time.
0 commit comments