diff configure.ac @ 1936:a55b1c903628

branch merge
author William Pitcock <nenolod@atheme.org>
date Mon, 01 Oct 2007 15:35:02 -0500
parents 266f1bf0d5fc
children f86cb7fc1d4f
line wrap: on
line diff
--- a/configure.ac	Mon Oct 01 15:34:40 2007 -0500
+++ b/configure.ac	Mon Oct 01 15:35:02 2007 -0500
@@ -22,6 +22,11 @@
 	CPPFLAGS="$CPPFLAGS -I/usr/X11R6/include"
 fi
 
+dnl append audacious header path to CPPFLAGS when --prefix is specified.
+if test "$prefix" != "NONE" ; then
+   CPPFLAGS="$CPPFLAGS -I${includedir}"
+fi
+
 dnl OMK bootstrap
 AC_SUBST([PACKAGE], [AC_PACKAGE_TARNAME])
 AC_SUBST([VERSION], [AC_PACKAGE_VERSION])
@@ -185,6 +190,8 @@
 dnl ========================
 
 BUILDSYS_SHARED_LIB
+BUILDSYS_PROG_IMPLIB
+test x"$PROG_IMPLIB_NEEDED" = x"yes" && LIBS="$LIBS -L\${libdir} -laudacious.exe"
 
 dnl Ok, first we find out what flags we need to use.
 AC_MSG_CHECKING([for what extension and flags to use for plugin compilation])
@@ -1364,7 +1371,7 @@
 	CONTAINER_PLUGINS="$CONTAINER_PLUGINS xspf"
 fi
 
-dnl *** ProjectM (GL Milkdrop port)
+dnl *** projectM (GL Milkdrop port)
 
 AC_ARG_ENABLE(projectm,
 [  --disable-projectm      disable projectM vis plugin. (default=enabled)],
@@ -1372,7 +1379,7 @@
 [have_projectm=yes])
 
 if test "$have_projectm" = "yes"; then
-	PKG_CHECK_MODULES(LIBPROJECTM, libprojectM >= 0.0.0, [have_projectm="yes"], [have_projectm="no"])
+	PKG_CHECK_MODULES(LIBPROJECTM, libprojectM < 1.0, [have_projectm="yes"], [have_projectm="no"])
 	AM_PATH_SDL(1.2.5, , [
 		AC_MSG_WARN([*** SDL is not installed. projectM will not be built. ***])
 		have_projectm="no"
@@ -1380,7 +1387,7 @@
 	if test x$libprjM = xno; then
 	        AC_MSG_WARN([*** libprojectM not found.
 	                        libprojectM is needed to build this package.
-	                        You can download libprojectM at http://xmms-projectM.sf.net/])
+	                        You can download libprojectM at http://projectm.sf.net/])
 	fi
 	LIBPROJECTM_datadir=`pkg-config --variable=pkgdatadir libprojectM`;
 	LIBPROJECTM_sysconfdir=`pkg-config --variable=sysconfdir libprojectM`;
@@ -1393,6 +1400,36 @@
 	VISUALIZATION_PLUGINS="$VISUALIZATION_PLUGINS projectm"
 fi
 
+dnl *** projectM (GL Milkdrop port)
+
+AC_ARG_ENABLE(projectm-1.0,
+[  --disable-projectm-1.0      disable projectM 1.0+ vis plugin. (default=enabled)],
+[have_projectm1=$enableval],
+[have_projectm1=yes])
+
+if test "$have_projectm1" = "yes"; then
+	PKG_CHECK_MODULES(LIBPROJECTM1, libprojectM >= 1.0, [have_projectm1="yes"], [have_projectm1="no"])
+	AM_PATH_SDL(1.2.5, , [
+		AC_MSG_WARN([*** SDL is not installed. projectM will not be built. ***])
+		have_projectm1="no"
+	])
+	if test x$libprjM = xno; then
+	        AC_MSG_WARN([*** libprojectM not found.
+	                        libprojectM is needed to build this package.
+	                        You can download libprojectM at http://projectm.sf.net/])
+	fi
+	LIBPROJECTM1_datadir=`pkg-config --variable=pkgdatadir libprojectM`;
+	LIBPROJECTM1_sysconfdir=`pkg-config --variable=sysconfdir libprojectM`;
+        LIBPROJECTM1_prefix=`pkg-config --variable=prefix libprojectM`;
+	LIBPROJECTM1_CFLAGS="$LIBPROJECTM1_CFLAGS -DPROJECTM_DATADIR=\\\"$LIBPROJECTM1_datadir\\\" -DPROJECTM_SYSCONFDIR=\\\"$LIBPROJECTM1_sysconfdir\\\" -DPROJECTM_PREFIX=\\\"$LIBPROJECTM1_prefix\\\"";
+fi
+AC_SUBST(LIBPROJECTM1_LIBS)
+AC_SUBST(LIBPROJECTM1_CFLAGS)
+
+if test "$have_projectm1" = "yes"; then
+	VISUALIZATION_PLUGINS="$VISUALIZATION_PLUGINS projectm-1.0"
+fi
+
 dnl *** TTA
 
 AC_ARG_ENABLE(tta,
@@ -1625,7 +1662,8 @@
 echo "  Blur Scope:                             yes"
 echo "  Spectrum Analyzer:                      yes"
 echo "  Paranormal Visualization Library:       $have_paranormal"
-echo "  ProjectM (GL milkdrop):                 $have_projectm"
+echo "  projectM 0.x (GL milkdrop):             $have_projectm"
+echo "  projectM 1.x (GL milkdrop):             $have_projectm1"
 echo "  RootVis plugin:                         $have_rootvis"
 echo
 echo "  Transport"