Revert "Fix number processors on mac for parallelizing ctest"

This reverts commit 5ba04bba44.
release/4.3a0
= 2016-06-17 09:08:49 -04:00
parent 8c922b56c3
commit a7d02de3b5
1 changed files with 5 additions and 4 deletions

View File

@ -112,10 +112,11 @@ if(NOT DEFINED PROCESSOR_COUNT)
# Mac:
if(APPLE)
find_program(cmd_sysctl "sysctl")
if(cmd_sysctl)
execute_process(COMMAND ${cmd_sysctl} -n hw.ncpu OUTPUT_VARIABLE info)
string(STRIP ${info} PROCESSOR_COUNT)
find_program(cmd_sys_pro "system_profiler")
if(cmd_sys_pro)
execute_process(COMMAND ${cmd_sys_pro} OUTPUT_VARIABLE info)
string(REGEX REPLACE "^.*Total Number Of Cores: ([0-9]+).*$" "\\1"
PROCESSOR_COUNT "${info}")
endif()
endif()