QCCVERSIONFILE := qccversion.$(shell (cd server && $(QCC) --version) > qccversion.txt && git hash-object qccversion.txt)
-# We eventually need to get rid of these.
+# We eventually need to get rid of these
QCCFLAGS_WTFS ?= \
-Wno-field-redeclared
QCCFLAGS_FEATURES ?= \
- -DVEHICLES_ENABLED=1 \
- -DVEHICLES_USE_ODE=0 \
-DBUILD_MOD=$(BUILD_MOD)
# -Ooverlap-locals is required
-
QCCFLAGS ?= \
-std=gmqcc \
-Ooverlap-locals \
#include "../turrets/sv_turrets.qh"
-// #define VEHICLES_USE_ODE
-
// vehicle cvars
float autocvar_g_vehicles;
float autocvar_g_vehicles_enter;
-Wno-unused-variable
-Wno-implicit-function-pointer
)
-declare -a FEATURES=(
- -DVEHICLES_ENABLED=1
- -DVEHICLES_USE_ODE=0
-)
declare QCC=../../../gmqcc/gmqcc
declare -a QCC_FLAGS=(
-futf8
-freturn-assignments
-frelaxed-switch
- -O3
+ -Ooverlap-locals
)
function check() {
declare -la predefs=("-D${2}" "lib/_all.inc" "${base}/_all.qh")
find "$base" -type f -name '*.qc' -print0 | sort -z | while read -r -d '' file; do
echo "$file"
- ${QCC} "${QCC_FLAGS[@]}" "${NOWARN[@]}" "${FEATURES[@]}" "${predefs[@]}" "$file" >/dev/null
+ ${QCC} "${QCC_FLAGS[@]}" "${NOWARN[@]}" "${predefs[@]}" "$file" >/dev/null
done
}