build/freebsd: set CMAKE_MAKE_PROGRAM iff "Unix Makefiles" (#8260)

It's only appropriate to set CMAKE_MAKE_PROGRAM to gmake when we're
using the "Unix Makefiles" generator.  On QB, the nodes have Ninja
available and will use it, which means CMAKE_GENERATOR is set to
"Ninja".  Setting CMAKE_MAKE_PROGRAM was forcing the build to use gmake
instead of ninja, which was causing the build failure.
This commit is contained in:
John Szakmeister
2018-04-12 06:51:38 -04:00
committed by Justin M. Keyes
parent d48df146d1
commit f44fb5b1a5

View File

@@ -86,7 +86,8 @@ else()
"-DCMAKE_C_FLAGS:STRING=${CMAKE_C_COMPILER_ARG1} ${LUV_INCLUDE_FLAGS} -fPIC")
endif()
if(CMAKE_SYSTEM_NAME MATCHES ".*BSD" OR CMAKE_SYSTEM_NAME MATCHES "DragonFly")
if(CMAKE_GENERATOR MATCHES "Unix Makefiles" AND
(CMAKE_SYSTEM_NAME MATCHES ".*BSD" OR CMAKE_SYSTEM_NAME MATCHES "DragonFly"))
set(LUV_BUILD_COMMAND ${CMAKE_COMMAND} "-DCMAKE_MAKE_PROGRAM=gmake" --build .)
else()
set(LUV_BUILD_COMMAND ${CMAKE_COMMAND} --build .)