From 405945827d88e3ef8517fc73382f7357608ad750 Mon Sep 17 00:00:00 2001 From: KonAki Date: Wed, 14 Oct 2026 12:16:31 +0800 Subject: build the converters, fix konmodel tool, find X11 on the BSDs --- build.sh | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'build.sh') diff --git a/build.sh b/build.sh index 6746c49..6157307 100755 --- a/build.sh +++ b/build.sh @@ -44,6 +44,17 @@ case $platform in linux|bsd) LDLIBS="-lX11 -lXext -lXrandr -lm" DEFS="-D_POSIX_C_SOURCE=200809L" + # the BSDs keep X11 out of the default paths + case $(uname -s) in + NetBSD) x11=/usr/X11R7 ;; + OpenBSD) x11=/usr/X11R6 ;; + FreeBSD|DragonFly) x11=/usr/local ;; + *) x11= ;; + esac + if [ -n "$x11" ]; then + DEFS="$DEFS -I$x11/include" + LDLIBS="-L$x11/lib -Wl,-R$x11/lib $LDLIBS" + fi ;; windows) CC=${CC:-x86_64-w64-mingw32-gcc} -- cgit