@@ -107,6 +107,9 @@ pub struct TestProps {
107
107
// Similar to `aux_builds`, but a list of NAME=somelib.rs of dependencies
108
108
// to build and pass with the `--extern` flag.
109
109
pub aux_crates : Vec < ( String , String ) > ,
110
+ /// Similar to `aux_builds`, but also passes the resulting dylib path to
111
+ /// `-Zcodegen-backend`.
112
+ pub aux_codegen_backend : Option < String > ,
110
113
// Environment settings to use for compiling
111
114
pub rustc_env : Vec < ( String , String ) > ,
112
115
// Environment variables to unset prior to compiling.
@@ -231,6 +234,7 @@ mod directives {
231
234
pub const AUX_BIN : & ' static str = "aux-bin" ;
232
235
pub const AUX_BUILD : & ' static str = "aux-build" ;
233
236
pub const AUX_CRATE : & ' static str = "aux-crate" ;
237
+ pub const AUX_CODEGEN_BACKEND : & ' static str = "aux-codegen-backend" ;
234
238
pub const EXEC_ENV : & ' static str = "exec-env" ;
235
239
pub const RUSTC_ENV : & ' static str = "rustc-env" ;
236
240
pub const UNSET_EXEC_ENV : & ' static str = "unset-exec-env" ;
@@ -267,6 +271,7 @@ impl TestProps {
267
271
aux_builds : vec ! [ ] ,
268
272
aux_bins : vec ! [ ] ,
269
273
aux_crates : vec ! [ ] ,
274
+ aux_codegen_backend : None ,
270
275
revisions : vec ! [ ] ,
271
276
rustc_env : vec ! [
272
277
( "RUSTC_ICE" . to_string( ) , "0" . to_string( ) ) ,
@@ -446,6 +451,9 @@ impl TestProps {
446
451
& mut self . aux_crates ,
447
452
Config :: parse_aux_crate,
448
453
) ;
454
+ if let Some ( r) = config. parse_name_value_directive ( ln, AUX_CODEGEN_BACKEND ) {
455
+ self . aux_codegen_backend = Some ( r. trim ( ) . to_owned ( ) ) ;
456
+ }
449
457
config. push_name_value_directive (
450
458
ln,
451
459
EXEC_ENV ,
@@ -722,6 +730,7 @@ const KNOWN_DIRECTIVE_NAMES: &[&str] = &[
722
730
"assembly-output" ,
723
731
"aux-bin" ,
724
732
"aux-build" ,
733
+ "aux-codegen-backend" ,
725
734
"aux-crate" ,
726
735
"build-aux-docs" ,
727
736
"build-fail" ,
0 commit comments