diff options
| author | Ilya Kitaev <mbg033@gmail.comm> | 2016-07-06 16:24:14 +0300 |
|---|---|---|
| committer | Ilya Kitaev <mbg033@gmail.comm> | 2016-07-06 16:24:14 +0300 |
| commit | fca82f347d29429e3ad662897a38923e3258a643 (patch) | |
| tree | 2f6660bd9d54307bb4f8d27834a1913d06ed2892 | |
| parent | da43e9a93a8cac57a8c993ba823dddddefa4af3f (diff) | |
| download | monzero-gui-fca82f347d29429e3ad662897a38923e3258a643.tar.gz monzero-gui-fca82f347d29429e3ad662897a38923e3258a643.tar.xz monzero-gui-fca82f347d29429e3ad662897a38923e3258a643.zip | |
Cross-plaftorm number of cpu cores
| -rwxr-xr-x | get_libwallet_api.sh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/get_libwallet_api.sh b/get_libwallet_api.sh index 60f86d32..520bba17 100755 --- a/get_libwallet_api.sh +++ b/get_libwallet_api.sh @@ -3,7 +3,8 @@ BITMONERO_URL=https://github.com/mbg033/bitmonero.git BITMONERO_BRANCH=fee-mul -CPU_CORE_COUNT=$(grep -c ^processor /proc/cpuinfo) +# thanks to SO: http://stackoverflow.com/a/20283965/4118915 +CPU_CORE_COUNTS=$(grep -c ^processor /proc/cpuinfo 2>/dev/null || sysctl -n hw.ncpu) pushd $(pwd) ROOT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" |
