INCLUDES is the right way to add to CFLAGS, not DEFS. Also there are bugs
[platform/upstream/glib.git] / Makefile.am
index 3f1529c..bf03bcc 100644 (file)
@@ -1,6 +1,10 @@
 ## Process this file with automake to produce Makefile.in
 
-SUBDIRS = gmodule
+# build . first, then SUBDIRS
+SUBDIRS = gmodule docs
+all-recursive-am: all-am
+# alpha `automake' supports this better
+#SUBDIRS = . gmodule docs
 
 configincludedir = $(pkglibdir)/include
 
@@ -8,24 +12,28 @@ bin_SCRIPTS=glib-config
 BUILT_SOURCES=glib-config
 glib-config: glib-config.in
 
-DEFS += -DG_LOG_DOMAIN=g_log_domain_glib
+INCLUDES = -DG_LOG_DOMAIN=g_log_domain_glib
 
-EXTRA_DIST =   \
-               glib.m4 \
-               glib.spec
+EXTRA_DIST = \
+       glib.m4         \
+       glib.spec       \
+       sanity_check    \
+       README.win32    \
+       glib.def        \
+       makefile.lcc    \
+       makefile.msc    \
+       glibconfig.h.win32
 
-# build . first, then SUBDIRS
-all-recursive-am: all-am
+lib_LTLIBRARIES = libglib.la
 
-lib_LTLIBRARIES = libglib-1.1.la
-
-libglib_1_1_la_SOURCES = \
+libglib_la_SOURCES = \
                garray.c        \
                gcache.c        \
                gcompletion.c   \
                gdataset.c      \
                gerror.c        \
                ghash.c         \
+               ghook.c         \
                glist.c         \
                gmem.c          \
                gmessages.c     \
@@ -46,17 +54,23 @@ include_HEADERS = \
 configinclude_DATA = \
                glibconfig.h
 
-libglib_1_1_la_LDFLAGS = -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE)
+BUILT_SOURCES = stamp-gc-h #note: not glibconfig.h
+glibconfig.h: stamp-gc-h
+       @:
+stamp-gc-h: config.status
+       CONFIG_FILES= CONFIG_HEADERS= CONFIG_OTHER=glibconfig.h ./config.status
+       echo timestamp > stamp-gc-h
 
-INCLUDES = -I$(top_srcdir)
+libglib_la_LDFLAGS = \
+       -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) -release $(LT_RELEASE)
 
 noinst_PROGRAMS = testglib
-testglib_LDADD = libglib-@LT_RELEASE@.la
+testglib_LDADD = libglib.la
 
 m4datadir = $(datadir)/aclocal
 m4data_DATA = glib.m4
 
-.PHONY: files release
+.PHONY: files release sanity snapshot
 
 files:
        @files=`ls $(DISTFILES) 2> /dev/null `; for p in $$files; do \
@@ -64,4 +78,12 @@ files:
        done
 
 release:
+       rm -rf .deps */.deps
+       cd docs && make glib.html
+       $(MAKE) distcheck
+
+sanity:
+       ./sanity_check $(VERSION)
+
+snapshot:
        $(MAKE) dist distdir=$(PACKAGE)`date +"%y%m%d"`