ExternalProject: Fix 'make' builds with Ninja (#13159)
Fix the build command when Ninja is the CMake Generator, but the external project is created for a project that does not use CMake but does use "make".
This commit is contained in:
parent
4af648041d
commit
c9097c74b6
|
@ -712,8 +712,12 @@ function(_ep_get_build_command name step cmd_var)
|
||||||
endif()
|
endif()
|
||||||
else() # if(cfg_cmd_id STREQUAL "configure")
|
else() # if(cfg_cmd_id STREQUAL "configure")
|
||||||
# Non-CMake project. Guess "make" and "make install" and "make test".
|
# Non-CMake project. Guess "make" and "make install" and "make test".
|
||||||
# But use "$(MAKE)" to get recursive parallel make.
|
if("${CMAKE_GENERATOR}" MATCHES "Makefiles")
|
||||||
|
# Try to get the parallel arguments
|
||||||
set(cmd "$(MAKE)")
|
set(cmd "$(MAKE)")
|
||||||
|
else()
|
||||||
|
set(cmd "make")
|
||||||
|
endif()
|
||||||
if(step STREQUAL "INSTALL")
|
if(step STREQUAL "INSTALL")
|
||||||
set(args install)
|
set(args install)
|
||||||
endif()
|
endif()
|
||||||
|
|
Loading…
Reference in New Issue