From c5e4bab85854476016b385ac80d962d1fcab9133 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kjetil=20Limkj=C3=A6r?= Date: Wed, 13 Dec 2017 22:00:14 +0100 Subject: [PATCH] Fix pyenv install on Solaris / Illumos pyenv install crashes on Solaris with an empty log file. Adding support for the proper Solaris getconf call in num_cpu_cores fixed it. Tested and working under OmniOS CE r151024. --- plugins/python-build/bin/python-build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/python-build/bin/python-build b/plugins/python-build/bin/python-build index f47c1e89..f89474b8 100755 --- a/plugins/python-build/bin/python-build +++ b/plugins/python-build/bin/python-build @@ -156,7 +156,7 @@ num_cpu_cores() { num="$(sysctl -n hw.ncpu 2>/dev/null || true)" ;; * ) - num="$({ getconf _NPROCESSORS_ONLN || + num="$({ getconf _NPROCESSORS_ONLN || getconf NPROCESSORS_ONLN || grep -c ^processor /proc/cpuinfo; } 2>/dev/null)" num="${num#0}" ;;