IF(NOT DEFINED CMAKE_TEST_SC_NPROCESSORS) MESSAGE(STATUS "sysconf() support for _SC_NPROCESSORS_CONF") TRY_COMPILE(CMAKE_TEST_SC_NPROCESSORS ${CMAKE_BINARY_DIR} ${CMAKE_CURRENT_LIST_DIR}/TestSCNProcessors.c OUTPUT_VARIABLE OUTPUT) IF(CMAKE_TEST_SC_NPROCESSORS) MESSAGE(STATUS "sysconf() supports _SC_NPROCESSORS_CONF - found") SET(HAVE_SC_NPROCESSORS_CONF 1 CACHE INTERNAL "sysconf() _SC_NPROCESSORS_CONF") FILE(APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeOutput.log "Determining sysconf() support for _SC_NPROCESSORS_CONF " "succeeded:\n${OUTPUT}\n\n") ELSE(CMAKE_TEST_SC_NPROCESSORS) MESSAGE(STATUS "sysconf() supports _SC_NPROCESSORS_CONF - not found") ENDIF(CMAKE_TEST_SC_NPROCESSORS) ENDIF(NOT DEFINED CMAKE_TEST_SC_NPROCESSORS)