From 7acd169bef320b6b6e872b6107383d2047e6a410 Mon Sep 17 00:00:00 2001 From: Will Rosecrans Date: Mon, 8 Jan 2018 14:48:58 -0800 Subject: [PATCH] Tidy build script --- build_cmake_pybullet_double.sh | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/build_cmake_pybullet_double.sh b/build_cmake_pybullet_double.sh index 0bddae1a5..802b87d04 100755 --- a/build_cmake_pybullet_double.sh +++ b/build_cmake_pybullet_double.sh @@ -1,10 +1,16 @@ #!/bin/sh -rm CMakeCache.txt -mkdir build_cmake + +if [ -e CMakeCache.txt ]; then + rm CMakeCache.txt +fi +mkdir -p build_cmake cd build_cmake cmake -DBUILD_PYBULLET=ON -DBUILD_PYBULLET_NUMPY=OFF -DUSE_DOUBLE_PRECISION=ON -DCMAKE_BUILD_TYPE=Release .. -make -j12 +make -j $(command nproc || echo 12) cd examples cd pybullet -ln -s pybullet.dylib pybullet.so +if [ -e pybullet.dylib ]; then + rm pybullet.so + ln -s pybullet.dylib pybullet.so +fi