File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -830,6 +830,7 @@ impl Config {
830830 }
831831
832832 // If the generated project is Makefile based we should carefully transfer corresponding CARGO_MAKEFLAGS
833+ let mut use_jobserver = false ;
833834 if fs:: metadata ( & build. join ( "Makefile" ) ) . is_ok ( ) {
834835 match env:: var_os ( "CARGO_MAKEFLAGS" ) {
835836 // Only do this on non-windows and non-bsd
@@ -844,6 +845,7 @@ impl Config {
844845 || cfg ! ( target_os = "bitrig" )
845846 || cfg ! ( target_os = "dragonflybsd" ) ) =>
846847 {
848+ use_jobserver = true ;
847849 cmd. env ( "MAKEFLAGS" , makeflags) ;
848850 }
849851 _ => { }
@@ -864,7 +866,7 @@ impl Config {
864866
865867 // --parallel requires CMake 3.12:
866868 // https://cmake.org/cmake/help/latest/release/3.12.html#command-line
867- if version >= Version :: new ( 3 , 12 ) {
869+ if version >= Version :: new ( 3 , 12 ) && !use_jobserver {
868870 if let Ok ( s) = env:: var ( "NUM_JOBS" ) {
869871 // See https://cmake.org/cmake/help/v3.12/manual/cmake.1.html#build-tool-mode
870872 cmd. arg ( "--parallel" ) . arg ( s) ;
You can’t perform that action at this time.
0 commit comments