diff options
author | Georgi Kodinov <joro@sun.com> | 2009-07-10 16:00:17 +0300 |
---|---|---|
committer | Georgi Kodinov <joro@sun.com> | 2009-07-10 16:00:17 +0300 |
commit | 55f514ad0505182cb3a7f3f955a16baadb2493ba (patch) | |
tree | 38ea669198256222690ca96dcaab1bed77c3cd9a /BUILD/check-cpu | |
parent | af7d0595865330df7a4c86e95d41b92c409acfed (diff) | |
download | mariadb-git-55f514ad0505182cb3a7f3f955a16baadb2493ba.tar.gz |
fixed the CPU checking code.
Diffstat (limited to 'BUILD/check-cpu')
-rwxr-xr-x | BUILD/check-cpu | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/BUILD/check-cpu b/BUILD/check-cpu index 4974d3f4ecc..e7cae1c1da8 100755 --- a/BUILD/check-cpu +++ b/BUILD/check-cpu @@ -44,8 +44,13 @@ check_cpu () { model_name=`sysctl -n hw.model` ;; Darwin) - cpu_family=`uname -p` - model_name=`machine` + cpu_family=`sysctl -n machdep.cpu.vendor` + model_name=`sysctl -n machdep.cpu.brand_string` + if [ -z "$cpu_family" -o -z "$model_name" ] + then + cpu_family=`uname -p` + model_name=`machine` + fi ;; *) cpu_family=`uname -m`; |