require automake 1.7. Add calls to libtoolize and gtkdocize. Clean up some
authorJames Henstridge <james@daa.com.au>
Tue, 4 Mar 2003 10:10:48 +0000 (10:10 +0000)
committerJames Henstridge <jamesh@src.gnome.org>
Tue, 4 Mar 2003 10:10:48 +0000 (10:10 +0000)
2003-03-01  James Henstridge  <james@daa.com.au>

    * autogen.sh: require automake 1.7.  Add calls to libtoolize and
    gtkdocize.  Clean up some of the error messages.

    * configure.in: move version declaration to the top of the file
    (before AC_INIT), using M4 macros.
    GLIB_AC_DIVERT_BEFORE_HELP() calls no longer necessary, due to use
    of M4 macro expansion in help messages instead.
    Convert AC_ARG_WITH/AC_ARG_ENABLE calls to use AC_HELP_STRING to
    format help strings.  Use quadrigraphs to get square brackets to
    show correctly.
    Replace gtk-doc checks with a call to GTK_DOC_CHECK() macro.
    Use AC_CONFIG_COMMANDS([glibconfig.h], ...) to output
    glibconfig.h, so that "./config.status glibconfig.h" works.
    Add an extra AC_CONFIG_FILES call listing other files we want
    generated by config.status protected by an "if false" block.  This
    way automake generates the rules needed to rebuild the files for
    us.
    Add quotes in various places.

    * docs/reference/*/Makefile.am: convert to use the common
    gtk-doc.make file.  This localises the complexity to a single
    makefile fragment maintained with gtk-doc itself.

    * */Makefile.am: remove unneeded rules to build win32 files with
    config.status.  Automake now does this for us.
    Replace instances of @FOO@ with $(FOO) where appropriate -- this
    allows automake to do a better job checking the makefile.
    Add some files to DISTCLEANFILES where appropriate

    * Makefile.am: use the DISTCHECK_CONFIGURE_FLAGS variable to
    ensure that --enable-gtk-doc is passed to configure during a
    distcheck.  Remove the custom distcheck, since the standard one
    will now do.

    * gobject/Makefile.am: switch to BUILT_SOURCES, since that now
    works.

18 files changed:
ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-12
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
Makefile.am
autogen.sh
configure.in
docs/reference/glib/Makefile.am
docs/reference/gobject/Makefile.am
glib/Makefile.am
gmodule/Makefile.am
gobject/Makefile.am
gthread/Makefile.am
po/ChangeLog
po/Makefile.in.in
tests/Makefile.am

index c274f1469a2e57396854f786d378fbf4e816a161..b0492434d5352aeb4ba285dffdfc1d8f5a9e7dcc 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,42 @@
+2003-03-01  James Henstridge  <james@daa.com.au>
+
+       * autogen.sh: require automake 1.7.  Add calls to libtoolize and
+       gtkdocize.  Clean up some of the error messages.
+
+       * configure.in: move version declaration to the top of the file
+       (before AC_INIT), using M4 macros.
+       GLIB_AC_DIVERT_BEFORE_HELP() calls no longer necessary, due to use
+       of M4 macro expansion in help messages instead.
+       Convert AC_ARG_WITH/AC_ARG_ENABLE calls to use AC_HELP_STRING to
+       format help strings.  Use quadrigraphs to get square brackets to
+       show correctly.
+       Replace gtk-doc checks with a call to GTK_DOC_CHECK() macro.
+       Use AC_CONFIG_COMMANDS([glibconfig.h], ...) to output
+       glibconfig.h, so that "./config.status glibconfig.h" works.
+       Add an extra AC_CONFIG_FILES call listing other files we want
+       generated by config.status protected by an "if false" block.  This
+       way automake generates the rules needed to rebuild the files for
+       us.
+       Add quotes in various places.
+
+       * docs/reference/*/Makefile.am: convert to use the common
+       gtk-doc.make file.  This localises the complexity to a single
+       makefile fragment maintained with gtk-doc itself.
+
+       * */Makefile.am: remove unneeded rules to build win32 files with
+       config.status.  Automake now does this for us.
+       Replace instances of @FOO@ with $(FOO) where appropriate -- this
+       allows automake to do a better job checking the makefile.
+       Add some files to DISTCLEANFILES where appropriate
+
+       * Makefile.am: use the DISTCHECK_CONFIGURE_FLAGS variable to
+       ensure that --enable-gtk-doc is passed to configure during a
+       distcheck.  Remove the custom distcheck, since the standard one
+       will now do.
+
+       * gobject/Makefile.am: switch to BUILT_SOURCES, since that now
+       works.
+
 2003-02-26  Matthias Clasen  <maclas@gmx.de>
 
        * glib/gstrfuncs.c (g_strdup_vprintf): Use g_strndup, not
index c274f1469a2e57396854f786d378fbf4e816a161..b0492434d5352aeb4ba285dffdfc1d8f5a9e7dcc 100644 (file)
@@ -1,3 +1,42 @@
+2003-03-01  James Henstridge  <james@daa.com.au>
+
+       * autogen.sh: require automake 1.7.  Add calls to libtoolize and
+       gtkdocize.  Clean up some of the error messages.
+
+       * configure.in: move version declaration to the top of the file
+       (before AC_INIT), using M4 macros.
+       GLIB_AC_DIVERT_BEFORE_HELP() calls no longer necessary, due to use
+       of M4 macro expansion in help messages instead.
+       Convert AC_ARG_WITH/AC_ARG_ENABLE calls to use AC_HELP_STRING to
+       format help strings.  Use quadrigraphs to get square brackets to
+       show correctly.
+       Replace gtk-doc checks with a call to GTK_DOC_CHECK() macro.
+       Use AC_CONFIG_COMMANDS([glibconfig.h], ...) to output
+       glibconfig.h, so that "./config.status glibconfig.h" works.
+       Add an extra AC_CONFIG_FILES call listing other files we want
+       generated by config.status protected by an "if false" block.  This
+       way automake generates the rules needed to rebuild the files for
+       us.
+       Add quotes in various places.
+
+       * docs/reference/*/Makefile.am: convert to use the common
+       gtk-doc.make file.  This localises the complexity to a single
+       makefile fragment maintained with gtk-doc itself.
+
+       * */Makefile.am: remove unneeded rules to build win32 files with
+       config.status.  Automake now does this for us.
+       Replace instances of @FOO@ with $(FOO) where appropriate -- this
+       allows automake to do a better job checking the makefile.
+       Add some files to DISTCLEANFILES where appropriate
+
+       * Makefile.am: use the DISTCHECK_CONFIGURE_FLAGS variable to
+       ensure that --enable-gtk-doc is passed to configure during a
+       distcheck.  Remove the custom distcheck, since the standard one
+       will now do.
+
+       * gobject/Makefile.am: switch to BUILT_SOURCES, since that now
+       works.
+
 2003-02-26  Matthias Clasen  <maclas@gmx.de>
 
        * glib/gstrfuncs.c (g_strdup_vprintf): Use g_strndup, not
index c274f1469a2e57396854f786d378fbf4e816a161..b0492434d5352aeb4ba285dffdfc1d8f5a9e7dcc 100644 (file)
@@ -1,3 +1,42 @@
+2003-03-01  James Henstridge  <james@daa.com.au>
+
+       * autogen.sh: require automake 1.7.  Add calls to libtoolize and
+       gtkdocize.  Clean up some of the error messages.
+
+       * configure.in: move version declaration to the top of the file
+       (before AC_INIT), using M4 macros.
+       GLIB_AC_DIVERT_BEFORE_HELP() calls no longer necessary, due to use
+       of M4 macro expansion in help messages instead.
+       Convert AC_ARG_WITH/AC_ARG_ENABLE calls to use AC_HELP_STRING to
+       format help strings.  Use quadrigraphs to get square brackets to
+       show correctly.
+       Replace gtk-doc checks with a call to GTK_DOC_CHECK() macro.
+       Use AC_CONFIG_COMMANDS([glibconfig.h], ...) to output
+       glibconfig.h, so that "./config.status glibconfig.h" works.
+       Add an extra AC_CONFIG_FILES call listing other files we want
+       generated by config.status protected by an "if false" block.  This
+       way automake generates the rules needed to rebuild the files for
+       us.
+       Add quotes in various places.
+
+       * docs/reference/*/Makefile.am: convert to use the common
+       gtk-doc.make file.  This localises the complexity to a single
+       makefile fragment maintained with gtk-doc itself.
+
+       * */Makefile.am: remove unneeded rules to build win32 files with
+       config.status.  Automake now does this for us.
+       Replace instances of @FOO@ with $(FOO) where appropriate -- this
+       allows automake to do a better job checking the makefile.
+       Add some files to DISTCLEANFILES where appropriate
+
+       * Makefile.am: use the DISTCHECK_CONFIGURE_FLAGS variable to
+       ensure that --enable-gtk-doc is passed to configure during a
+       distcheck.  Remove the custom distcheck, since the standard one
+       will now do.
+
+       * gobject/Makefile.am: switch to BUILT_SOURCES, since that now
+       works.
+
 2003-02-26  Matthias Clasen  <maclas@gmx.de>
 
        * glib/gstrfuncs.c (g_strdup_vprintf): Use g_strndup, not
index c274f1469a2e57396854f786d378fbf4e816a161..b0492434d5352aeb4ba285dffdfc1d8f5a9e7dcc 100644 (file)
@@ -1,3 +1,42 @@
+2003-03-01  James Henstridge  <james@daa.com.au>
+
+       * autogen.sh: require automake 1.7.  Add calls to libtoolize and
+       gtkdocize.  Clean up some of the error messages.
+
+       * configure.in: move version declaration to the top of the file
+       (before AC_INIT), using M4 macros.
+       GLIB_AC_DIVERT_BEFORE_HELP() calls no longer necessary, due to use
+       of M4 macro expansion in help messages instead.
+       Convert AC_ARG_WITH/AC_ARG_ENABLE calls to use AC_HELP_STRING to
+       format help strings.  Use quadrigraphs to get square brackets to
+       show correctly.
+       Replace gtk-doc checks with a call to GTK_DOC_CHECK() macro.
+       Use AC_CONFIG_COMMANDS([glibconfig.h], ...) to output
+       glibconfig.h, so that "./config.status glibconfig.h" works.
+       Add an extra AC_CONFIG_FILES call listing other files we want
+       generated by config.status protected by an "if false" block.  This
+       way automake generates the rules needed to rebuild the files for
+       us.
+       Add quotes in various places.
+
+       * docs/reference/*/Makefile.am: convert to use the common
+       gtk-doc.make file.  This localises the complexity to a single
+       makefile fragment maintained with gtk-doc itself.
+
+       * */Makefile.am: remove unneeded rules to build win32 files with
+       config.status.  Automake now does this for us.
+       Replace instances of @FOO@ with $(FOO) where appropriate -- this
+       allows automake to do a better job checking the makefile.
+       Add some files to DISTCLEANFILES where appropriate
+
+       * Makefile.am: use the DISTCHECK_CONFIGURE_FLAGS variable to
+       ensure that --enable-gtk-doc is passed to configure during a
+       distcheck.  Remove the custom distcheck, since the standard one
+       will now do.
+
+       * gobject/Makefile.am: switch to BUILT_SOURCES, since that now
+       works.
+
 2003-02-26  Matthias Clasen  <maclas@gmx.de>
 
        * glib/gstrfuncs.c (g_strdup_vprintf): Use g_strndup, not
