/bin/build.sh: search for ninja and use it by default
This commit is contained in:
parent
64433cbe18
commit
ef5d609f4a
13
bin/build.sh
13
bin/build.sh
@ -1,7 +1,12 @@
|
|||||||
#!/bin/env sh
|
#!/bin/env sh
|
||||||
|
|
||||||
if [ "$1" = "web" ]; then
|
# check whether ninja is around (you better start running)
|
||||||
emcmake cmake -B .build-web "${@:2}" && cmake --build .build-web --parallel
|
if [ -x "$(command -v ninja)" ]; then
|
||||||
else
|
generator="-G Ninja"
|
||||||
cmake -B .build "$@" && cmake --build .build --parallel
|
fi
|
||||||
|
|
||||||
|
if [ "$1" = "web" ]; then
|
||||||
|
emcmake cmake $generator -B .build-web "${@:2}" && cmake --build .build-web --parallel
|
||||||
|
else
|
||||||
|
cmake $generator -B .build "$@" && cmake --build .build --parallel
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user