Skip to content

Commit

Permalink
allow build script customizations (#110)
Browse files Browse the repository at this point in the history
  • Loading branch information
copperlight authored Dec 2, 2024
1 parent 6060950 commit b1fa055
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,21 @@ set -e

# usage: ./build.sh [clean|clean --confirm|skiptest]

BUILD_DIR=cmake-build
# Choose: Debug, Release, RelWithDebInfo and MinSizeRel. Use Debug for asan checking locally.
BUILD_TYPE=Debug
if [[ -z "$BUILD_DIR" ]]; then
BUILD_DIR="cmake-build"
fi

if [[ -z "$BUILD_TYPE" ]]; then
# Choose: Debug, Release, RelWithDebInfo and MinSizeRel. Use Debug for asan checking locally.
BUILD_TYPE="Debug"
fi

BLUE="\033[0;34m"
NC="\033[0m"

if [[ "$1" == "clean" ]]; then
echo -e "${BLUE}==== clean ====${NC}"
rm -rf $BUILD_DIR
rm -rf "$BUILD_DIR"
# extracted and generated files
rm -f metatron/auth_context.pb.cc
rm -f metatron/auth_context.pb.h
Expand Down

0 comments on commit b1fa055

Please sign in to comment.