[pangomm] Begin transition to mm-common build system



commit 26a9090f2b63371c4ef3ced30889d59e37ffd8f9
Author: Daniel Elstner <danielk openismus com>
Date:   Tue Aug 11 14:46:17 2009 +0200

    Begin transition to mm-common build system
    
    * autogen.sh: Replace with minimal version using mm-common-prepare
    and autoreconf.
    * configure.ac: Rename file from configure.in.  Remove a lot of old
    cruft and clean up the remaining bits.  Make use of mm-common macros.
    Insert temporary dummy conditionals to keep the module buildable.
    * config.h.in: Delete file, as it is now generated by autoheader.
    * Makefile.am (ACLOCAL_AMFLAGS): Set to help autoreconf do its work.
    * MSVC_Net200[58]/pangomm/Makefile.am: Change rule dependency
    configure.in to configure.ac.

 ChangeLog                        |   14 ++
 MSVC_Net2005/pangomm/Makefile.am |    2 +-
 MSVC_Net2008/pangomm/Makefile.am |    2 +-
 Makefile.am                      |   24 +++-
 autogen.sh                       |  117 +---------------
 config.h.in                      |    7 -
 configure.ac                     |  102 ++++++++++++++
 configure.in                     |  277 --------------------------------------
 8 files changed, 145 insertions(+), 400 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index fd916b7..a2d5c90 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2009-08-11  Daniel Elstner  <danielk openismus com>
+
+	Begin transition to mm-common build system
+
+	* autogen.sh: Replace with minimal version using mm-common-prepare
+	and autoreconf.
+	* configure.ac: Rename file from configure.in.  Remove a lot of old
+	cruft and clean up the remaining bits.  Make use of mm-common macros.
+	Insert temporary dummy conditionals to keep the module buildable.
+	* config.h.in: Delete file, as it is now generated by autoheader.
+	* Makefile.am (ACLOCAL_AMFLAGS): Set to help autoreconf do its work.
+	* MSVC_Net200[58]/pangomm/Makefile.am: Change rule dependency
+	configure.in to configure.ac.
+
 2009-03-09  Theppitak Karoonboonyanan  <thep linux thai net>	
 
 	* docs/reference/Makefile.am: Split out devhelp installation rule, so
diff --git a/MSVC_Net2005/pangomm/Makefile.am b/MSVC_Net2005/pangomm/Makefile.am
index 3d7ceaf..236d67b 100644
--- a/MSVC_Net2005/pangomm/Makefile.am
+++ b/MSVC_Net2005/pangomm/Makefile.am
@@ -8,5 +8,5 @@ EXTRA_DIST = pangommconfig.h pangomm.vcproj pangomm.rc
 # wht respect to the .h.in file, to prevent an error with 'make distcheck'.
 # See http://sources.redhat.com/automake/automake.html#distcleancheck
 
-pangommconfig.h: $(top_srcdir)/pango/pangommconfig.h.in $(top_srcdir)/configure.in
+pangommconfig.h: $(top_srcdir)/pango/pangommconfig.h.in $(top_srcdir)/configure.ac
 	cp -f $(top_builddir)/pango/pangommconfig.h $@
diff --git a/MSVC_Net2008/pangomm/Makefile.am b/MSVC_Net2008/pangomm/Makefile.am
index 3d7ceaf..236d67b 100644
--- a/MSVC_Net2008/pangomm/Makefile.am
+++ b/MSVC_Net2008/pangomm/Makefile.am
@@ -8,5 +8,5 @@ EXTRA_DIST = pangommconfig.h pangomm.vcproj pangomm.rc
 # wht respect to the .h.in file, to prevent an error with 'make distcheck'.
 # See http://sources.redhat.com/automake/automake.html#distcleancheck
 
-pangommconfig.h: $(top_srcdir)/pango/pangommconfig.h.in $(top_srcdir)/configure.in
+pangommconfig.h: $(top_srcdir)/pango/pangommconfig.h.in $(top_srcdir)/configure.ac
 	cp -f $(top_builddir)/pango/pangommconfig.h $@
