From 0cb00ae734219e1ace4b1c9b80d35d37d2afaab6 Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Fri, 24 Apr 2020 18:30:23 +0200 Subject: [PATCH] build.sh: adding --cli and --no-gui flags to compliment --no-cli and --gui --- build.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/build.sh b/build.sh index 7bab057..4988843 100755 --- a/build.sh +++ b/build.sh @@ -1,11 +1,11 @@ #!/bin/bash function usage() { - echo "Usage: ${0##*/} [ -h|--help ] [ --no-cli ] [ --gui] [ -t|--type Debug|Release|RelWithDebInfo|MinSizeRel ] [--pkg-type nsis|deb|zip|tgz] [ --disable-threads ] [ --force-ansi ]" + echo "Usage: ${0##*/} [ -h|--help ] [ --cli|--no-cli ] [ --gui|--no-gui] [ -t|--type Debug|Release|RelWithDebInfo|MinSizeRel ] [--pkg-type nsis|deb|zip|tgz] [ --disable-threads ] [ --force-ansi ]" exit 1 } -options=$(getopt -n "${0##*/}" -o "lht:" -l "help,no-cli,gui,type:,pkg-type:,disable-threads,force-ansi" -- "$@") +options=$(getopt -n "${0##*/}" -o "lht:" -l "help,cli,no-cli,gui,no-gui,type:,pkg-type:,disable-threads,force-ansi" -- "$@") [ $? -eq 0 ] || usage @@ -33,10 +33,14 @@ while true; do TARGET="package" ARGS="${ARGS} -DCPACK_GENERATOR=${1^^}" ;; + --cli) + ARGS="${ARGS} -DCOMPONENT_CLI=ON" ;; --no-cli) ARGS="${ARGS} -DCOMPONENT_CLI=OFF" ;; --gui) ARGS="${ARGS} -DCOMPONENT_GUI=ON" ;; + --no-gui) + ARGS="${ARGS} -DCOMPONENT_GUI=OFF" ;; --disable-threads) ARGS="${ARGS} -DUSE_THREADS=OFF" ;; --force-ansi)