From 56449e59d7aabd1c06fb67a51a1e129b55cb9270 Mon Sep 17 00:00:00 2001 From: yuuko Date: Thu, 29 Aug 2024 21:51:04 -0700 Subject: break out of system config --- srcds-pkgs/sourcemod/setup-hook.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 srcds-pkgs/sourcemod/setup-hook.sh (limited to 'srcds-pkgs/sourcemod/setup-hook.sh') diff --git a/srcds-pkgs/sourcemod/setup-hook.sh b/srcds-pkgs/sourcemod/setup-hook.sh new file mode 100644 index 0000000..17d8617 --- /dev/null +++ b/srcds-pkgs/sourcemod/setup-hook.sh @@ -0,0 +1,16 @@ +SPCOMPFLAGS=${SPCOMPFLAGS:-} +dontUseSourcepawnFindHeaders=${dontUseSourcepawnFindHeaders:-} +sourcepawnFindHeaders(){ + [ -n "${dontUseSourcepawnFindHeaders:-}" ] && return + for plug in $buildInputs; do + local ipath="$plug/share/addons/sourcemod/scripting/include" + if [ -d "$ipath" ]; then + echo "found sourcepawn headers: \"$ipath\"" + SPCOMPFLAGS="$SPCOMPFLAGS -i $ipath" + fi + done + dontUseSourcepawnFindHeaders=1 + export SPCOMPFLAGS dontUseSourcepawnFindHeaders +} + +addEnvHooks "$targetOffset" sourcepawnFindHeaders -- cgit v1.2.3