From 41c391009e04fe915254708fe119211ee2ba482d Mon Sep 17 00:00:00 2001 From: KonAki Date: Thu, 8 Oct 2026 16:54:47 +0800 Subject: Hook audio, ui and debug into the build --- build.sh | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'build.sh') diff --git a/build.sh b/build.sh index 766f14f..b441b9a 100755 --- a/build.sh +++ b/build.sh @@ -12,7 +12,7 @@ developer=0 usage() { echo "usage: build.sh [-d] [-D] [-p platform] [-m module,...] [-o objdir] [target ...]" - echo "modules: font toml tile pack assets image audio" + echo "modules: font toml tile pack ui debug assets image audio" echo "platforms: native linux bsd windows" echo "targets: all run clean tools pack" exit 1 @@ -77,7 +77,7 @@ addobj() for m in $modules; do DEFS="$DEFS -DKON_MODULE_$(echo "$m" | tr 'a-z' 'A-Z')" case $m in - font|toml|tile|pack) addobj "kon$m" ;; + font|toml|tile|pack|ui|debug) addobj "kon$m" ;; assets) addobj konassets ;; image) addobj stb_image ;; audio) @@ -95,6 +95,16 @@ done case " $modules " in *" assets "*) addobj konpack ;; esac +case " $modules " in +*" ui "*) addobj konfont ;; +esac +case " $modules " in +*" debug "*) addobj konfont; addobj konassets; addobj konpack ;; +esac + +case " $modules " in +*" debug "*) [ $developer = 1 ] || echo "note: debug module does nothing without -d or -D" ;; +esac OBJDIR=$objdir export CC EXE LDLIBS MODEFLAGS DEFS OBJDIR MODOBJS -- cgit