[Xfce4-commits] r26569 - xfce4-mixer/trunk
Jannis Pohlmann
jannis at xfce.org
Mon Jan 14 02:14:09 CET 2008
Author: jannis
Date: 2008-01-14 01:14:09 +0000 (Mon, 14 Jan 2008)
New Revision: 26569
Modified:
xfce4-mixer/trunk/ChangeLog
xfce4-mixer/trunk/configure.in.in
Log:
* configure.in.in: Add support for version information, just like all
the other Xfce components have. Also add special debugging support
for SVN snapshots. Enhance the AC_COPYRIGHT value. Print build
configuration at the end of ./configure.
Modified: xfce4-mixer/trunk/ChangeLog
===================================================================
--- xfce4-mixer/trunk/ChangeLog 2008-01-14 01:09:43 UTC (rev 26568)
+++ xfce4-mixer/trunk/ChangeLog 2008-01-14 01:14:09 UTC (rev 26569)
@@ -1,5 +1,12 @@
2008-01-14 Jannis Pohlmann <jannis at xfce.org>
+ * configure.in.in: Add support for version information, just like all
+ the other Xfce components have. Also add special debugging support
+ for SVN snapshots. Enhance the AC_COPYRIGHT value. Print build
+ configuration at the end of ./configure.
+
+2008-01-14 Jannis Pohlmann <jannis at xfce.org>
+
* configure.in.in, xfce4-mixer/xfce-mixer-card.{c,h},
xfce4-mixer/xfce-mixer.c: Add optional support for the GstMixer
notification API. It uses GstBus and GstMixerMessages. The latter
Modified: xfce4-mixer/trunk/configure.in.in
===================================================================
--- xfce4-mixer/trunk/configure.in.in 2008-01-14 01:09:43 UTC (rev 26568)
+++ xfce4-mixer/trunk/configure.in.in 2008-01-14 01:14:09 UTC (rev 26569)
@@ -4,10 +4,29 @@
dnl
dnl ***************************
+dnl *** Version information ***
+dnl ***************************
+m4_define([xfce4_mixer_version_major], [4])
+m4_define([xfce4_mixer_version_minor], [5])
+m4_define([xfce4_mixer_version_micro], [0])
+m4_define([xfce4_mixer_version_nano], []) dnl leave this empty to have no nano version
+m4_define([xfce4_mixer_version_build], [r at REVISION@])
+m4_define([xfce4_mixer_version_tag], [svn])
+m4_define([xfce4_mixer_version], [xfce4_mixer_version_major().xfce4_mixer_version_minor().xfce4_mixer_version_micro()ifelse(xfce4_mixer_version_nano(), [], [], [.xfce4_mixer_version_nano()])ifelse(xfce4_mixer_version_tag(), [svn], [xfce4_mixer_version_tag()-xfce4_mixer_version_build()], [xfce4_mixer_version_tag()])])
+
+dnl *******************************************
+dnl *** Debugging support for SVN snapshots ***
+dnl *******************************************
+m4_define([mixer_debug_default], [ifelse(xfce4_mixer_version_tag(), [svn], [full], [minimum])])
+
+dnl ***************************
dnl *** Initialize autoconf ***
dnl ***************************
-AC_COPYRIGHT([Copyright (c) 2007 Jannis Pohlmann <jannis at xfce.org>])
-AC_INIT([xfce4-mixer], [4.5.0], [jannis at xfce.org], [xfce4-mixer])
+AC_COPYRIGHT([Copyright (c) 2008
+ The Xfce development team. All rights reserved.
+
+Written for Xfce by Jannis Pohlmann <jannis at xfce.org>.])
+AC_INIT([xfce4-mixer], [xfce4_mixer_version], [http://bugzilla.xfce.org/], [xfce4-mixer])
AC_REVISION([$Id$])
AC_PREREQ([2.50])
@@ -76,8 +95,61 @@
dnl ***********************************
dnl *** Check for debugging support ***
dnl ***********************************
-BM_DEBUG_SUPPORT()
+AC_ARG_ENABLE([debug],
+AC_HELP_STRING([--enable-debug=@<:@no/minimum/yes/full@:>@],
+ [Turn on debugging @<:@default=mixer_debug_default@:>@]),
+ [], [enable_debug=mixer_debug_default])
+AC_MSG_CHECKING([whether to enable debugging support])
+if test x"$enable_debug" = x"full" -o x"$enable_debug" = x"yes"; then
+ dnl Print the result
+ AC_MSG_RESULT([$enable_debug])
+ dnl Make sure we detect possible errors (if supported)
+ save_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -Wall -Werror"
+ AC_MSG_CHECKING([whether $CC accepts -Wall -Werror])
+ AC_COMPILE_IFELSE(AC_LANG_SOURCE([int x;]), [
+ AC_MSG_RESULT([yes])
+ PLATFORM_CFLAGS="$PLATFORM_CFLAGS -Wall -Werror"
+ ], [
+ AC_MSG_RESULT([no])
+ ])
+ CFLAGS="$save_CFLAGS"
+
+ dnl Paranoia for --enable-debug=full
+ if test x"$enable_debug" = x"full"; then
+ dnl Enable extensive debugging
+ PLATFORM_CPPFLAGS="$PLATFORM_CPPFLAGS -DG_ENABLE_DEBUG"
+
+ dnl Use -O0 -g3 if the compiler supports it
+ save_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -O0 -g3"
+ AC_MSG_CHECKING([whether $CC accepts -O0 -g3])
+ AC_COMPILE_IFELSE(AC_LANG_SOURCE([int x;]), [
+ AC_MSG_RESULT([yes])
+ PLATFORM_CFLAGS="$PLATFORM_CFLAGS -O0 -g3"
+ ], [
+ AC_MSG_RESULT([no])
+ ])
+ CFLAGS="$save_CFLAGS"
+ fi
+else
+ dnl Print the result
+ AC_MSG_RESULT([$enable_debug])
+
+ dnl Disable debugging (release build)
+ PLATFORM_CPPFLAGS="$PLATFORM_CPPFLAGS -DNDEBUG"
+
+ dnl Disable object cast checks
+ PLATFORM_CPPFLAGS="$PLATFORM_CPPFLAGS -DG_DISABLE_CAST_CHECKS"
+
+ dnl Disable all checks for --enable-debug=no
+ if test x"$enable_debug" = x"no"; then
+ PLATFORM_CPPFLAGS="$PLATFORM_CPPFLAGS -DG_DISABLE_ASSERT -DG_DISABLE_CHECKS"
+ fi
+fi
+
+
AC_OUTPUT([
Makefile
icons/Makefile
@@ -89,3 +161,16 @@
xfce4-mixer/Makefile
po/Makefile.in
])
+
+dnl ***************************
+dnl *** Print configuration ***
+dnl ***************************
+echo
+echo "Build Configuration:"
+echo
+if test "x$HAVE_GST_MIXER_NOTIFICATION" = "xyes"; then
+echo " * GStreamer mixer notification support: yes"
+else
+echo " * GStreamer mixer notification support: no"
+fi
+echo
More information about the Xfce4-commits
mailing list