summaryrefslogtreecommitdiff
path: root/m4/baltisot.m4
diff options
context:
space:
mode:
authorpixel <pixel>2002-12-06 18:54:59 +0000
committerpixel <pixel>2002-12-06 18:54:59 +0000
commit70ab3da408f5939fbfec4237e87f503ae82b2179 (patch)
treecc2e867aa3d57fe7bead0e9fbf1b1cba9008eac5 /m4/baltisot.m4
parent4e771e092cfb1d8c2850205285ba480e7376a186 (diff)
Commit of the day.
Diffstat (limited to 'm4/baltisot.m4')
-rw-r--r--m4/baltisot.m453
1 files changed, 53 insertions, 0 deletions
diff --git a/m4/baltisot.m4 b/m4/baltisot.m4
new file mode 100644
index 0000000..bcb75e9
--- /dev/null
+++ b/m4/baltisot.m4
@@ -0,0 +1,53 @@
+# Configure paths for Baltisot
+# Nicolas Noble 2002-12-06
+# stolen from Sam Lantinga
+# stolen from Manish Singh
+# stolen back from Frank Belew
+# stolen from Manish Singh
+# Shamelessly stolen from Owen Taylor
+
+dnl AM_PATH_SDL([ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
+dnl Test for BALTISOT, and define BALTISOT_CFLAGS and BALTISOT_LIBS
+dnl
+AC_DEFUN(AM_PATH_BALTISOT,
+[dnl
+dnl Get the cflags and libraries from the baltisot-config script
+dnl
+AC_ARG_WITH(baltisot-prefix,[ --with-baltisot-prefix=PFX Prefix where Baltisot is installed (optional)],
+ baltisot_prefix="$withval", baltisot_prefix="")
+AC_ARG_WITH(baltisot-exec-prefix,[ --with-baltisot-exec-prefix=PFX Exec prefix where Baltisot is installed (optional)],
+ baltisot_exec_prefix="$withval", baltisot_exec_prefix="")
+
+ if test x$baltisot_exec_prefix != x ; then
+ baltisot_args="$baltisot_args --exec-prefix=$baltisot_exec_prefix"
+ if test x${BALTISOT_CONFIG+set} != xset ; then
+ BALTISOT_CONFIG=$baltisot_exec_prefix/bin/baltisot-config
+ fi
+ fi
+ if test x$baltisot_prefix != x ; then
+ baltisot_args="$baltisot_args --prefix=$baltisot_prefix"
+ if test x${BALTISOT_CONFIG+set} != xset ; then
+ BALTISOT_CONFIG=$baltisot_prefix/bin/baltisot-config
+ fi
+ fi
+
+ PATH="$prefix/bin:$prefix/usr/bin:$PATH"
+ AC_PATH_PROG(BALTISOT_CONFIG, baltisot-config, no, [$PATH])
+ no_baltisot=""
+ if test "$BALTISOT_CONFIG" = "no" ; then
+ no_baltisot=yes
+ else
+ BALTISOT_CFLAGS=`$BALTISOT_CONFIG $baltisotconf_args --cflags`
+ BALTISOT_LIBS=`$BALTISOT_CONFIG $baltisotconf_args --libs`
+ fi
+
+ if test "x$no_baltisot" = x ; then
+ ifelse([$1], , :, [$1])
+ else
+ BALTISOT_CFLAGS=""
+ BALTISOT_LIBS=""
+ ifelse([$2], , :, [$2])
+ fi
+ AC_SUBST(BALTISOT_CFLAGS)
+ AC_SUBST(BALTISOT_LIBS)
+])