File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -625,7 +625,14 @@ impl Step for TestHelpers {
625625 if builder. config . dry_run {
626626 return ;
627627 }
628- let target = self . target ;
628+ // The x86_64-fortanix-unknown-sgx target doesn't have a working C
629+ // toolchain. However, some x86_64 ELF objects can be linked
630+ // without issues. Use this hack to compile the test helpers.
631+ let target = if self . target == "x86_64-fortanix-unknown-sgx" {
632+ TargetSelection :: from_user ( "x86_64-unknown-linux-gnu" )
633+ } else {
634+ self . target
635+ } ;
629636 let dst = builder. test_helpers_out ( target) ;
630637 let src = builder. src . join ( "src/test/auxiliary/rust_test_helpers.c" ) ;
631638 if up_to_date ( & src, & dst. join ( "librust_test_helpers.a" ) ) {
@@ -649,7 +656,6 @@ impl Step for TestHelpers {
649656 }
650657 cfg. compiler ( builder. cc ( target) ) ;
651658 }
652-
653659 cfg. cargo_metadata ( false )
654660 . out_dir ( & dst)
655661 . target ( & target. triple )
You can’t perform that action at this time.
0 commit comments