in case we have to abort the program, debugging is enabled and we are not
[platform/upstream/glib.git] / Makefile.am
1 ## Process this file with automake to produce Makefile.in
2
3 AUTOMAKE_OPTIONS = 1.4
4
5 SUBDIRS = . gmodule gthread docs tests
6
7 bin_SCRIPTS=glib-config
8 BUILT_SOURCES=glib-config
9 glib-config: glib-config.in
10
11 INCLUDES = -DG_LOG_DOMAIN=g_log_domain_glib @GLIB_DEBUG_FLAGS@
12
13 EXTRA_DIST = \
14         glib.m4                 \
15         glib.spec.in            \
16         acglib.m4               \
17         sanity_check            \
18         README.win32            \
19         glib.def                \
20         makefile.msc            \
21         makefile.cygwin         \
22         giowin32.c              \
23         glibconfig.h.win32      \
24         config.h.win32          \
25         build-dll
26
27 lib_LTLIBRARIES = libglib.la
28
29 libglib_la_SOURCES = \
30         garray.c        \
31         gcache.c        \
32         gcompletion.c   \
33         gdataset.c      \
34         gdate.c         \
35         gerror.c        \
36         ghash.c         \
37         ghook.c         \
38         giochannel.c    \
39         giounix.c       \
40         glist.c         \
41         gmain.c         \
42         gmem.c          \
43         gmessages.c     \
44         gnode.c         \
45         gprimes.c       \
46         gqueue.c        \
47         grel.c          \
48         grand.c         \
49         gscanner.c      \
50         gslist.c        \
51         gstrfuncs.c     \
52         gstring.c       \
53         gthread.c       \
54         gtimer.c        \
55         gtree.c         \
56         gutils.c
57
58 include_HEADERS = \
59         glib.h
60
61 configexecincludedir = $(pkglibdir)/include
62 #configexecinclude_DATA = glibconfig.h
63
64 install-exec-local: glibconfig.h
65         $(mkinstalldirs) $(DESTDIR)$(configexecincludedir)
66         file=$(DESTDIR)$(configexecincludedir)/glibconfig.h; \
67         if test -r $$file && cmp -s glibconfig.h $$file; then :; \
68         else $(INSTALL_DATA) glibconfig.h $$file; fi
69
70 configure: configure.in acglib.m4               
71
72 BUILT_SOURCES = stamp-gc-h #note: not glibconfig.h
73 glibconfig.h: stamp-gc-h
74         @if test -f glibconfig.h; then :; \
75         else rm -f stamp-gc-h; $(MAKE) stamp-gc-h; fi
76 stamp-gc-h: config.status
77         CONFIG_FILES= CONFIG_HEADERS= CONFIG_OTHER=glibconfig.h ./config.status
78         echo timestamp > stamp-gc-h
79
80 libglib_la_LDFLAGS = \
81         -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
82         -release $(LT_RELEASE) \
83         -export-dynamic
84
85 noinst_PROGRAMS = testglib testgdate testgdateparser
86 testglib_LDADD = libglib.la
87 testgdate_LDADD = libglib.la
88 testgdateparser_LDADD = libglib.la
89
90 m4datadir = $(datadir)/aclocal
91 m4data_DATA = glib.m4
92
93 glibconfig.h.win32: $(top_builddir)/config.status $(top_srcdir)/glibconfig.h.win32.in
94         cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
95
96 config.h.win32: $(top_builddir)/config.status $(top_srcdir)/config.h.win32.in
97         cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
98
99 makefile.msc: $(top_builddir)/config.status $(top_srcdir)/makefile.msc.in
100         cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
101
102 makefile.cygwin: $(top_builddir)/config.status $(top_srcdir)/makefile.cygwin.in
103         cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
104
105 .PHONY: files release sanity snapshot
106
107 files:
108         @files=`ls $(DISTFILES) 2> /dev/null `; for p in $$files; do \
109           echo $$p; \
110         done
111
112 release:
113         rm -rf .deps */.deps
114         cd docs && make glib.html
115         $(MAKE) distcheck
116
117 sanity:
118         ./sanity_check $(VERSION)
119
120 snapshot:
121         $(MAKE) dist distdir=$(PACKAGE)`date +"%y%m%d"`
122
123 dist-hook:
124         cp glib.spec $(distdir)