index c274f1469a2e57396854f786d378fbf4e816a161..b0492434d5352aeb4ba285dffdfc1d8f5a9e7dcc 100644 (file)
@@ -1,3 +1,42 @@
+2003-03-01  James Henstridge  <james@daa.com.au>
+
+       * autogen.sh: require automake 1.7.  Add calls to libtoolize and
+       gtkdocize.  Clean up some of the error messages.
+
+       * configure.in: move version declaration to the top of the file
+       (before AC_INIT), using M4 macros.
+       GLIB_AC_DIVERT_BEFORE_HELP() calls no longer necessary, due to use
+       of M4 macro expansion in help messages instead.
+       Convert AC_ARG_WITH/AC_ARG_ENABLE calls to use AC_HELP_STRING to
+       format help strings.  Use quadrigraphs to get square brackets to
+       show correctly.
+       Replace gtk-doc checks with a call to GTK_DOC_CHECK() macro.
+       Use AC_CONFIG_COMMANDS([glibconfig.h], ...) to output
+       glibconfig.h, so that "./config.status glibconfig.h" works.
+       Add an extra AC_CONFIG_FILES call listing other files we want
+       generated by config.status protected by an "if false" block.  This
+       way automake generates the rules needed to rebuild the files for
+       us.
+       Add quotes in various places.
+
+       * docs/reference/*/Makefile.am: convert to use the common
+       gtk-doc.make file.  This localises the complexity to a single
+       makefile fragment maintained with gtk-doc itself.
+
+       * */Makefile.am: remove unneeded rules to build win32 files with
+       config.status.  Automake now does this for us.
+       Replace instances of @FOO@ with $(FOO) where appropriate -- this
+       allows automake to do a better job checking the makefile.
+       Add some files to DISTCLEANFILES where appropriate
+
+       * Makefile.am: use the DISTCHECK_CONFIGURE_FLAGS variable to
+       ensure that --enable-gtk-doc is passed to configure during a
+       distcheck.  Remove the custom distcheck, since the standard one
+       will now do.
+
+       * gobject/Makefile.am: switch to BUILT_SOURCES, since that now
+       works.
+
 2003-02-26  Matthias Clasen  <maclas@gmx.de>
 
        * glib/gstrfuncs.c (g_strdup_vprintf): Use g_strndup, not
index c274f1469a2e57396854f786d378fbf4e816a161..b0492434d5352aeb4ba285dffdfc1d8f5a9e7dcc 100644 (file)
@@ -1,3 +1,42 @@
+2003-03-01  James Henstridge  <james@daa.com.au>
+
+       * autogen.sh: require automake 1.7.  Add calls to libtoolize and
+       gtkdocize.  Clean up some of the error messages.
+
+       * configure.in: move version declaration to the top of the file
+       (before AC_INIT), using M4 macros.
+       GLIB_AC_DIVERT_BEFORE_HELP() calls no longer necessary, due to use
+       of M4 macro expansion in help messages instead.
+       Convert AC_ARG_WITH/AC_ARG_ENABLE calls to use AC_HELP_STRING to
+       format help strings.  Use quadrigraphs to get square brackets to
+       show correctly.
+       Replace gtk-doc checks with a call to GTK_DOC_CHECK() macro.
+       Use AC_CONFIG_COMMANDS([glibconfig.h], ...) to output
+       glibconfig.h, so that "./config.status glibconfig.h" works.
+       Add an extra AC_CONFIG_FILES call listing other files we want
+       generated by config.status protected by an "if false" block.  This
+       way automake generates the rules needed to rebuild the files for
+       us.
+       Add quotes in various places.
+
+       * docs/reference/*/Makefile.am: convert to use the common
+       gtk-doc.make file.  This localises the complexity to a single
+       makefile fragment maintained with gtk-doc itself.
+
+       * */Makefile.am: remove unneeded rules to build win32 files with
+       config.status.  Automake now does this for us.
+       Replace instances of @FOO@ with $(FOO) where appropriate -- this
+       allows automake to do a better job checking the makefile.
+       Add some files to DISTCLEANFILES where appropriate
+
+       * Makefile.am: use the DISTCHECK_CONFIGURE_FLAGS variable to
+       ensure that --enable-gtk-doc is passed to configure during a
+       distcheck.  Remove the custom distcheck, since the standard one
+       will now do.
+
+       * gobject/Makefile.am: switch to BUILT_SOURCES, since that now
+       works.
+
 2003-02-26  Matthias Clasen  <maclas@gmx.de>
 
        * glib/gstrfuncs.c (g_strdup_vprintf): Use g_strndup, not
index 25b1799ae63afd4c827bf2136bc99567d8b9279f..f1b204a97230f5c7f67d50cc6cc00e4de021ecd5 100644 (file)
@@ -1,6 +1,6 @@
 ## Process this file with automake to produce Makefile.in
 
-AUTOMAKE_OPTIONS = 1.4
+AUTOMAKE_OPTIONS = 1.7
 
 SUBDIRS = . m4macros glib gobject gmodule gthread tests build po docs
 
@@ -33,10 +33,13 @@ EXTRA_DIST =                        \
        glib-2.0-uninstalled.pc.in      \
        gobject-2.0-uninstalled.pc.in   \
        gmodule-2.0-uninstalled.pc.in   \
-       gthread-2.0-uninstalled.pc.in
+       gthread-2.0-uninstalled.pc.in   \
+       gtk-doc.make
 
 # These may be in the builddir too
 BUILT_EXTRA_DIST =             \
+       README                  \
+       INSTALL                 \
        glibconfig.h.win32      \
        config.h.win32
 
@@ -50,6 +53,9 @@ install-exec-local: glibconfig.h
        if test -r $$file && cmp -s glibconfig.h $$file; then :; \
        else $(INSTALL_DATA) glibconfig.h $$file; fi
 
+uninstall-local:
+       rm -f $(DESTDIR)$(configexecincludedir)/glibconfig.h
+
 CONFIGURE_DEPENDENCIES = acglib.m4
 
 BUILT_SOURCES = stamp-gc-h #note: not glibconfig.h
@@ -57,23 +63,24 @@ glibconfig.h: stamp-gc-h
        @if test -f glibconfig.h; then :; \
        else rm -f stamp-gc-h; $(MAKE) stamp-gc-h; fi
 stamp-gc-h: config.status
-       CONFIG_FILES= CONFIG_HEADERS= CONFIG_OTHER=glibconfig.h ./config.status
+       cd $(top_builddir) && $(SHELL) ./config.status glibconfig.h
        echo timestamp > stamp-gc-h
 
-
 pkgconfigdir = $(libdir)/pkgconfig
 pkgconfig_DATA = glib-2.0.pc gobject-2.0.pc gmodule-2.0.pc gthread-2.0.pc
 
 $(pkgconfig_DATA): config.status
 
-glibconfig.h.win32: $(top_builddir)/config.status $(top_srcdir)/glibconfig.h.win32.in
-       cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-config.h.win32: $(top_builddir)/config.status $(top_srcdir)/config.h.win32.in
-       cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
+# build documentation when doing distcheck
+DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc
 
 DISTCLEANFILES = glibconfig-sysdefs.h glibconfig.h stamp-gc-h
 
+distclean-local:
+       if test $(srcdir) = .; then :; else \
+           rm -f $(BUILT_EXTRA_DIST); \
+       fi
+
 .PHONY: files release sanity snapshot
 
 files:
@@ -96,32 +103,7 @@ snapcheck:
        $(MAKE) distcheck distdir=$(PACKAGE)-snap`date +"%Y%m%d"`
 
 dist-hook: $(BUILT_EXTRA_DIST)
-       cd $(top_builddir) && CONFIG_FILES="INSTALL README" CONFIG_HEADERS= $(SHELL) ./config.status
-       files='$(BUILT_EXTRA_DIST) INSTALL README'; \
+       files='$(BUILT_EXTRA_DIST)'; \
        for f in $$files; do \
          if test -f $$f; then d=.; else d=$(srcdir); fi; \
          rm -f $(distdir)/$$f && cp $$d/$$f $(distdir) || exit 1; done
-
-# This is a version of the automake-1.4 distcheck rule modified
-# to pass --enable-gtk-doc to ./configure
-#
-mydistcheck: dist
-       -rm -rf $(distdir)
-       GZIP=$(GZIP_ENV) $(TAR) zxf $(distdir).tar.gz
-       mkdir $(distdir)/=build
-       mkdir $(distdir)/=inst
-       dc_install_base=`cd $(distdir)/=inst && pwd`; \
-       cd $(distdir)/=build \
-         && ../configure --srcdir=.. --prefix=$$dc_install_base --enable-gtk-doc \
-         && $(MAKE) $(AM_MAKEFLAGS) \
-         && $(MAKE) $(AM_MAKEFLAGS) dvi \
-         && $(MAKE) $(AM_MAKEFLAGS) check \
-         && $(MAKE) $(AM_MAKEFLAGS) install \
-         && $(MAKE) $(AM_MAKEFLAGS) installcheck \
-         && $(MAKE) $(AM_MAKEFLAGS) dist
-       -rm -rf $(distdir)
-       @banner="$(distdir).tar.gz is ready for distribution"; \
-       dashes=`echo "$$banner" | sed s/./=/g`; \
-       echo "$$dashes"; \
-       echo "$$banner"; \
-       echo "$$dashes"
index 3dcf32c8745039a90c75523b67a0c65a4cc2d8de..f95ab0b4bbd2fcaa00f3059f227d98da7cece979 100755 (executable)
@@ -13,8 +13,8 @@ FILE=glib/glib.h
 DIE=0
 
 have_libtool=false
-if libtool --version < /dev/null > /dev/null 2>&1 ; then
-       libtool_version=`libtoolize --version |  libtoolize --version | sed 's/^[^0-9]*\([0-9.][0-9.]*\).*/\1/'`
+if libtoolize --version < /dev/null > /dev/null 2>&1 ; then
+       libtool_version=`libtoolize --version | sed 's/^[^0-9]*\([0-9.][0-9.]*\).*/\1/'`
        case $libtool_version in
            1.4*)
                have_libtool=true
@@ -25,34 +25,34 @@ if $have_libtool ; then : ; else
        echo
        echo "You must have libtool 1.4 installed to compile $PROJECT."
        echo "Install the appropriate package for your distribution,"
-       echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/"
+       echo "or get the source tarball at http://ftp.gnu.org/gnu/libtool/"
        DIE=1
 fi
 
+(gtkdocize --version) < /dev/null > /dev/null 2>&1 || {
+       echo
+       echo "You must have gtk-doc installed to compile $PROJECT."
+       echo "Install the appropriate package for your distribution,"
+       echo "or get the source tarball at ftp://ftp.gnome.org/pub/GNOME/sources/gtk-doc/"
+       DIE=1
+}
+
 (autoconf --version) < /dev/null > /dev/null 2>&1 || {
        echo
        echo "You must have autoconf installed to compile $PROJECT."
-       echo "libtool the appropriate package for your distribution,"
-       echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/"
+       echo "Install the appropriate package for your distribution,"
+       echo "or get the source tarball at http://ftp.gnu.org/gnu/autoconf/"
        DIE=1
 }
 
-have_automake=false
-if automake-1.4 --version < /dev/null > /dev/null 2>&1 ; then
-       automake_version=`automake-1.4 --version | grep 'automake (GNU automake)' | sed 's/^[^0-9]*\(.*\)/\1/'`
-       case $automake_version in
-          1.2*|1.3*|1.4) 
-               ;;
-          *)
-               have_automake=true
-               ;;
-       esac
-fi
-if $have_automake ; then : ; else
+if automake-1.7 --version < /dev/null > /dev/null 2>&1 ; then
+    AUTOMAKE=automake-1.7
+    ACLOCAL=aclocal-1.7
+else
        echo
