build_scripts

This commit is contained in:
2022-08-16 15:54:23 +06:00
parent 914d4c4e10
commit 62963e6666
8 changed files with 38 additions and 13 deletions

View File

@@ -5,6 +5,7 @@ source build_scripts/init.sh
print "${CYAN}===============[build]================\n"
clear_dir "$OUTDIR"
clear_dir "$OBJDIR"
compile_c "$BUILD_C_ARGS" "$SRC_C $TESTS_C"
compile_cpp "$BUILD_CPP_ARGS" "$SRC_CPP $TESTS_CPP"
link "$BUILD_CPP_ARGS $BUILD_LINKER_ARGS" $BUILD_FILE
compile_c "$BUILD_C_ARGS" "$SRC_C"
compile_cpp "$BUILD_CPP_ARGS" "$SRC_CPP"
ar x deps/* --output=obj
link "$BUILD_CPP_ARGS $BUILD_LINKER_ARGS" "$BUILD_FILE"

View File

@@ -5,6 +5,6 @@ source build_scripts/init.sh
print "${CYAN}=============[build_dbg]==============\n"
clear_dir "$OUTDIR"
clear_dir "$OBJDIR"
compile_c "$BUILD_DBG_C_ARGS" "$SRC_C $TESTS_C"
compile_cpp "$BUILD_DBG_CPP_ARGS" "$SRC_CPP $TESTS_CPP"
link "$BUILD_DBG_CPP_ARGS $BUILD_DBG_LINKER_ARGS" $TEST_DBG_FILE
compile_c "$BUILD_DBG_C_ARGS" "$SRC_C"
compile_cpp "$BUILD_DBG_CPP_ARGS" "$SRC_CPP"
link "$BUILD_DBG_CPP_ARGS $BUILD_DBG_LINKER_ARGS" "$BUILD_FILE"

View File

@@ -4,5 +4,5 @@ source build_scripts/init.sh
print "${CYAN}================[test]================\n"
cd $OUTDIR
./$TEST_FILE
./$BUILD_FILE
cd ..

View File

@@ -4,6 +4,6 @@ source build_scripts/init.sh
print "${CYAN}===========[test_valgrind]============\n"
cd $OUTDIR
valgrind $VALGRIND_ARGS ./$TEST_DBG_FILE
valgrind $VALGRIND_ARGS ./$BUILD_DBG_FILE
cat "valgrind.log"
cd ..