mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
smtk2ssrf-build.sh: add building command line mode
Add a flag to build with -DCOMMANDLINE=ON
This commit is contained in:
parent
d7d8434f4e
commit
15028fd299
1 changed files with 7 additions and 2 deletions
|
|
@ -2,7 +2,8 @@
|
||||||
# This script is meant to run from src directory in the same fashion than
|
# This script is meant to run from src directory in the same fashion than
|
||||||
# subsurface/scripts/build.sh
|
# subsurface/scripts/build.sh
|
||||||
#
|
#
|
||||||
# Flags: -t (--tag) A git valid tag, commit, etc in subsurface tree
|
# Flags: -c (--cli) Build commandline version (no graphics)
|
||||||
|
# -t (--tag) A git valid tag, commit, etc in subsurface tree
|
||||||
# -j (--jobs) Desired build parallelism, integer.
|
# -j (--jobs) Desired build parallelism, integer.
|
||||||
# -b (--build) Cmake build type, valid values Debug or Release
|
# -b (--build) Cmake build type, valid values Debug or Release
|
||||||
# Examples:
|
# Examples:
|
||||||
|
|
@ -53,6 +54,8 @@ read -rs _proceed
|
||||||
#
|
#
|
||||||
while [ $# -gt 0 ]; do
|
while [ $# -gt 0 ]; do
|
||||||
case $1 in
|
case $1 in
|
||||||
|
-c|--cli) CLI="ON"
|
||||||
|
;;
|
||||||
-t|--tag) SSRF_TAG="$2"
|
-t|--tag) SSRF_TAG="$2"
|
||||||
shift;;
|
shift;;
|
||||||
-j|--jobs) JOBS=-j"$2"
|
-j|--jobs) JOBS=-j"$2"
|
||||||
|
|
@ -164,7 +167,9 @@ cd "$SSRF_PATH"/smtk-import || aborting "Couldnt cd into $SSRF_PATH/smtk-import"
|
||||||
mkdir -p build
|
mkdir -p build
|
||||||
cd build || aborting "Couldn't cd into $SSRF_PATH/smtk-import/build"
|
cd build || aborting "Couldn't cd into $SSRF_PATH/smtk-import/build"
|
||||||
|
|
||||||
cmake -DCMAKE_BUILD_TYPE="$RELEASE" .. || aborting "Cmake incomplete"
|
cmake -DCMAKE_BUILD_TYPE="$RELEASE" \
|
||||||
|
-DCOMMANDLINE=${CLI:-OFF} \
|
||||||
|
.. || aborting "Cmake incomplete"
|
||||||
|
|
||||||
make "$JOBS" || aborting "Failed to build smtk2ssrf"
|
make "$JOBS" || aborting "Failed to build smtk2ssrf"
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue