-I$(top_srcdir)/gmodule, fix from Michael Meeks
[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 = . gobject gmodule gthread docs tests build
6
7 bin_SCRIPTS=glib-config-2.0
8 BUILT_SOURCES=glib-config-2.0
9 glib-config-2.0: glib-config-2.0.in
10
11 INCLUDES = -DG_LOG_DOMAIN=g_log_domain_glib @GLIB_DEBUG_FLAGS@ \
12         -DG_DISABLE_COMPAT_H
13
14 EXTRA_DIST =                    \
15         ChangeLog.pre-1-2       \
16         glib-2.0.m4             \
17         glib.spec.in            \
18         acglib.m4               \
19         sanity_check            \
20         README.win32            \
21         TODO.xml                \
22         glib.def                \
23         makefile.msc.in         \
24         makefile.mingw.in       \
25         giowin32.c              \
26         glibconfig.h.win32.in   \
27         gwin32.c                \
28         gspawn-win32.c          \
29         gspawn-win32-helper.c   \
30         config.h.win32.in       \
31         build-dll               \
32         glib.rc.in              \
33         glib-2.0.pc.in          \
34         gobject-2.0.pc.in       \
35         gmodule-2.0.pc.in       \
36         gthread-2.0.pc.in       \
37         gen-unicode-tables.pl
38
39 # These may be in the builddir too
40 BUILT_EXTRA_DIST = \
41         makefile.msc            \
42         makefile.mingw          \
43         glibconfig.h.win32      \
44         config.h.win32          \
45         glib.rc                 \
46         glib.spec
47
48 lib_LTLIBRARIES = libglib-1.3.la
49
50 libglib_1_3_la_SOURCES =        \
51         garray.c                \
52         gasyncqueue.c           \
53         gbacktrace.c            \
54         gcache.c                \
55         gcompletion.c           \
56         gconvert.c              \
57         gdataset.c              \
58         gdate.c                 \
59         gerror.c                \
60         gfileutils.c            \
61         ghash.c                 \
62         ghook.c                 \
63         giochannel.c            \
64         giounix.c               \
65         glist.c                 \
66         gmain.c                 \
67         gmarkup.c               \
68         gmem.c                  \
69         gmessages.c             \
70         gnode.c                 \
71         gprimes.c               \
72         gqsort.c                \
73         gqueue.c                \
74         grel.c                  \
75         grand.c                 \
76         gscanner.c              \
77         gshell.c                \
78         gslist.c                \
79         gspawn.c                \
80         gstrfuncs.c             \
81         gstring.c               \
82         gthread.c               \
83         gthreadpool.c           \
84         gtimer.c                \
85         gtree.c                 \
86         guniprop.c              \
87         gutf8.c                 \
88         gunibreak.h             \
89         gunibreak.c             \
90         gunichartables.h        \
91         gunidecomp.h            \
92         gunidecomp.c            \
93         gutils.c
94
95 ## If we decide to link in 'alloca.c', this is how to do it
96 #libglib_1_3_la_LIBADD = @ALLOCA@
97
98 glibincludedir=$(includedir)/glib-2.0
99 glibinclude_HEADERS =   \
100         galloca.h       \
101         garray.h        \
102         gasyncqueue.h   \
103         gbacktrace.h    \
104         gcache.h        \
105         gcompat.h       \
106         gcompletion.h   \
107         gconvert.h      \
108         gdataset.h      \
109         gdate.h         \
110         gerror.h        \
111         gfileutils.h    \
112         ghash.h         \
113         ghook.h         \
114         giochannel.h    \
115         glib.h          \
116         glib-object.h   \
117         glist.h         \
118         gmacros.h       \
119         gmain.h         \
120         gmarkup.h       \
121         gmem.h          \
122         gmessages.h     \
123         gnode.h         \
124         gprimes.h       \
125         gqsort.h        \
126         gquark.h        \
127         gqueue.h        \
128         grand.h         \
129         grel.h          \
130         gscanner.h      \
131         gshell.h        \
132         gslist.h        \
133         gspawn.h        \
134         gstrfuncs.h     \
135         gstring.h       \
136         gthread.h       \
137         gthreadpool.h   \
138         gtimer.h        \
139         gtree.h         \
140         gtypes.h        \
141         gunicode.h      \
142         gutils.h        \
143         gwin32.h
144
145 configexecincludedir = $(libdir)/glib-2.0/include
146 #configexecinclude_DATA = glibconfig.h
147
148 install-exec-local: glibconfig.h
149         $(mkinstalldirs) $(DESTDIR)$(configexecincludedir)
150         file=$(DESTDIR)$(configexecincludedir)/glibconfig.h; \
151         if test -r $$file && cmp -s glibconfig.h $$file; then :; \
152         else $(INSTALL_DATA) glibconfig.h $$file; fi
153
154 CONFIGURE_DEPENDENCIES = acglib.m4
155
156 BUILT_SOURCES = stamp-gc-h #note: not glibconfig.h
157 glibconfig.h: stamp-gc-h
158         @if test -f glibconfig.h; then :; \
159         else rm -f stamp-gc-h; $(MAKE) stamp-gc-h; fi
160 stamp-gc-h: config.status
161         CONFIG_FILES= CONFIG_HEADERS= CONFIG_OTHER=glibconfig.h ./config.status
162         echo timestamp > stamp-gc-h
163
164 libglib_1_3_la_LIBADD = @ICONV_LIBS@
165
166 libglib_1_3_la_LDFLAGS = \
167         -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
168         -export-dynamic
169
170 noinst_PROGRAMS = testglib testgdate testgdateparser timeloop
171 testglib_LDADD = libglib-1.3.la
172 testgdate_LDADD = libglib-1.3.la
173 testgdateparser_LDADD = libglib-1.3.la
174 timeloop_LDADD = libglib-1.3.la
175
176 m4datadir = $(datadir)/aclocal
177 m4data_DATA = glib-2.0.m4
178
179 pkgconfigdir = $(libdir)/pkgconfig
180 pkgconfig_DATA = glib-2.0.pc gobject-2.0.pc gmodule-2.0.pc gthread-2.0.pc
181
182 glibconfig.h.win32: $(top_builddir)/config.status $(top_srcdir)/glibconfig.h.win32.in
183         cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
184
185 config.h.win32: $(top_builddir)/config.status $(top_srcdir)/config.h.win32.in
186         cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
187
188 makefile.msc: $(top_builddir)/config.status $(top_srcdir)/makefile.msc.in
189         cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
190
191 makefile.mingw: $(top_builddir)/config.status $(top_srcdir)/makefile.mingw.in
192         cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
193
194 glib.rc: $(top_builddir)/config.status $(top_srcdir)/glib.rc.in
195         cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
196
197 .PHONY: files release sanity snapshot
198
199 files:
200         @files=`ls $(DISTFILES) 2> /dev/null `; for p in $$files; do \
201           echo $$p; \
202         done
203
204 release:
205         rm -rf .deps */.deps
206         cd docs && make glib.html
207         $(MAKE) distcheck
208
209 sanity:
210         ./sanity_check $(VERSION)
211
212 snapshot:
213         $(MAKE) dist distdir=$(PACKAGE)-snap`date +"%Y%m%d"`
214
215 snapcheck:
216         $(MAKE) distcheck distdir=$(PACKAGE)-snap`date +"%Y%m%d"`
217
218 dist-hook: $(BUILT_EXTRA_DIST)
219         files='$(BUILT_EXTRA_DIST)'; \
220         for f in $$files; do \
221           if test -f $$f; then d=.; else d=$(srcdir); fi; \
222           cp $$d/$$f $(distdir) || exit 1; done