From: PHO Date: Thu, 23 Feb 2012 10:20:27 +0000 (+0900) Subject: #cpu detection for NetBSD X-Git-Url: https://git.cielonegro.org/gitweb.cgi?a=commitdiff_plain;h=24ecd4063af8f36ea8c9cb45d1cae4406240be80;p=build-hc-pkg.git #cpu detection for NetBSD --- diff --git a/build-hc-pkg b/build-hc-pkg index 87e34ef..27bf1fd 100755 --- a/build-hc-pkg +++ b/build-hc-pkg @@ -16,7 +16,10 @@ function detect_number_of_cpus () { case "$platform" in *-*-darwin) - ioreg -r -c IOCPU | fgrep -c IOCPUNumber + ioreg -r -c IOCPU | fgrep -c \"IOCPUNumber\" + ;; + *-*-netbsd*) + cat /proc/cpuinfo | grep -cE 'processor[[:space:]]*:' ;; *) echo "WARNING: I don't know how to detect the number of processors on this platform." >&2