-       echo "You must have automake 1.4-p6 installed to compile $PROJECT."
-       echo "Get ftp://ftp.gnu.org/pub/gnu/automake/automake-1.4-p6.tar.gz"
-       echo "(or a newer version if it is available)"
+       echo "You must have automake 1.7.x installed to compile $PROJECT."
+       echo "Install the appropriate package for your distribution,"
+       echo "or get the source tarball at http://ftp.gnu.org/gnu/automake/"
        DIE=1
 fi
 
@@ -72,17 +72,15 @@ if test -z "$AUTOGEN_SUBDIR_MODE"; then
         fi
 fi
 
-case $CC in
-*xlc | *xlc\ * | *lcc | *lcc\ *) am_opt=--include-deps;;
-esac
+$ACLOCAL $ACLOCAL_FLAGS || exit 1
 
-aclocal-1.4 $ACLOCAL_FLAGS
+libtoolize --force || exit 1
+gtkdocize || exit 1
 
-# optionally feature autoheader
-(autoheader --version)  < /dev/null > /dev/null 2>&1 && autoheader
+autoheader || exit 1
 
-automake-1.4 -a $am_opt
-autoconf
+$AUTOMAKE --add-missing || exit 1
+autoconf || exit 1
 cd $ORIGDIR
 
 if test -z "$AUTOGEN_SUBDIR_MODE"; then
@@ -90,4 +88,4 @@ if test -z "$AUTOGEN_SUBDIR_MODE"; then
 
         echo 
         echo "Now type 'make' to compile $PROJECT."
-fi
\ No newline at end of file
+fi
index d2ed1f5b3ac0b95c7469981f0fa9ca3576305414..adaa4b1d2fe0092d7f6207d75da4d9f34614cc0e 100644 (file)
@@ -1,43 +1,74 @@
+# Process this file with autoconf to produce a configure script.
+# require autoconf 2.54
+AC_PREREQ(2.54)
+
 dnl ***********************************
 dnl *** include special GLib macros ***
 dnl ***********************************
 
-define(glib_configure_in)
-builtin(include, acglib.m4)dnl
-builtin(include, glib/libcharset/codeset.m4)dnl
-builtin(include, glib/libcharset/glibc21.m4)dnl
-builtin(include, m4macros/glib-gettext.m4)dnl
-
-# require autoconf 2.53
-AC_PREREQ(2.53)
-
-# Process this file with autoconf to produce a configure script.
-AC_INIT(glib/glib.h)
-
-# Save this value here, since automake will set cflags later
-cflags_set=${CFLAGS+set}
+m4_define(glib_configure_in)
+m4_include(acglib.m4)dnl
+m4_include(glib/libcharset/codeset.m4)dnl
+m4_include(glib/libcharset/glibc21.m4)dnl
+m4_include(m4macros/glib-gettext.m4)dnl
 
-GLIB_AC_DIVERT_BEFORE_HELP([
 #
 # The following version number definitions apply to GLib, GModule, GObject 
 # and GThread as a whole, so if changes occoured in any of them, they are all
 # treated with the same interface and binary age.
 #
 # Making releases:
-#   GLIB_MICRO_VERSION += 1;
-#   GLIB_INTERFACE_AGE += 1;
-#   GLIB_BINARY_AGE += 1;
-# if any functions have been added, set GLIB_INTERFACE_AGE to 0.
+#   glib_micro_version += 1;
+#   glib_interface_age += 1;
+#   glib_binary_age += 1;
+# if any functions have been added, set glib_interface_age to 0.
 # if backwards compatibility has been broken,
-# set GLIB_BINARY_AGE _and_ GLIB_INTERFACE_AGE to 0.
+# set glib_binary_age _and_ glib_interface_age to 0.
 #
-GLIB_MAJOR_VERSION=2
-GLIB_MINOR_VERSION=2
-GLIB_MICRO_VERSION=0
-GLIB_INTERFACE_AGE=0
-GLIB_BINARY_AGE=`expr 100 '*' $GLIB_MINOR_VERSION + $GLIB_MICRO_VERSION`
-GLIB_VERSION=$GLIB_MAJOR_VERSION.$GLIB_MINOR_VERSION.$GLIB_MICRO_VERSION
-])dnl
+m4_define([glib_major_version], [2])
+m4_define([glib_minor_version], [2])
+m4_define([glib_micro_version], [0])
+m4_define([glib_interface_age], [0])
+m4_define([glib_binary_age],
+          [m4_eval(100 * glib_minor_version + glib_micro_version)])
+m4_define([glib_version],
+          [glib_major_version.glib_minor_version.glib_micro_version])
+
+# libtool version related macros
+m4_define([glib_lt_release], [glib_major_version.glib_minor_version])
+m4_define([glib_lt_current],
+          [m4_eval(100 * glib_minor_version + glib_micro_version - glib_interface_age)])
+m4_define([glib_lt_revision], [glib_interface_age])
+m4_define([glib_lt_age], [m4_eval(glib_binary_age - glib_interface_age)])
+m4_define([glib_lt_current_minus_age],
+          [m4_eval(glib_lt_current - glib_lt_age)])
+
+# if the minor version number is odd, then we want debugging.  Otherwise
+# we only want minimal debugging support.
+m4_define([glib_debug_default],
+          [m4_if(m4_eval(glib_minor_version % 2), [1], [yes], [minimum])])dnl
+
+
+AC_INIT(glib, [glib_version],
+        [http://bugzilla.gnome.org/enter_bug.cgi?product=glib])
+
+AC_CONFIG_SRCDIR([glib/glib.h])
+
+# Save this value here, since automake will set cflags later
+cflags_set=${CFLAGS+set}
+
+AM_INIT_AUTOMAKE([no-define])
+
+# Specify a configuration file
+AM_CONFIG_HEADER([config.h])
+
+
+GLIB_MAJOR_VERSION=glib_major_version
+GLIB_MINOR_VERSION=glib_minor_version
+GLIB_MICRO_VERSION=glib_micro_version
+GLIB_INTERFACE_AGE=glib_interface_age
+GLIB_BINARY_AGE=glib_binary_age
+GLIB_VERSION=glib_version
 
 AC_SUBST(GLIB_MAJOR_VERSION)
 AC_SUBST(GLIB_MINOR_VERSION)
@@ -46,43 +77,35 @@ AC_SUBST(GLIB_VERSION)
 AC_SUBST(GLIB_INTERFACE_AGE)
 AC_SUBST(GLIB_BINARY_AGE)
 
+AC_DEFINE(GLIB_MAJOR_VERSION, [glib_major_version],
+         [Define to the GLIB major version])
+AC_DEFINE(GLIB_MINOR_VERSION, [glib_minor_version],
+         [Define to the GLIB minor version])
+AC_DEFINE(GLIB_MICRO_VERSION, [glib_micro_version],
+         [Define to the GLIB micro version])
+AC_DEFINE(GLIB_INTERFACE_AGE, [glib_interface_age],
+         [Define to the GLIB interface age])
+AC_DEFINE(GLIB_BINARY_AGE, [glib_binary_age],
+         [Define to the GLIB binary age])
+
 # libtool versioning
-LT_RELEASE=$GLIB_MAJOR_VERSION.$GLIB_MINOR_VERSION
-LT_CURRENT=`expr 100 '*' $GLIB_MINOR_VERSION + $GLIB_MICRO_VERSION - $GLIB_INTERFACE_AGE`
-LT_REVISION=$GLIB_INTERFACE_AGE
-LT_AGE=`expr $GLIB_BINARY_AGE - $GLIB_INTERFACE_AGE`
-LT_CURRENT_MINUS_AGE=`expr $LT_CURRENT - $LT_AGE`
+LT_RELEASE=glib_lt_release
+LT_CURRENT=glib_lt_current
+LT_REVISION=glib_lt_revision
+LT_AGE=glib_lt_age
+LT_CURRENT_MINUS_AGE=glib_lt_current_minus_age
 AC_SUBST(LT_RELEASE)
 AC_SUBST(LT_CURRENT)
 AC_SUBST(LT_REVISION)
 AC_SUBST(LT_AGE)
 AC_SUBST(LT_CURRENT_MINUS_AGE)
 
-VERSION=$GLIB_VERSION
-PACKAGE=glib
-
-AM_INIT_AUTOMAKE($PACKAGE, $VERSION, no-define)
-
-# Specify a configuration file
-AM_CONFIG_HEADER(config.h)
-
-AC_DEFINE_UNQUOTED(GLIB_MAJOR_VERSION, $GLIB_MAJOR_VERSION,
-                  [Define to the GLIB major version])
-AC_DEFINE_UNQUOTED(GLIB_MINOR_VERSION, $GLIB_MINOR_VERSION,
-                  [Define to the GLIB minor version])
-AC_DEFINE_UNQUOTED(GLIB_MICRO_VERSION, $GLIB_MICRO_VERSION,
-                  [Define to the GLIB micro version])
-AC_DEFINE_UNQUOTED(GLIB_INTERFACE_AGE, $GLIB_INTERFACE_AGE,
-                  [Define to the GLIB interface age])
-AC_DEFINE_UNQUOTED(GLIB_BINARY_AGE, $GLIB_BINARY_AGE,
-                  [Define to the GLIB binary age])
-
 dnl Initialize maintainer mode
 AM_MAINTAINER_MODE
 
 AC_CANONICAL_HOST
 
-AC_MSG_CHECKING(for the BeOS)
+AC_MSG_CHECKING([for the BeOS])
 case $host in
   *-*-beos*)
     glib_native_beos="yes"
@@ -123,7 +146,7 @@ case "$host" in
     ;;
 esac
 AC_MSG_RESULT([$glib_native_win32])
-AM_CONDITIONAL(OS_WIN32, test "$glib_native_win32" = "yes")
+AM_CONDITIONAL(OS_WIN32, [test "$glib_native_win32" = "yes"])
 AC_SUBST(G_LIB_WIN32_RESOURCE)
 AC_SUBST(G_MODULE_WIN32_RESOURCE)
 AC_SUBST(G_OBJECT_WIN32_RESOURCE)
@@ -135,62 +158,72 @@ AC_SUBST(GTHREAD_DEF)
 AC_SUBST(TESTGMODULE_EXP)
 
 if test "$glib_native_win32" = "yes"; then
-  AC_CHECK_PROG(ms_librarian, lib.exe, yes, no)
+  AC_CHECK_PROG(ms_librarian, [lib.exe], [yes], [no])
 fi
-AM_CONDITIONAL(MS_LIB_AVAILABLE, test x$ms_librarian = xyes)
-
-GLIB_AC_DIVERT_BEFORE_HELP([
-# figure debugging default, prior to $ac_help setup
-case $GLIB_MINOR_VERSION in
-*[[13579]]) debug_default=yes ;;
-*)          debug_default=minimum ;;
-esac[]dnl
-])
+AM_CONDITIONAL(MS_LIB_AVAILABLE, [test x$ms_librarian = xyes])
 
 dnl declare --enable-* args and collect ac_help strings
-AC_ARG_ENABLE(debug, [  --enable-debug=[no/minimum/yes] turn on debugging [default=$debug_default]],,enable_debug=$debug_default)
-AC_ARG_ENABLE(gc_friendly, [  --enable-gc-friendly    turn on garbage collector friendliness [default=no]],,enable_gc_friendly=no)
-AC_ARG_ENABLE(mem_pools, [  --disable-mem-pools     disable all glib memory pools],,disable_mem_pools=no)
-AC_ARG_ENABLE(ansi, [  --enable-ansi           turn on strict ansi [default=no]],
-                   , enable_ansi=no)
-AC_ARG_ENABLE(threads, [  --enable-threads        turn on basic thread support [default=yes]
-                          ([=no] will override --with-threads)],,enable_threads=yes)
-AC_ARG_ENABLE(rebuilds, [  --disable-rebuilds      disable all source autogeneration rules],,enable_rebuilds=yes)
+AC_ARG_ENABLE(debug,
+              AC_HELP_STRING([--enable-debug=@<:@no/minimum/yes@:>@],
+                             [turn on debugging @<:@default=glib_debug_default@:>@]),,
+              enable_debug=glib_debug_default)
+
+AC_ARG_ENABLE(gc_friendly,
+              [AC_HELP_STRING([--enable-gc-friendly],
+                              [turn on garbage collector friendliness [default=no]])],,
+              [enable_gc_friendly=no])
+AC_ARG_ENABLE(mem_pools,
+              [AC_HELP_STRING([--disable-mem-pools],
+                             [disable all glib memory pools])],,
+             [disable_mem_pools=no])
+AC_ARG_ENABLE(ansi,
+              [AC_HELP_STRING([--enable-ansi],
+                              [turn on strict ansi [default=no]])],,
+             [enable_ansi=no])
+AC_ARG_ENABLE(threads,
+              [AC_HELP_STRING([--enable-threads],
+                              [turn on basic thread support [default=yes]
+([=no] will override --with-threads)])],,
+              [enable_threads=yes])
+AC_ARG_ENABLE(rebuilds,
+              [AC_HELP_STRING([--disable-rebuilds],
+                              [disable all source autogeneration rules])],,
+              [enable_rebuilds=yes])
 
 if test "x$enable_threads" != "xyes"; then
   enable_threads=no
 fi
 
-AC_DEFINE_UNQUOTED(G_COMPILED_WITH_DEBUGGING, "${enable_debug}",
+AC_DEFINE_UNQUOTED(G_COMPILED_WITH_DEBUGGING, ["${enable_debug}"],
        [Whether glib was compiled with debugging enabled])
 
-AC_MSG_CHECKING(whether to enable garbage collector friendliness)
+AC_MSG_CHECKING([whether to enable garbage collector friendliness])
 if test "x$enable_gc_friendly" = "xyes"; then
   AC_DEFINE(ENABLE_GC_FRIENDLY, 1, [Whether to enable GC friendliness])
   AC_SUBST(ENABLE_GC_FRIENDLY)
-  AC_MSG_RESULT(yes)
+  AC_MSG_RESULT([yes])
 else
-  AC_MSG_RESULT(no)
+  AC_MSG_RESULT([no])
 fi
 
-AC_MSG_CHECKING(whether to disable memory pools)
+AC_MSG_CHECKING([whether to disable memory pools])
 if test "x$disable_mem_pools" = "xno"; then
-  AC_MSG_RESULT(no)
+  AC_MSG_RESULT([no])
 else
-  AC_DEFINE(DISABLE_MEM_POOLS, 1, [Whether to disable memory pools])
+  AC_DEFINE(DISABLE_MEM_POOLS, [1], [Whether to disable memory pools])
   AC_SUBST(DISABLE_MEM_POOLS)
-  AC_MSG_RESULT(yes)
+  AC_MSG_RESULT([yes])
 fi
 
 dnl Checks for programs.
 AC_PROG_CC
 
 dnl Check for a working C++ compiler, but do not bail out, if none is found.
-AC_CHECK_PROGS(CXX, $CCC c++ g++ gcc CC cxx cc++ cl, gcc)
+AC_CHECK_PROGS(CXX, [$CCC c++ g++ gcc CC cxx cc++ cl], [gcc])
 AC_LANG_SAVE
 AC_LANG_CPLUSPLUS
 AC_TRY_COMPILE(,[class a { int b; } c;], ,CXX=)
-AM_CONDITIONAL(HAVE_CXX, test "$CXX" != "")
+AM_CONDITIONAL(HAVE_CXX, [test "$CXX" != ""])
 AC_LANG_RESTORE
 
 AM_PROG_CC_STDC
@@ -201,7 +234,7 @@ AC_SYS_LARGEFILE
 #
 # Find pkg-config
 #
-AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
+AC_PATH_PROG(PKG_CONFIG, [pkg-config], [no])
 if test x$PKG_CONFIG = xno ; then
   AC_MSG_ERROR([*** pkg-config not found. See http://www.freedesktop.org/software/pkgconfig/])
 fi
@@ -270,7 +303,7 @@ AC_EXEEXT
 # define a MAINT-like variable REBUILD which is set if Perl
 # and awk are found, so autogenerated sources can be rebuilt
 AC_PROG_AWK
-AC_CHECK_PROGS(PERL, perl5 perl)
+AC_CHECK_PROGS(PERL, [perl5 perl])
 # We would like indent, but don't require it.
 AC_CHECK_PROG(INDENT, indent, indent)
 REBUILD=\#
@@ -285,7 +318,7 @@ AC_SUBST(REBUILD)
 # Need full path to Perl for glib-mkenums
 #
 if test "x$PERL" != x ; then
-  AC_PATH_PROG(PERL_PATH, $PERL)
+  AC_PATH_PROG(PERL_PATH, [$PERL])
 else
   PERL_PATH="/usr/bin/env perl"
 fi
@@ -297,30 +330,33 @@ dnl ***********************
 dnl
 dnl We do this before the gettext checks, to avoid distortion
 
-AC_ARG_WITH(libiconv, [  --with-libiconv=[no/gnu/native] use the libiconv library ],,with_libiconv=maybe)
+AC_ARG_WITH(libiconv,
+            [AC_HELP_STRING([--with-libiconv=@<:@no/gnu/native@:>@],
+                            [use the libiconv library])],,
+           [with_libiconv=maybe])
 
 found_iconv=no
 case $with_libiconv in
   maybe)
     # Check in the C library first
-    AC_CHECK_FUNC(iconv_open, with_libiconv=no; found_iconv=yes)
+    AC_CHECK_FUNC(iconv_open, [with_libiconv=no; found_iconv=yes])
     # Check if we have GNU libiconv
     if test $found_iconv = "no"; then
-      AC_CHECK_LIB(iconv, libiconv_open, with_libiconv=gnu; found_iconv=yes)
+      AC_CHECK_LIB(iconv, libiconv_open, [with_libiconv=gnu; found_iconv=yes])
     fi
     # Check if we have a iconv in -liconv, possibly from vendor
     if test $found_iconv = "no"; then
-      AC_CHECK_LIB(iconv, iconv_open, with_libiconv=native; found_iconv=yes)
+      AC_CHECK_LIB(iconv, iconv_open, [with_libiconv=native; found_iconv=yes])
     fi
     ;;
   no)
-    AC_CHECK_FUNC(iconv_open, with_libiconv=no; found_iconv=yes)
+    AC_CHECK_FUNC(iconv_open, [with_libiconv=no; found_iconv=yes])
     ;;
   gnu|yes)
-    AC_CHECK_LIB(iconv, libiconv_open, with_libiconv=gnu; found_iconv=yes)
+    AC_CHECK_LIB(iconv, libiconv_open, [with_libiconv=gnu; found_iconv=yes])
     ;;
   native)
-    AC_CHECK_LIB(iconv, iconv_open, with_libiconv=native; found_iconv=yes)
+    AC_CHECK_LIB(iconv, iconv_open, [with_libiconv=native; found_iconv=yes])
     ;;
 esac
 
@@ -346,7 +382,7 @@ LIBS="$INTLLIBS $LIBS"
 
 GETTEXT_PACKAGE=glib20
 AC_SUBST(GETTEXT_PACKAGE)
-AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE"
+AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, ["$GETTEXT_PACKAGE"]
   [Define the gettext package to be used])
 
 GLIB_DEFINE_LOCALEDIR(GLIB_LOCALE_DIR)
@@ -700,7 +736,10 @@ AC_FUNC_PRINTF_UNIX98
 # Check whether to use trio printf
 #
 
-AC_ARG_ENABLE(included-printf, [  --enable-included-printf    use included printf [default=auto]], enable_trio="$enableval")
+AC_ARG_ENABLE(included-printf,
+              [AC_HELP_STRING([--enable-included-printf],
+                              [use included printf [default=auto]])],
+              enable_trio="$enableval")
 
 need_trio=no
 if test "x$enable_trio" = "xyes" ; then
@@ -1175,13 +1214,15 @@ dnl ***********************
 dnl *** g_thread checks ***
 dnl ***********************
 
-AC_ARG_WITH(threads, [  --with-threads=[none/posix/dce/solaris/win32] specify a thread implementation to use],
-       if test "x$with_threads" = x; then
+AC_ARG_WITH(threads,
+           [AC_HELP_STRING([--with-threads=@<:@none/posix/dce/solaris/win32@:>@],
+                           [specify a thread implementation to use])],
+           [if test "x$with_threads" = x; then
                want_threads=yes
-       else
+           else
                want_threads=$with_threads
-       fi,
-       want_threads=yes)
+           fi],
+          [want_threads=yes])
 if test "x$enable_threads" = "xno"; then
         want_threads=no
 fi
@@ -1847,87 +1888,16 @@ dnl **************************
 dnl *** Checks for gtk-doc ***
 dnl **************************
 
-AC_ARG_WITH(html-dir, [  --with-html-dir=PATH    path to installed docs])
-
-if test "x$with_html_dir" = "x" ; then
-  HTML_DIR='${datadir}/gtk-doc/html'
-else
-  HTML_DIR=$with_html_dir
-fi
-
-AC_SUBST(HTML_DIR)
-
-AC_CHECK_PROG(GTKDOC, gtkdoc-mkdb, true, false)
-
-AC_CHECK_PROG(GTKDOC, gtkdoc-mkdb, true, false)
-
-gtk_doc_min_version=0.10
-if $GTKDOC ; then
-    gtk_doc_version=`gtkdoc-mkdb --version`
-    AC_MSG_CHECKING([gtk-doc version ($gtk_doc_version) >= $gtk_doc_min_version])
-
-    IFS="${IFS=        }"; gtk_save_IFS="$IFS"; IFS="."
-    set $gtk_doc_version
-    for min in $gtk_doc_min_version ; do
-        cur=$1; shift
-        if test -z $min ; then break; fi
-        if test -z $cur ; then GTKDOC=false; break; fi
-        if test $cur -gt $min ; then break ; fi
-        if test $cur -lt $min ; then GTKDOC=false; break ; fi
-    done
-    IFS="$gtk_save_IFS"
-
-    if $GTKDOC ; then
-      AC_MSG_RESULT(yes)
-    else
-      AC_MSG_RESULT(no)
-    fi
-fi
-
-AM_CONDITIONAL(HAVE_GTK_DOC, $GTKDOC)
-AC_SUBST(HAVE_GTK_DOC)
-
-AC_CHECK_PROG(DB2HTML, db2html, true, false)
-AM_CONDITIONAL(HAVE_DOCBOOK, $DB2HTML)
-
-dnl Let people disable the gtk-doc stuff.
-AC_ARG_ENABLE(gtk-doc, [  --enable-gtk-doc        use gtk-doc to build documentation [default=auto]], enable_gtk_doc="$enableval", enable_gtk_doc=no)
-
-if test x$enable_gtk_doc = xyes ; then
-  if test x$GTKDOC = xtrue ; then
-    enable_gtk_doc=yes
-  else
-    enable_gtk_doc=no 
-  fi
-fi
-
-dnl NOTE: We need to use a separate automake conditional for this
-dnl       to make this work with the tarballs.
-AM_CONDITIONAL(ENABLE_GTK_DOC, test x$enable_gtk_doc = xyes)
+GTK_DOC_CHECK([1.0])
 
 dnl ******************************
 dnl *** output the whole stuff ***
 dnl ******************************
 
-AC_OUTPUT_COMMANDS([
-
-## Generate `glibconfig.h' in two cases
-## 1. `config.status' is run either explicitly, or via configure.
-##     Esp. not when it is run in `Makefile' to generate makefiles and
-##     config.h
-## 2. CONFIG_OTHER is set explicitly
-##
-## Case 1 is difficult.  We know that `automake' sets one of
-## CONFIG_FILES or CONFIG_HEADERS to empty.  This heuristic works
-## only when AM_CONFIG_HEADER is set, however.
-
-if test -n "${CONFIG_FILES}" && test -n "${CONFIG_HEADERS}"; then
-  # Both CONFIG_FILES and CONFIG_HEADERS are non-empty ==> Case 1
-  CONFIG_OTHER=${CONFIG_OTHER:-glibconfig.h}
-fi
-case "$CONFIG_OTHER" in
-*glibconfig.h*)
-       echo creating glibconfig.h
+dnl this section will only be run if config.status is invoked with no
+dnl arguments, or with "glibconfig.h" as an argument.
+AC_CONFIG_COMMANDS([glibconfig.h],
+[
        outfile=glibconfig.h-tmp
        cat > $outfile <<\_______EOF
 /* glibconfig.h
@@ -2131,7 +2101,7 @@ struct _GStaticMutex
 {
   struct _GMutex *runtime_mutex;
   union {
-    char   pad[$g_mutex_sizeof];
+    char   pad[[$g_mutex_sizeof]];
     double dummy_double;
     void  *dummy_pointer;
     long   dummy_long;
@@ -2160,7 +2130,7 @@ _______EOF
 typedef union _GSystemThread GSystemThread;
 union _GSystemThread
 {
-  char   data[$g_system_thread_sizeof];
+  char   data[[$g_system_thread_sizeof]];
   double dummy_double;
   void  *dummy_pointer;
   long   dummy_long;
@@ -2205,12 +2175,11 @@ _______EOF
 
 
        if cmp -s $outfile glibconfig.h; then
-         echo glibconfig.h is unchanged
+         AC_MSG_NOTICE([glibconfig.h is unchanged])
          rm -f $outfile
        else
          mv $outfile glibconfig.h
-       fi ;;
-esac
+       fi
 ],[
 
 # Note that if two cases are the same, case goes with the first one.
@@ -2458,7 +2427,7 @@ case $host in
 esac
 ])
 
-AC_OUTPUT([
+AC_CONFIG_FILES([
 glib-2.0.pc
 glib-2.0-uninstalled.pc
 gmodule-2.0.pc
@@ -2476,8 +2445,8 @@ build/win32/dirent/Makefile
 glib/Makefile
 glib/libcharset/Makefile
 glib/trio/Makefile
-gmodule/gmoduleconf.h
 gmodule/Makefile
+gmodule/gmoduleconf.h
 gobject/Makefile
 gobject/glib-mkenums
 gthread/Makefile
@@ -2490,8 +2459,37 @@ docs/reference/gobject/Makefile
 docs/reference/gobject/version.xml
 tests/Makefile
 m4macros/Makefile
-],[
-chmod 0755 glib-zip
-chmod 0755 glib-gettextize
-chmod 0755 gobject/glib-mkenums
 ])
+
+AC_CONFIG_COMMANDS([chmod-scripts],
+[chmod 0755 glib-zip
+chmod 0755 glib-gettextize
+chmod 0755 gobject/glib-mkenums])
+
+# we want to invoke this macro solely so that the config.status script
+# and automake generated makefiles know about these generated files.
+# They are only needed to distcheck the package
+if false; then
+  AC_CONFIG_FILES([
+    INSTALL
+    README
+    config.h.win32
+    glibconfig.h.win32
+    glib/makefile.mingw
+    glib/makefile.msc
+    glib/glib.rc
+    gmodule/makefile.mingw
+    gmodule/makefile.msc
+    gmodule/gmodule.rc
+    gobject/makefile.mingw
+    gobject/makefile.msc
+    gobject/gobject.rc
+    gthread/makefile.mingw
+    gthread/makefile.msc
+    gthread/gthread.rc
+    tests/makefile.mingw
+    tests/makefile.msc
+  ])
+fi
+
+AC_OUTPUT
index 23f5b86eb432d684105e95a161496638da40bdbe..5959840e437d211e4d1b4060f855b3043a8c0f4d 100644 (file)
@@ -1,4 +1,5 @@
 ## Process this file with automake to produce Makefile.in
+AUTOMAKE_OPTIONS = 1.6
 
 # The name of the module.
 DOC_MODULE=glib
@@ -6,17 +7,11 @@ DOC_MODULE=glib
 # The top-level SGML file.
 DOC_MAIN_SGML_FILE=glib-docs.sgml
 
-# The directory containing the source code. Relative to $(srcdir)
-DOC_SOURCE_DIR=../../..
-
 # Extra options to supply to gtkdoc-scan
 SCAN_OPTIONS=--deprecated-guards="G_DISABLE_DEPRECATED"
 
-# Extra options to supply to gtkdoc-mkdb
-MKDB_OPTIONS=--sgml-mode --output-format=xml --ignore-files=trio
-
-# Extra options to supply to gtkdoc-fixref
-FIXXREF_OPTIONS=
+# The directory containing the source code. Relative to $(srcdir)
+DOC_SOURCE_DIR=../../..
 
 # Used for dependencies
 HFILE_GLOB=$(top_srcdir)/glib/*.h $(top_srcdir)/gmodule/*.h
@@ -39,8 +34,8 @@ IGNORE_HFILES=                        \
        gprintfint.h            \
        trio
 
-# Extra files to add when scanning
-EXTRA_HFILES=
+# Extra options to supply to gtkdoc-mkdb
+MKDB_OPTIONS=--sgml-mode --output-format=xml --ignore-files=trio
 
 # Images to copy into HTML directory
 HTML_IMAGES =                                  \
@@ -55,153 +50,15 @@ content_files =                            \
        resources.sgml                  \
        version.xml
 
+# Extra options to supply to gtkdoc-fixref
+FIXXREF_OPTIONS=
+
+# include common portion ...
+include $(top_srcdir)/gtk-doc.make
 
 # Other files to distribute
-extra_files =                          \
+EXTRA_DIST +=                          \
        mainloop-states.fig             \
        mainloop-states.png             \
        mainloop-states.eps             \
        version.xml.in
-
-# CFLAGS and LDFLAGS for compiling scan program. Only needed
-# if $(DOC_MODULE).types is non-empty.
-GTKDOC_CFLAGS =
-GTKDOC_LIBS =
-
-# Commands for compiling and linking 
-GTKDOC_CC=$(LIBTOOL) --mode=compile $(CC)
-GTKDOC_LD=$(LIBTOOL) --mode=link $(CC)
-
-
-####################################
-# Everything below here is generic #
-####################################
-
-# We set GPATH here; this gives us semantics for GNU make
-# which are more like other make's VPATH, when it comes to
-# whether a source that is a target of one rule is then
-# searched for in VPATH/GPATH.
-#
-GPATH = $(srcdir)
-
-TARGET_DIR=$(HTML_DIR)/$(DOC_MODULE)
-
-EXTRA_DIST =                           \
-       $(content_files)                \
-       $(extra_files)                  \
-       $(HTML_IMAGES)                  \
-       $(DOC_MAIN_SGML_FILE)           \
-       $(DOC_MODULE).types             \
-       $(DOC_MODULE)-sections.txt      \
-       $(DOC_MODULE)-overrides.txt
-
-DOC_STAMPS=scan-build.stamp tmpl-build.stamp sgml-build.stamp html-build.stamp \
-          $(srcdir)/tmpl.stamp $(srcdir)/sgml.stamp $(srcdir)/html.stamp
-
-SCANOBJ_FILES =                 \
-       $(DOC_MODULE).args       \
-       $(DOC_MODULE).hierarchy  \
-       $(DOC_MODULE).interfaces \
-       $(DOC_MODULE).prerequisites \
-       $(DOC_MODULE).signals
-
-if ENABLE_GTK_DOC
-all-local: html-build.stamp
-
-#### scan ####
-
-scan-build.stamp: $(HFILE_GLOB)
-       @echo '*** Scanning header files ***'
-       if grep -l '^..*$$' $(srcdir)/$(DOC_MODULE).types > /dev/null ; then \
-           CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" CFLAGS="$(GTKDOC_CFLAGS)" LDFLAGS="$(GTKDOC_LIBS)" gtkdoc-scangobj --module=$(DOC_MODULE) --output-dir=$(srcdir) ; \
-       else \
-           cd $(srcdir) ; \
-           for i in $(SCANOBJ_FILES) ; do \
-               test -f $$i || touch $$i ; \
-           done \
-       fi
-       cd $(srcdir) && \
-         gtkdoc-scan --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR) --ignore-headers="$(IGNORE_HFILES)" $(SCAN_OPTIONS) $(EXTRA_HFILES)
-       touch scan-build.stamp
-
-$(DOC_MODULE)-decl.txt $(SCANOBJ_FILES): scan-build.stamp
-       @true
-
-#### templates ####
-
-tmpl-build.stamp: $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt
-       @echo '*** Rebuilding template files ***'
-       cd $(srcdir) && gtkdoc-mktmpl --module=$(DOC_MODULE)
-       touch tmpl-build.stamp
-
-tmpl.stamp: tmpl-build.stamp
-       @true
-
-#### sgml ####
-
-sgml-build.stamp: tmpl.stamp $(CFILE_GLOB) $(srcdir)/tmpl/*.sgml
-       @echo '*** Building SGML ***'
-       cd $(srcdir) && \
-       gtkdoc-mkdb --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR) $(MKDB_OPTIONS)
-       touch sgml-build.stamp
-
-sgml.stamp: sgml-build.stamp
-       @true
-
-#### html ####
-
-html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
-       @echo '*** Building HTML ***'
-       rm -rf $(srcdir)/html 
-       mkdir $(srcdir)/html
-       cd $(srcdir)/html && gtkdoc-mkhtml $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)
-       test "x$(HTML_IMAGES)" = "x" || ( cd $(srcdir) && cp $(HTML_IMAGES) html )
-       @echo '-- Fixing Crossreferences' 
-       cd $(srcdir) && gtkdoc-fixxref --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
-       touch html-build.stamp
-endif
-
-##############
-
-clean-local:
-       rm -f *~ *.bak $(SCANOBJ_FILES) *-unused.txt $(DOC_STAMPS)
-
-maintainer-clean-local: clean
-       cd $(srcdir) && rm -rf sgml html $(DOC_MODULE)-decl-list.txt $(DOC_MODULE)-decl.txt
-
-install-data-local:
-       $(mkinstalldirs) $(DESTDIR)$(TARGET_DIR)
-       (installfiles=`echo $(srcdir)/html/*`; \
-       if test "$$installfiles" = '$(srcdir)/html/*'; \
-       then echo '-- Nothing to install' ; \
-       else \
-         for i in $$installfiles; do \
-           echo '-- Installing '$$i ; \
-           $(INSTALL_DATA) $$i $(DESTDIR)$(TARGET_DIR); \
-         done; \
-         echo '-- Installing $(srcdir)/html/index.sgml' ; \
-         $(INSTALL_DATA) $(srcdir)/html/index.sgml $(DESTDIR)$(TARGET_DIR); \
-       fi)
-
-#
-# Require gtk-doc when making dist
-#
-if ENABLE_GTK_DOC
-dist-check-gtkdoc:
-else
-dist-check-gtkdoc:
-       @echo "*** gtk-doc must be installed and enabled in order to make dist"
-       @false
-endif
-
-dist-hook: dist-check-gtkdoc dist-hook-local
-       mkdir $(distdir)/tmpl
-       mkdir $(distdir)/xml
-       mkdir $(distdir)/html
-       -cp $(srcdir)/tmpl/*.sgml $(distdir)/tmpl
-       -cp $(srcdir)/sgml/*.xml $(distdir)/xml
-       -cp $(srcdir)/html/* $(distdir)/html
-
-.PHONY : dist-hook-local
-
-
index 0792ae517c18ede4f065bb084948b7cbb8627f43..b756b19e139824748be8e526f4a0862a73c9ad01 100644 (file)
@@ -6,174 +6,34 @@ DOC_MODULE=gobject
 # The top-level SGML file.
 DOC_MAIN_SGML_FILE=gobject-docs.sgml
 
-# The directory containing the source code. Relative to $(srcdir)
-DOC_SOURCE_DIR=../../../gobject
-
 # Extra options to supply to gtkdoc-scan
 SCAN_OPTIONS=
 
-# Extra options to supply to gtkdoc-mkdb
-MKDB_OPTIONS=--output-format=xml
-
-# Extra options to supply to gtkdoc-fixref
-FIXXREF_OPTIONS=--extra-dir=$(srcdir)/../glib/html
+# The directory containing the source code. Relative to $(srcdir)
+DOC_SOURCE_DIR=../../../gobject
 
-# Used for dependencies
 HFILE_GLOB=$(top_srcdir)/gobject/*.h
 CFILE_GLOB=$(top_srcdir)/gobject/*.c
 
-# Headers to ignore
-IGNORE_HFILES=
-
-# Extra files to add when scanning
-EXTRA_HFILES=
-
-# Images to copy into HTML directory
-HTML_IMAGES =
-
-# Extra SGML files that are included by $(DOC_MAIN_SGML_FILE)
-content_files = version.xml
-
-# Other files to distribute
-extra_files = version.xml.in
-
 # CFLAGS and LDFLAGS for compiling scan program. Only needed
 # if $(DOC_MODULE).types is non-empty.
-GTKDOC_CFLAGS =
+INCLUDES =
 GTKDOC_LIBS =
 
-# Commands for compiling and linking 
-GTKDOC_CC=$(LIBTOOL) --mode=compile $(CC)
-GTKDOC_LD=$(LIBTOOL) --mode=link $(CC)
-
-
-####################################
-# Everything below here is generic #
-####################################
-
-# We set GPATH here; this gives us semantics for GNU make
-# which are more like other make's VPATH, when it comes to
-# whether a source that is a target of one rule is then
-# searched for in VPATH/GPATH.
-#
-GPATH = $(srcdir)
-
-TARGET_DIR=$(HTML_DIR)/$(DOC_MODULE)
-
-EXTRA_DIST =                           \
-       $(content_files)                \
-       $(extra_files)                  \
-       $(HTML_IMAGES)                  \
-       $(DOC_MAIN_SGML_FILE)           \
-       $(DOC_MODULE).types             \
-       $(DOC_MODULE)-sections.txt      \
-       $(DOC_MODULE)-overrides.txt
 
-DOC_STAMPS=scan-build.stamp tmpl-build.stamp sgml-build.stamp html-build.stamp \
-          $(srcdir)/tmpl.stamp $(srcdir)/sgml.stamp $(srcdir)/html.stamp
-
-SCANOBJ_FILES =                 \
-       $(DOC_MODULE).args       \
-       $(DOC_MODULE).hierarchy  \
-       $(DOC_MODULE).interfaces \
-       $(DOC_MODULE).prerequisites \
-       $(DOC_MODULE).signals
-
-if ENABLE_GTK_DOC
-all-local: html-build.stamp
-
-#### scan ####
-
-scan-build.stamp: $(HFILE_GLOB)
-       @echo '*** Scanning header files ***'
-       if grep -l '^..*$$' $(srcdir)/$(DOC_MODULE).types > /dev/null ; then \
-           CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" CFLAGS="$(GTKDOC_CFLAGS)" LDFLAGS="$(GTKDOC_LIBS)" gtkdoc-scangobj --module=$(DOC_MODULE) --output-dir=$(srcdir) ; \
-       else \
-           cd $(srcdir) ; \
-           for i in $(SCANOBJ_FILES) ; do \
-               test -f $$i || touch $$i ; \
-           done \
-       fi
-       cd $(srcdir) && \
-         gtkdoc-scan --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR) --ignore-headers="$(IGNORE_HFILES)" $(SCAN_OPTIONS) $(EXTRA_HFILES)
-       touch scan-build.stamp
-
-$(DOC_MODULE)-decl.txt $(SCANOBJ_FILES): scan-build.stamp
-       @true
-
-#### templates ####
-
-tmpl-build.stamp: $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt
-       @echo '*** Rebuilding template files ***'
-       cd $(srcdir) && gtkdoc-mktmpl --module=$(DOC_MODULE)
-       touch tmpl-build.stamp
-
-tmpl.stamp: tmpl-build.stamp
-       @true
-
-#### sgml ####
-
-sgml-build.stamp: tmpl.stamp $(CFILE_GLOB) $(srcdir)/tmpl/*.sgml
-       @echo '*** Building SGML ***'
-       cd $(srcdir) && \
-       gtkdoc-mkdb --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR) $(MKDB_OPTIONS)
-       touch sgml-build.stamp
-
-sgml.stamp: sgml-build.stamp
-       @true
-
-#### html ####
-
-html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
-       @echo '*** Building HTML ***'
-       rm -rf $(srcdir)/html 
-       mkdir $(srcdir)/html
-       cd $(srcdir)/html && gtkdoc-mkhtml $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)
-       test "x$(HTML_IMAGES)" = "x" || ( cd $(srcdir) && cp $(HTML_IMAGES) html )
-       @echo '-- Fixing Crossreferences' 
-       cd $(srcdir) && gtkdoc-fixxref --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
-       touch html-build.stamp
-endif
-
-##############
-
-clean-local:
-       rm -f *~ *.bak $(SCANOBJ_FILES) *-unused.txt $(DOC_STAMPS)
+# Extra options to supply to gtkdoc-mkdb
+MKDB_OPTIONS=
 
-maintainer-clean-local: clean
-       cd $(srcdir) && rm -rf sgml html $(DOC_MODULE)-decl-list.txt $(DOC_MODULE)-decl.txt
+# Images to copy into HTML directory
+HTML_IMAGES =
 
-install-data-local:
-       $(mkinstalldirs) $(DESTDIR)$(TARGET_DIR)
-       (installfiles=`echo $(srcdir)/html/*`; \
-       if test "$$installfiles" = '$(srcdir)/html/*'; \
-       then echo '-- Nothing to install' ; \
-       else \
-         for i in $$installfiles; do \
-           echo '-- Installing '$$i ; \
-           $(INSTALL_DATA) $$i $(DESTDIR)$(TARGET_DIR); \
-         done; \
-         echo '-- Installing $(srcdir)/html/index.sgml' ; \
-         $(INSTALL_DATA) $(srcdir)/html/index.sgml $(DESTDIR)$(TARGET_DIR); \
-       fi)
+# Extra SGML files that are included by $(DOC_MAIN_SGML_FILE)
+content_files = version.xml
 
-#
-# Require gtk-doc when making dist
-#
-if ENABLE_GTK_DOC
-dist-check-gtkdoc:
-else
-dist-check-gtkdoc:
-       @echo "*** gtk-doc must be installed and enabled in order to make dist"
-       @false
-endif
+# Extra options to supply to gtkdoc-fixref
+FIXXREF_OPTIONS=--extra-dir=$(srcdir)/../glib/html
 
-dist-hook: dist-check-gtkdoc dist-hook-local
-       mkdir $(distdir)/tmpl
-       mkdir $(distdir)/xml
-       mkdir $(distdir)/html
-       -cp $(srcdir)/tmpl/*.sgml $(distdir)/tmpl
-       -cp $(srcdir)/xml/*.xml $(distdir)/xml
-       -cp $(srcdir)/html/* $(distdir)/html
+include $(top_srcdir)/gtk-doc.make
 
-.PHONY : dist-hook-local
+# Other files to distribute
+EXTRA_DIST += version.xml.in
index 559b70ba2c9c99523f6bcf384e714d75285679fc..0462374c5c234e71ac08964af9ead3ee21158cda 100644 (file)
@@ -11,7 +11,7 @@ SUBDIRS = libcharset $(TRIO_SUBDIR)
 DIST_SUBDIRS = libcharset trio
 
 INCLUDES = -I$(top_srcdir) -DG_LOG_DOMAIN=\"GLib\" \
-       @GLIB_DEBUG_FLAGS@ -DG_DISABLE_DEPRECATED -DGLIB_COMPILATION 
+       $(GLIB_DEBUG_FLAGS) -DG_DISABLE_DEPRECATED -DGLIB_COMPILATION 
 
 EXTRA_DIST =                   \
        makefile.mingw.in       \
@@ -182,8 +182,8 @@ install-libtool-import-lib:
 uninstall-libtool-import-lib:
 endif
 
-libglib_2_0_la_LIBADD = libcharset/libcharset.la $(trio_libtrio_la) @GIO@ @GSPAWN@ @PLATFORMDEP@ @G_LIB_WIN32_RESOURCE@ @ICONV_LIBS@ @G_LIBS_EXTRA@ 
-libglib_2_0_la_DEPENDENCIES = libcharset/libcharset.la $(trio_libtrio_la) @GIO@ @GSPAWN@ @PLATFORMDEP@ @G_LIB_WIN32_RESOURCE@ @GLIB_DEF@
+libglib_2_0_la_LIBADD = libcharset/libcharset.la $(trio_libtrio_la) $(GIO) $(GSPAWN) $(PLATFORMDEP) $(G_LIB_WIN32_RESOURCE) $(ICONV_LIBS) $(G_LIBS_EXTRA)
+libglib_2_0_la_DEPENDENCIES = libcharset/libcharset.la $(trio_libtrio_la) $(GIO) $(GSPAWN) $(PLATFORMDEP) $(G_LIB_WIN32_RESOURCE) $(GLIB_DEF)
 
 libglib_2_0_la_LDFLAGS = \
        -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
@@ -194,21 +194,12 @@ bin_PROGRAMS = gspawn-win32-helper
 gspawn_win32_helper_LDADD = libglib-2.0.la
 gspawn_win32_helper_LDFLAGS = -mwindows
 
-@G_LIB_WIN32_RESOURCE@ : glib.rc
-       $(top_srcdir)/build/win32/lt-compile-resource glib.rc @G_LIB_WIN32_RESOURCE@
+$(G_LIB_WIN32_RESOURCE): glib.rc
+       $(top_srcdir)/build/win32/lt-compile-resource glib.rc $@
 endif
 
 glib-2.0.lib: libglib-2.0.la glib.def
-       lib -name:libglib-2.0-@LT_CURRENT_MINUS_AGE@.dll -def:glib.def -out:$@
-
-glib.rc: $(top_builddir)/config.status $(top_srcdir)/glib/glib.rc.in
-       cd $(top_builddir) && CONFIG_FILES=glib/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-makefile.mingw: $(top_builddir)/config.status $(top_srcdir)/glib/makefile.mingw.in
-       cd $(top_builddir) && CONFIG_FILES=glib/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-makefile.msc: $(top_builddir)/config.status $(top_srcdir)/glib/makefile.msc.in
-       cd $(top_builddir) && CONFIG_FILES=glib/$@ CONFIG_HEADERS= $(SHELL) ./config.status
+       lib -name:libglib-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:glib.def -out:$@
 
 dist-hook: $(BUILT_EXTRA_DIST)
        files='$(BUILT_EXTRA_DIST)'; \
index 2007f70fd85613ecf8a31c4f3bbb67efe9faeb6c..ad70c70edcd7c942dfcc86da05d8b08ecb8331fa 100644 (file)
@@ -68,30 +68,21 @@ endif
 
 libgmodule_2_0_la_SOURCES = gmodule.c
 libgmodule_2_0_la_LDFLAGS = \
-       @G_MODULE_LDFLAGS@ \
+       $(G_MODULE_LDFLAGS) \
        -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
        -export-dynamic $(no_undefined) $(export_symbols)
 
-libgmodule_2_0_la_LIBADD = @G_MODULE_WIN32_RESOURCE@ @G_MODULE_LIBS_EXTRA@ @G_MODULE_LIBS@ $(libglib)
+libgmodule_2_0_la_LIBADD = $(G_MODULE_WIN32_RESOURCE) $(G_MODULE_LIBS_EXTRA) $(G_MODULE_LIBS) $(libglib)
 
-libgmodule_2_0_la_DEPENDENCIES = @G_MODULE_WIN32_RESOURCE@ @GMODULE_DEF@
+libgmodule_2_0_la_DEPENDENCIES = $(G_MODULE_WIN32_RESOURCE) $(GMODULE_DEF)
 
 if OS_WIN32
-@G_MODULE_WIN32_RESOURCE@ : gmodule.rc
-       $(top_srcdir)/build/win32/lt-compile-resource gmodule.rc @G_MODULE_WIN32_RESOURCE@
+$(G_MODULE_WIN32_RESOURCE): gmodule.rc
+       $(top_srcdir)/build/win32/lt-compile-resource gmodule.rc $@
 endif
 
 gmodule-2.0.lib: libgmodule-2.0.la gmodule.def
-       lib -name:libgmodule-2.0-@LT_CURRENT_MINUS_AGE@.dll -def:gmodule.def -out:$@
-
-gmodule.rc: $(top_builddir)/config.status $(top_srcdir)/gmodule/gmodule.rc.in
-       cd $(top_builddir) && CONFIG_FILES=gmodule/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-makefile.mingw: $(top_builddir)/config.status $(top_srcdir)/gmodule/makefile.mingw.in
-       cd $(top_builddir) && CONFIG_FILES=gmodule/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-makefile.msc: $(top_builddir)/config.status $(top_srcdir)/gmodule/makefile.msc.in
-       cd $(top_builddir) && CONFIG_FILES=gmodule/$@ CONFIG_HEADERS= $(SHELL) ./config.status
+       lib -name:libgmodule-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:gmodule.def -out:$@
 
 .PHONY: files release
 
index 651c0c1706979eabdab3e4fc292664cad9b35bbf..2489052c9c364494dbe4415bd2e52869bb1d5fa8 100644 (file)
@@ -3,16 +3,15 @@
 #
 ## Process this file with automake to produce Makefile.in
 
-INCLUDES = @STRIP_BEGIN@ \
+INCLUDES = \
        -DG_LOG_DOMAIN=\"GLib-GObject\"         \
        -I$(top_srcdir)                         \
        -I$(top_srcdir)/glib                    \
        -I$(top_builddir)                       \
-       @GLIB_DEBUG_FLAGS@                      \
+       $(GLIB_DEBUG_FLAGS)                     \
        -DG_DISABLE_DEPRECATED                  \
        -DGOBJECT_COMPILATION                   \
-       -DG_DISABLE_CONST_RETURNS               \
-@STRIP_END@
+       -DG_DISABLE_CONST_RETURNS
 
 libglib = $(top_builddir)/glib/libglib-2.0.la
 
@@ -52,20 +51,19 @@ endif
 
 # libtool stuff: set version and export symbols for resolving
 libgobjectincludedir = $(includedir)/glib-2.0/gobject
-libgobject_2_0_la_LDFLAGS = @STRIP_BEGIN@ \
-       -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE)    \
-       -export-dynamic $(no_undefined) $(export_symbols)       \
-@STRIP_END@
+libgobject_2_0_la_LDFLAGS = \
+  -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
+  -export-dynamic $(no_undefined) $(export_symbols)
 
-libgobject_2_0_la_LIBADD = @G_OBJECT_WIN32_RESOURCE@ $(libglib)
+libgobject_2_0_la_LIBADD = $(G_OBJECT_WIN32_RESOURCE) $(libglib)
 
-libgobject_2_0_la_DEPENDENCIES = @G_OBJECT_WIN32_RESOURCE@ @GOBJECT_DEF@
+libgobject_2_0_la_DEPENDENCIES = $(G_OBJECT_WIN32_RESOURCE) $(GOBJECT_DEF)
 
 #
 # setup source file variables
 #
-# GObject library header files for public installation (non-generated)
-gobject_public_h_sources = @STRIP_BEGIN@ \
+# GObject library header files for public installation
+gobject_public_h_sources = \
        gboxed.h                \
        gclosure.h              \
        genums.h                \
@@ -82,12 +80,12 @@ gobject_public_h_sources = @STRIP_BEGIN@ \
        gvaluecollector.h       \
        gvaluetypes.h           \
        gobjectnotifyqueue.c    \
-@STRIP_END@
+       gmarshal.h
+
 # GObject library header files that don't get installed
-gobject_private_h_sources = @STRIP_BEGIN@ \
-@STRIP_END@
+gobject_private_h_sources = 
 # GObject library C sources to build the library from
-gobject_c_sources = @STRIP_BEGIN@ \
+gobject_c_sources = \
        gboxed.c                \
        gclosure.c              \
        genums.c                \
@@ -102,55 +100,33 @@ gobject_c_sources = @STRIP_BEGIN@ \
        gvalue.c                \
        gvaluearray.c           \
        gvaluetransform.c       \
-       gvaluetypes.c           \
-@STRIP_END@
-
-# we use our own built_sources variable rules to avoid automake's
-# BUILT_SOURCES oddities
-# we generate frequently rebuild files piggyback on a stamp file, so sources
-# depending on them only get rebuild when the built source actually changed
-# content
-
-# built sources that get installed with the header files
-gobject_built_public_sources = @STRIP_BEGIN@ \
-       gmarshal.h      \
-@STRIP_END@
-# built sources that don't get installed
-gobject_built_sources = @STRIP_BEGIN@ \
-       stamp-gmarshal.h                 \
-       gmarshal.c                       \
-       ${gobject_built_public_sources} \
-@STRIP_END@
+       gvaluetypes.c
+
+# these sources (also mentioned above) are generated.
+BUILT_SOURCES = gmarshal.h gmarshal.c
+
 # non-header sources (headers should be specified in the above variables)
 # that don't serve as direct make target sources, i.e. they don't have
 # their own .lo rules and don't get publically installed
-gobject_extra_sources = @STRIP_BEGIN@ \
+gobject_extra_sources = \
        gmarshal.list           \
-       gmarshal.strings        \
-@STRIP_END@
+       gmarshal.strings
 
 
 #
 # setup GObject library sources and their dependancies
 #
-gobject_target_headers = $(gobject_public_h_sources) $(gobject_built_public_sources)
+gobject_target_headers = $(gobject_public_h_sources)
 gobject_target_sources = $(gobject_c_sources)
-MAINTAINERCLEANFILES += $(gobject_built_sources)
-EXTRA_HEADERS +=
-EXTRA_DIST += $(gobject_private_h_sources) $(gobject_extra_sources)
-EXTRA_DIST += $(gobject_built_sources)
+EXTRA_HEADERS =
+EXTRA_DIST = $(gobject_private_h_sources) $(gobject_extra_sources)
 
 #
 # rules to generate built sources
 #
 # setup autogeneration dependancies
 gen_sources = xgen-gmh xgen-gmc xgen-gms
-CLEANFILES += $(gen_sources)
-
-$(libgobject_2_0_la_OBJECTS): $(gobject_built_sources)  ${gobject_built_public_sources} # this is our oldest file, used for implicit auto-generation deps
-# initial creation of the real stamp-* files
-gmarshal.h:    # never add deps here
-       test -f "$(srcdir)/$@" || touch $(srcdir)/$@
+CLEANFILES = $(gen_sources)
 
 # normal autogeneration rules
 # all autogenerated files need to be generated in the srcdir,
@@ -165,24 +141,31 @@ else
   glib_genmarshal=./glib-genmarshal
 endif
 
-$(srcdir)/stamp-gmarshal.h: @REBUILD@ gmarshal.list gmarshal.h glib-genmarshal$(EXEEXT)
+gmarshal.h: stamp-gmarshal.h
+       @true
+stamp-gmarshal.h: @REBUILD@ gmarshal.list glib-genmarshal$(EXEEXT)
+       $(MAKE) glib-genmarshal$(EXEEXT)
        echo "#ifndef __G_MARSHAL_H__" > xgen-gmh \
        && echo "#define __G_MARSHAL_H__" >> xgen-gmh \
        && $(glib_genmarshal) --nostdinc --prefix=g_cclosure_marshal $(srcdir)/gmarshal.list --header >> xgen-gmh \
        && echo "#endif /* __G_MARSHAL_H__ */" >> xgen-gmh \
-       && (cmp -s xgen-gmh $(srcdir)/gmarshal.h || cp xgen-gmh $(srcdir)/gmarshal.h) \
+       && (cmp -s xgen-gmh gmarshal.h 2>/dev/null || cp xgen-gmh gmarshal.h) \
        && rm -f xgen-gmh xgen-gmh~ \
        && echo timestamp > $@
-$(srcdir)/gmarshal.c: @REBUILD@ $(srcdir)/stamp-gmarshal.h
+
+gmarshal.c: @REBUILD@ stamp-gmarshal.h
        $(glib_genmarshal) --nostdinc --prefix=g_cclosure_marshal $(srcdir)/gmarshal.list --body >> xgen-gmc \
-       && cp xgen-gmc $(srcdir)/gmarshal.c \
+       && cp xgen-gmc gmarshal.c \
        && rm -f xgen-gmc xgen-gmc~
-$(srcdir)/gmarshal.strings: @REBUILD@ $(srcdir)/gmarshal.list
+
+gmarshal.strings: @REBUILD@ $(srcdir)/gmarshal.list
        grep '^[A-Z]' $(srcdir)/gmarshal.list \
        | sed -e 's/^/"g_cclosure_marshal_/' -e 's/:/__/' -e 's/,/_/g' -e 's/$$/",/' > xgen-gms \
-       && cp xgen-gms $(srcdir)/gmarshal.strings \
+       && cp xgen-gms gmarshal.strings \
        && rm -f xgen-gms xgen-gms~
+
 glib-genmarshal.o: gmarshal.strings
+gsignal.lo: gmarshal.c
 
 
 # target platform:
@@ -227,24 +210,18 @@ EXTRA_DIST +=                     \
 BUILT_EXTRA_DIST = \
        makefile.mingw          \
        makefile.msc            \
-       gobject.rc
+       gobject.rc              \
+       gmarshal.h              \
+       gmarshal.c              \
+       stamp-gmarshal.h
 
 if OS_WIN32
-@G_OBJECT_WIN32_RESOURCE@ : gobject.rc
-       $(top_srcdir)/build/win32/lt-compile-resource gobject.rc @G_OBJECT_WIN32_RESOURCE@
+$(G_OBJECT_WIN32_RESOURCE): gobject.rc
+       $(top_srcdir)/build/win32/lt-compile-resource gobject.rc $@
 endif
 
 gobject-2.0.lib: libgobject-2.0.la gobject.def
-       lib -name:libgobject-2.0-@LT_CURRENT_MINUS_AGE@.dll -def:gobject.def -out:$@
-
-gobject.rc: $(top_builddir)/config.status $(top_srcdir)/gobject/gobject.rc.in
-       cd $(top_builddir) && CONFIG_FILES=gobject/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-makefile.mingw: $(top_builddir)/config.status $(top_srcdir)/gobject/makefile.mingw.in
-       cd $(top_builddir) && CONFIG_FILES=gobject/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-makefile.msc: $(top_builddir)/config.status $(top_srcdir)/gobject/makefile.msc.in
-       cd $(top_builddir) && CONFIG_FILES=gobject/$@ CONFIG_HEADERS= $(SHELL) ./config.status
+       lib -name:libgobject-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:gobject.def -out:$@
 
 dist-hook: $(BUILT_EXTRA_DIST)
        files='$(BUILT_EXTRA_DIST)'; \
@@ -255,3 +232,8 @@ dist-hook: $(BUILT_EXTRA_DIST)
 install-data-local: install-ms-lib install-libtool-import-lib
 
 uninstall-local: uninstall-ms-lib uninstall-libtool-import-lib
+
+distclean-local:
+       if test $(srcdir) = .; then :; else \
+           rm -f $(BUILT_EXTRA_DIST); \
+       fi
index 99c6fb8268478c80a7bb46608c9a415f7bad422f..66da12f4f6c8869753c4c350329d5aa9b2b8499c 100644 (file)
@@ -61,26 +61,17 @@ libgthread_2_0_la_LDFLAGS = \
        -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
        -export-dynamic $(no_undefined) $(export_symbols)
 
-libgthread_2_0_la_LIBADD = @G_THREAD_WIN32_RESOURCE@ @G_THREAD_LIBS_EXTRA@ @G_THREAD_LIBS_FOR_GTHREAD@ $(libglib)
+libgthread_2_0_la_LIBADD = $(G_THREAD_WIN32_RESOURCE) $(G_THREAD_LIBS_EXTRA) $(G_THREAD_LIBS_FOR_GTHREAD) $(libglib)
 
-libgthread_2_0_la_DEPENDENCIES = @G_THREAD_WIN32_RESOURCE@ @GTHREAD_DEF@
+libgthread_2_0_la_DEPENDENCIES = $(G_THREAD_WIN32_RESOURCE) $(GTHREAD_DEF)
 
 if OS_WIN32
-@G_THREAD_WIN32_RESOURCE@ : gthread.rc
-       $(top_srcdir)/build/win32/lt-compile-resource gthread.rc @G_THREAD_WIN32_RESOURCE@
+$(G_THREAD_WIN32_RESOURCE): gthread.rc
+       $(top_srcdir)/build/win32/lt-compile-resource gthread.rc $@
 endif
 
 gthread-2.0.lib: libgthread-2.0.la gthread.def
-       lib -name:libgthread-2.0-@LT_CURRENT_MINUS_AGE@.dll -def:gthread.def -out:$@
-
-gthread.rc: $(top_builddir)/config.status $(top_srcdir)/gthread/gthread.rc.in
-       cd $(top_builddir) && CONFIG_FILES=gthread/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-makefile.mingw: $(top_builddir)/config.status $(top_srcdir)/gthread/makefile.mingw.in
-       cd $(top_builddir) && CONFIG_FILES=gthread/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-makefile.msc: $(top_builddir)/config.status $(top_srcdir)/gthread/makefile.msc.in
-       cd $(top_builddir) && CONFIG_FILES=gthread/$@ CONFIG_HEADERS= $(SHELL) ./config.status
+       lib -name:libgthread-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:gthread.def -out:$@
 
 dist-hook: $(BUILT_EXTRA_DIST)
        files='$(BUILT_EXTRA_DIST)'; \
@@ -91,3 +82,4 @@ dist-hook: $(BUILT_EXTRA_DIST)
 install-data-local: install-ms-lib install-libtool-import-lib
 
 uninstall-local: uninstall-ms-lib uninstall-libtool-import-lib
+
index 32578c6587a9b3c0923f62bcd4b70298ee3c2255..9449929d661314510646118625d98d282aaaf8b3 100644 (file)
@@ -1,3 +1,10 @@
+2003-02-27  James Henstridge  <james@daa.com.au>
+
+       * Makefile.in.in (uninstall): fix uninstall target so that it
+       correctly removes the installed Makefile.in.in if PACKAGE==glib.
+       (update-po): update to use logic more similar to new gettexts,
+       which should pass readonly srcdir distcheck.
+
 2003-02-24  Roozbeh Pournader  <roozbeh@sharif.edu>
 
        * fa.po: Updated Persian translation.
index 435cd18280dad1ec822b7efc9f565a5a53e82455..092b4e0dc3f1e1eb540abe84816e0fc10af1773c 100644 (file)
@@ -169,7 +169,9 @@ uninstall:
          rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE)$(INSTOBJEXT); \
          rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE)$(INSTOBJEXT).m; \
        done
-       rm -f $(DESTDIR)$(gettextsrcdir)/po-Makefile.in.in
+       if test "$(PACKAGE)" = "glib"; then \
+         rm -f $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
+       fi
 
 check: all
 
@@ -199,19 +201,28 @@ dist distdir: update-po $(DISTFILES)
 
 update-po: Makefile
        $(MAKE) $(GETTEXT_PACKAGE).pot
+       tmpdir=`pwd`; \
        cd $(srcdir); \
        catalogs='$(CATALOGS)'; \
        for cat in $$catalogs; do \
          cat=`basename $$cat`; \
          lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
-         mv $$lang.po $$lang.old.po; \
          echo "$$lang:"; \
-         if $(MSGMERGE) $$lang.old.po $(GETTEXT_PACKAGE).pot -o $$lang.po; then \
-           rm -f $$lang.old.po; \
+         if $(MSGMERGE) $$lang.po $(GETTEXT_PACKAGE).pot -o $$tmpdir/$$lang.new.po; then \
+           if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
+             rm -f $$tmpdir/$$lang.new.po; \
+            else \
+             if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \
+               :; \
+             else \
+               echo "msgmerge for $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \
+               rm -f $$tmpdir/$$lang.new.po; \
+               exit 1; \
+             fi; \
+           fi; \
          else \
            echo "msgmerge for $$cat failed!"; \
-           rm -f $$lang.po; \
-           mv $$lang.old.po $$lang.po; \
+           rm -f $$tmpdir/$$lang.new.po; \
          fi; \
        done
 
index 010b96f827785b27ca26a07099cc66caad35e434..2a3c2f893c762e5bbc641414b0a466e002b0b1a1 100644 (file)
@@ -1,4 +1,4 @@
-INCLUDES = -I$(top_srcdir) -I$(top_srcdir)/glib -I$(top_srcdir)/gmodule @GLIB_DEBUG_FLAGS@
+INCLUDES = -I$(top_srcdir) -I$(top_srcdir)/glib -I$(top_srcdir)/gmodule $(GLIB_DEBUG_FLAGS)
 
 EFENCE=
 
@@ -103,8 +103,8 @@ TESTS_ENVIRONMENT = srcdir=$(srcdir) \
        LIBCHARSET_ALIAS_DIR=$(top_builddir)/glib/libcharset
 
 progs_ldadd = $(EFENCE) $(libglib) $(EFENCE)
-thread_ldadd = $(libgthread) @G_THREAD_LIBS@ $(progs_ldadd)
-module_ldadd = $(libgmodule) @G_MODULE_LIBS@ $(progs_ldadd)
+thread_ldadd = $(libgthread) $(G_THREAD_LIBS) $(progs_ldadd)
+module_ldadd = $(libgmodule) $(G_MODULE_LIBS) $(progs_ldadd)
 
 array_test_LDADD = $(progs_ldadd)
 date_test_LDADD = $(progs_ldadd)
@@ -116,7 +116,7 @@ list_test_LDADD = $(progs_ldadd)
 mainloop_test_LDADD = $(thread_ldadd)
 markup_test_LDADD = $(progs_ldadd)
 module_test_LDADD = $(module_ldadd) $(module_test_exp)
-module_test_LDFLAGS = @G_MODULE_LDFLAGS@
+module_test_LDFLAGS = $(G_MODULE_LDFLAGS)
 node_test_LDADD = $(progs_ldadd)
 queue_test_LDADD = $(progs_ldadd)
 qsort_test_LDADD = $(progs_ldadd)
@@ -143,18 +143,12 @@ install-libLTLIBRARIES:
        :
 
 libmoduletestplugin_a_la_SOURCES = libmoduletestplugin_a.c
-libmoduletestplugin_a_la_LDFLAGS = @G_MODULE_LDFLAGS@ -avoid-version -module $(no_undefined) -rpath $(libdir)
-libmoduletestplugin_a_la_LIBADD = @G_MODULE_LIBS@ $(libadd_libgmodule) $(libadd_libglib)
+libmoduletestplugin_a_la_LDFLAGS = $(G_MODULE_LDFLAGS) -avoid-version -module $(no_undefined) -rpath $(libdir)
+libmoduletestplugin_a_la_LIBADD = $(G_MODULE_LIBS) $(libadd_libgmodule) $(libadd_libglib)
 
 libmoduletestplugin_b_la_SOURCES = libmoduletestplugin_b.c
-libmoduletestplugin_b_la_LDFLAGS = @G_MODULE_LDFLAGS@ -avoid-version -module $(no_undefined) -rpath $(libdir)
-libmoduletestplugin_b_la_LIBADD = @G_MODULE_LIBS@ $(libadd_libgmodule) $(libadd_libglib)
-
-makefile.mingw: $(top_builddir)/config.status $(top_srcdir)/tests/makefile.mingw.in
-       cd $(top_builddir) && CONFIG_FILES=tests/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-makefile.msc: $(top_builddir)/config.status $(top_srcdir)/tests/makefile.msc.in
-       cd $(top_builddir) && CONFIG_FILES=tests/$@ CONFIG_HEADERS= $(SHELL) ./config.status
+libmoduletestplugin_b_la_LDFLAGS = $(G_MODULE_LDFLAGS) -avoid-version -module $(no_undefined) -rpath $(libdir)
+libmoduletestplugin_b_la_LIBADD = $(G_MODULE_LIBS) $(libadd_libgmodule) $(libadd_libglib)
 
 dist-hook: $(BUILT_EXTRA_DIST)
        files='$(BUILT_EXTRA_DIST)'; \
@@ -165,3 +159,5 @@ dist-hook: $(BUILT_EXTRA_DIST)
        for f in $(srcdir)/markups/* ; do  \
          cp $$f $(distdir)/markups;       \
        done
+
+DISTCLEANFILES = iochannel-test-outfile