diff --git a/Makefile.am b/Makefile.am
index 2d62f0f..8f09687 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,5 +1,25 @@
-SUBDIRS		= tools pango MSVC_Net2005 MSVC_Net2008 @DOCS_SUBDIR@
-DIST_SUBDIRS	= $(SUBDIRS) scripts
+## Copyright (c) 2009  Openismus GmbH  <http://www.openismus.com/>
+##
+## This file is part of pangomm.
+##
+## pangomm is free software: you can redistribute it and/or modify it
+## under the terms of the GNU Lesser General Public License as published
+## by the Free Software Foundation, either version 2.1 of the License,
+## or (at your option) any later version.
+##
+## pangomm is distributed in the hope that it will be useful, but
+## WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+## See the GNU Lesser General Public License for more details.
+##
+## You should have received a copy of the GNU Lesser General Public License
+## along with this library.  If not, see <http://www.gnu.org/licenses/>.
+
+ACLOCAL_AMFLAGS = -I scripts ${ACLOCAL_FLAGS}
+DISTCHECK_CONFIGURE_FLAGS = --enable-warnings=fatal
+
+SUBDIRS = tools pango
+DIST_SUBDIRS = tools pango tests docs scripts MSVC_Net2005 MSVC_Net2008
 
 EXTRA_DIST	= build_shared/Makefile_build.am_fragment \
 		  build_shared/Makefile_build_gensrc.am_fragment \
diff --git a/autogen.sh b/autogen.sh
index 2b1a8a4..fed2c5b 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -1,114 +1,7 @@
-#! /bin/sh
-
-# Copyright (c) 2006, The pangomm Development Team
-#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License, or (at your option) any later version.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
-
-# Be Bourne compatible. (stolen from autoconf)
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
-  set -o posix
-fi
-
-PROJECT=pangomm
-MIN_AUTOMAKE_VERSION=1.9
-
-srcdir=`dirname "$0"`
+#! /bin/sh -e
+test -n "$srcdir" || srcdir=`dirname "$0"`
 test -n "$srcdir" || srcdir=.
 
