File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -1012,6 +1012,29 @@ impl Build {
1012
1012
atlmfc_lib. display( )
1013
1013
) ) ;
1014
1014
}
1015
+
1016
+ let compiler = self . try_get_compiler ( ) ?;
1017
+ for arg in compiler. args . iter ( ) {
1018
+ if arg. to_str ( ) . unwrap ( ) . contains ( "Qspectre" ) {
1019
+ for ( var, val) in compiler. env . iter ( ) {
1020
+ if var == "LIB" {
1021
+ for path in env:: split_paths ( & val) {
1022
+ if let Some ( last) = path. iter ( ) . last ( ) {
1023
+ // check upon .../lib/{platform}/../spectre/{platform}
1024
+ let spectre = path. parent ( ) . unwrap ( ) . join ( "spectre" ) . join ( last) ;
1025
+ if spectre. exists ( ) {
1026
+ self . print ( & format ! (
1027
+ "cargo:rustc-link-search=native={}" ,
1028
+ spectre. display( )
1029
+ ) ) ;
1030
+ }
1031
+ }
1032
+ }
1033
+ break ;
1034
+ }
1035
+ }
1036
+ }
1037
+ }
1015
1038
}
1016
1039
1017
1040
self . print ( & format ! ( "cargo:rustc-link-lib=static={}" , lib_name) ) ;
You can’t perform that action at this time.
0 commit comments