Fix T48078: incorrect OS X command for retrieving number of CPUs on in Makefile.

This commit is contained in:
Brecht Van Lommel 2016-04-08 23:58:37 +02:00
parent c1d1c1dc6b
commit d09a372acb
Notes: blender-bot 2023-02-14 08:00:44 +01:00
Referenced by issue #48092, 2.77 and 277a totally freezes OS by opening the attached file
Referenced by issue #48078, Error in OSX build doc about getting hw.ncpu
1 changed files with 3 additions and 3 deletions

View File

@ -87,13 +87,13 @@ ifndef NPROCS
NPROCS:=$(shell nproc)
endif
ifeq ($(OS), Darwin)
NPROCS:=$(shell sysctl -a | grep "hw.ncpu" | cut -d" " -f3)
NPROCS:=$(shell sysctl -n hw.ncpu)
endif
ifeq ($(OS), FreeBSD)
NPROCS:=$(shell sysctl -a | grep "hw.ncpu" | cut -d" " -f2 )
NPROCS:=$(shell sysctl -n hw.ncpu)
endif
ifeq ($(OS), NetBSD)
NPROCS:=$(shell sysctl -a | grep "hw.ncpu" | cut -d" " -f2 )
NPROCS:=$(shell sysctl -n hw.ncpu)
endif
endif