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