diff options
author | Yuval Lifshitz <yuvalif@yahoo.com> | 2019-08-21 08:27:42 +0200 |
---|---|---|
committer | Yuval Lifshitz <yuvalif@yahoo.com> | 2019-09-06 08:38:32 +0200 |
commit | b8b43fe59d7c03cea7347a8de3b7e7272cef0935 (patch) | |
tree | 2e414135b4acdca9cbea60e9011476d4a52a7c04 /do_freebsd.sh | |
parent | Merge pull request #29973 from theanalyst/doc/releases/14.2.3 (diff) | |
download | ceph-b8b43fe59d7c03cea7347a8de3b7e7272cef0935.tar.xz ceph-b8b43fe59d7c03cea7347a8de3b7e7272cef0935.zip |
allow for multiple "build" dirs to exist
Signed-off-by: Yuval Lifshitz <yuvalif@yahoo.com>
Diffstat (limited to 'do_freebsd.sh')
-rwxr-xr-x | do_freebsd.sh | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/do_freebsd.sh b/do_freebsd.sh index d3f60a26558..509384bee57 100755 --- a/do_freebsd.sh +++ b/do_freebsd.sh @@ -24,16 +24,18 @@ CMAKE_C_FLAGS_DEBUG="$C_FLAGS_DEBUG $COMPILE_FLAGS" # dashboard, because versions fetched are not working on FreeBSD. +[ -z "$BUILD_DIR" ] && BUILD_DIR=build + echo Keeping the old build -if [ -d build.old ]; then - sudo mv build.old build.del - sudo rm -rf build.del & +if [ -d ${BUILD_DIR}.old ]; then + sudo mv ${BUILD_DIR}.old ${BUILD_DIR}.del + sudo rm -rf ${BUILD_DIR}.del & fi -if [ -d build ]; then - sudo mv build build.old +if [ -d ${BUILD_DIR} ]; then + sudo mv ${BUILD_DIR} ${BUILD_DIR}.old fi -mkdir build +mkdir ${BUILD_DIR} ./do_cmake.sh "$*" \ -D WITH_CCACHE=ON \ -D CMAKE_BUILD_TYPE=Debug \ @@ -61,7 +63,7 @@ mkdir build echo -n "start building: "; date printenv -cd build +cd ${BUILD_DIR} gmake -j$CPUS V=1 VERBOSE=1 gmake tests echo -n "start testing: "; date ; |