-origdir=`pwd`
-cd "$srcdir"
-
-LIBTOOLIZE_FLAGS="--automake $LIBTOOLIZE_FLAGS"
-ACLOCAL_FLAGS="-I scripts $ACLOCAL_FLAGS"
-AUTOMAKE_FLAGS="--add-missing $AUTOMAKE_FLAGS"
-
-if test "x$*$AUTOGEN_SUBDIR_MODE" = x
-then
-  echo "I am going to run ./configure with no arguments -- if you wish"
-  echo "to pass any to it, please specify them on the $0 command line."
-fi
-
-libtoolize=libtoolize
-autoconf=autoconf
-autoheader=autoheader
-aclocal=
-automake=
-auto_version=0
-
-# awk program to transform the output of automake --version
-# into an integer value suitable for numeric comparison.
-extract_version='{ printf "%.0f", 1000000 * v[split($1, v, " ")] + 1000 * $2 + $3; exit }'
-
-for suffix in -1.7 -1.8 -1.9 ""
-do
-  aclocal_version=`aclocal$suffix --version </dev/null 2>/dev/null | awk -F. "$extract_version"`
-  automake_version=`automake$suffix --version </dev/null 2>/dev/null | awk -F. "$extract_version"`
-
-  if test "$aclocal_version" -eq "$automake_version" 2>/dev/null \
-     && test "$automake_version" -ge "$auto_version" 2>/dev/null
-  then
-    auto_version=$automake_version
-    aclocal=aclocal$suffix
-    automake=automake$suffix
-  fi
-done
-
-min_version=`echo "$MIN_AUTOMAKE_VERSION" | awk -F. "$extract_version"`
-
-if test "$auto_version" -ge "$min_version" 2>/dev/null
-then :; else
-  echo "Sorry, at least automake $MIN_AUTOMAKE_VERSION is required to configure $PROJECT."
-  exit 1
-fi
-
-rm -f config.guess config.sub depcomp install-sh missing mkinstalldirs
-rm -f config.cache acconfig.h
-rm -rf autom4te.cache
-
-#WARNINGS=all
-#export WARNINGS
-
-if (set -x && set +x) >/dev/null 2>&1
-then
-  set_xtrace=set
-else
-  set_xtrace=:
-fi
-
-$set_xtrace -x
-
-"$libtoolize" $LIBTOOLIZE_FLAGS	|| exit 1
-"$aclocal" $ACLOCAL_FLAGS	|| exit 1
-#"$autoheader"			|| exit 1
-"$automake" $AUTOMAKE_FLAGS	|| exit 1
-"$autoconf"			|| exit 1
-cd "$origdir"			|| exit 1
-
-if test -z "$AUTOGEN_SUBDIR_MODE"
-then
-  "$srcdir/configure" --enable-maintainer-mode ${1+"$@"} || exit 1
-  $set_xtrace +x
-  echo
-  echo "Now type 'make' to compile $PROJECT."
-fi
-
-exit 0
+mm-common-prepare --force --copy "$srcdir"
+autoreconf --force --install "$srcdir"
+test -n "$NOCONFIGURE" || "$srcdir/configure" --enable-maintainer-mode "$@"
diff --git a/configure.ac b/configure.ac
new file mode 100644
index 0000000..b64294f
--- /dev/null
+++ b/configure.ac
@@ -0,0 +1,102 @@
+## Copyright (c) 2009  Openismus GmbH  <http://www.openismus.com/>
+##
+## This file is part of pangomm.
+##
+## pangomm is free software: you can redistribute it and/or modify it
+## under the terms of the GNU Lesser General Public License as published
+## by the Free Software Foundation, either version 2.1 of the License,
+## or (at your option) any later version.
+##
+## pangomm is distributed in the hope that it will be useful, but
+## WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+## See the GNU Lesser General Public License for more details.
+##
+## You should have received a copy of the GNU Lesser General Public License
+## along with this library.  If not, see <http://www.gnu.org/licenses/>.
+
+AC_INIT([pangomm], [2.24.0], [http://bugzilla.gnome.org/enter_bug.cgi?product=pangomm],
+        [pangomm], [http://www.gtkmm.org/])
+AC_PREREQ([2.59])
+
+AC_CONFIG_SRCDIR([pango/pangomm.h])
+AC_CONFIG_AUX_DIR([scripts])
+AC_CONFIG_MACRO_DIR([scripts])
+AC_CONFIG_HEADERS([config.h pango/pangommconfig.h])
+
+MM_INIT_MODULE([pangomm-1.4], m4_expand([AC_PACKAGE_VERSION]))
+
+# http://www.gnu.org/software/libtool/manual/html_node/Updating-version-info.html
+AC_SUBST([LIBPANGOMM_SO_VERSION], [1:30:0])
+
+AM_INIT_AUTOMAKE([1.9 -Wno-portability dist-bzip2 no-define nostdinc tar-pax])
+AM_MAINTAINER_MODE
+AC_ARG_VAR([ACLOCAL_FLAGS], [aclocal flags, e.g. -I <macro dir>])
+
+AC_PROG_CXX
+AC_DISABLE_STATIC
+AC_LIBTOOL_WIN32_DLL
+AC_PROG_LIBTOOL
+
+AC_SUBST([PANGOMM_MODULES], ['glibmm-2.4 >= 2.14.1 cairomm-1.0 >= 1.2.2 pangocairo >= 1.23.0'])
+PKG_CHECK_MODULES([PANGOMM], [$PANGOMM_MODULES])
+
+MM_PKG_CONFIG_SUBST([GTHREAD_CFLAGS], [--cflags-only-other gthread-2.0])
+MM_PKG_CONFIG_SUBST([GMMPROC_DIR], [--variable=gmmprocdir glibmm-2.4])
+
+AC_LANG([C++])
+
+MM_ARG_ENABLE_WARNINGS([PANGOMM_WXXFLAGS],
+                       [-Wall],
+                       [-pedantic -Wall -Wextra],
+                       [G PANGO])
+
+AC_ARG_ENABLE([deprecated-api],
+              [AS_HELP_STRING([--disable-deprecated-api],
+                              [omit deprecated API from the library])],
+              [pangomm_deprecated_api=$enableval],
+              [pangomm_deprecated_api=yes])
+AS_IF([test "x$pangomm_deprecated_api" = xyes],
+[
+  AC_MSG_NOTICE([[Deprecated API will be built, for backwards-compatibility.]])
+  DISABLE_DEPRECATED_API_CFLAGS=dnl
+], [
+  AC_MSG_WARN([[Deprecated API will not be built, breaking backwards-compatibility.
+Do not use this option for distribution packages.]])
+  DISABLE_DEPRECATED_API_CFLAGS='-DPANGOMM_DISABLE_DEPRECATED'dnl
+])
+AC_SUBST([DISABLE_DEPRECATED_API_CFLAGS])
+
+# TODO: Remove dummies
+AC_SUBST([GMMPROC], ['${GMMPROC_DIR}/gmmproc'])
+AM_CONDITIONAL([OS_WIN32], [false])
+AM_CONDITIONAL([PLATFORM_WIN32], [false])
+
+AC_CONFIG_FILES([
+  Makefile
+
+  pango/Makefile
+  pango/pangomm-1.4.pc
+    pango/src/Makefile
+    pango/pangomm/Makefile
+      pango/pangomm/private/Makefile
+
+  tools/Makefile
+    tools/m4/Makefile
+    tools/extra_defs_gen/Makefile
+
+  MSVC_Net2005/Makefile
+    MSVC_Net2005/gendef/Makefile
+    MSVC_Net2005/pangomm/Makefile
+    MSVC_Net2005/pangomm/pangomm.rc
+  MSVC_Net2008/Makefile
+    MSVC_Net2008/gendef/Makefile
+    MSVC_Net2008/pangomm/Makefile
+    MSVC_Net2008/pangomm/pangomm.rc
+])
+
+AC_CONFIG_FILES([
+  scripts/Makefile
+])
+
+AC_OUTPUT



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]