]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
build/ops: streamline processing of WITH_SEASTAR env var
authorNathan Cutler <ncutler@suse.com>
Wed, 1 Aug 2018 10:28:59 +0000 (12:28 +0200)
committerNathan Cutler <ncutler@suse.com>
Wed, 1 Aug 2018 10:36:09 +0000 (12:36 +0200)
Quoting relevant portion of "man test":

    STRING equivalent to -n STRING

Signed-off-by: Nathan Cutler <ncutler@suse.com>
install-deps.sh

index 3dc3828af2a23ee66b869c15646775bea97d8670..b6ad79a07182d1810d0f1397c25049b0841b462a 100755 (executable)
@@ -23,14 +23,8 @@ export LC_ALL=C # the following is vulnerable to i18n
 
 ARCH=`uname -m`
 
-if [ -n "$WITH_SEASTAR" ]; then
-    with_seastar=true
-else
-    with_seastar=false
-fi
-
 function install_seastar_deps {
-    if $with_seastar; then
+    if [ $WITH_SEASTAR ]; then
         $SUDO env DEBIAN_FRONTEND=noninteractive apt-get install -y \
               ragel libc-ares-dev libhwloc-dev libnuma-dev libpciaccess-dev \
               libcrypto++-dev libgnutls28-dev libsctp-dev libprotobuf-dev \
@@ -46,7 +40,7 @@ function munge_ceph_spec_in {
     else
         sed -i -e 's/%bcond_without python2/%bcond_with python2/g' $OUTFILE
     fi
-    if $with_seastar; then
+    if [ $WITH_SEASTAR ]; then
         sed -i -e 's/%bcond_with seastar/%bcond_without seastar/g' $OUTFILE
     fi
 }