Add a GIcon implementation that can add an emblem to another icon.
[platform/upstream/glib.git] / gio / Makefile.am
1 include $(top_srcdir)/Makefile.decl
2
3 NULL =
4
5 SUBDIRS=
6
7 if OS_UNIX
8 SUBDIRS += xdgmime
9 endif
10
11 if OS_WIN32_AND_DLL_COMPILATION
12 if MS_LIB_AVAILABLE
13 noinst_DATA = gio-2.0.lib
14
15 install_ms_lib_cmd = $(INSTALL) gio-2.0.lib $(DESTDIR)$(libdir)
16 uninstall_ms_lib_cmd = -rm $(DESTDIR)$(libdir)/gio-2.0.lib
17 endif
18 endif
19
20 install-ms-lib:
21         $(install_ms_lib_cmd)
22
23 uninstall-ms-lib:
24         $(uninstall_ms_lib_cmd)
25
26 gio.def: gio.symbols
27         (echo -e EXPORTS; $(CPP) -P -DINCLUDE_VARIABLES -DINCLUDE_INTERNAL_SYMBOLS -DG_OS_WIN32 -DALL_FILES - <$(srcdir)/gio.symbols | sed -e '/^$$/d' -e 's/^/ /' -e 's/G_GNUC_[^ ]*//g' | sort) > gio.def.tmp && \
28           mv gio.def.tmp gio.def
29
30 gioalias.h: gio.symbols
31         $(PERL) $(srcdir)/makegioalias.pl < $(srcdir)/gio.symbols > gioalias.h.tmp && \
32           mv gioalias.h.tmp gioalias.h
33
34 gioaliasdef.c: gio.symbols
35         $(PERL) $(srcdir)/makegioalias.pl -def < $(srcdir)/gio.symbols > gioaliasdef.c.tmp && \
36           mv gioaliasdef.c.tmp gioaliasdef.c
37
38 if OS_LINUX
39 if HAVE_GNUC_VISIBILITY
40 TESTS = abicheck.sh pltcheck.sh
41 endif
42 endif
43
44 AM_CPPFLAGS = \
45         -DG_LOG_DOMAIN=\"GLib-GIO\"                     \
46         -I$(top_builddir)                               \
47         -I$(top_srcdir)                                 \
48         -I$(top_srcdir)/glib                            \
49         -I$(top_srcdir)/gmodule                         \
50         $(GLIB_DEBUG_FLAGS)                             \
51         -DG_DISABLE_DEPRECATED                          \
52         -DGIO_COMPILATION                               \
53         -DGIO_MODULE_DIR=\"$(GIO_MODULE_DIR)\"  
54
55 lib_LTLIBRARIES = libgio-2.0.la
56
57 marshal_sources = \
58         gio-marshal.h   \
59         gio-marshal.c   \
60         $(NULL)
61
62 if CROSS_COMPILING
63   glib_genmarshal=$(GLIB_GENMARSHAL)
64 else
65   glib_genmarshal=../gobject/glib-genmarshal
66 endif
67
68 gio-marshal.h: gio-marshal.list
69         $(glib_genmarshal) --prefix=_gio_marshal $(srcdir)/gio-marshal.list --header --internal > $@.tmp && \
70           mv $@.tmp $@
71
72 gio-marshal.c: gio-marshal.h gio-marshal.list
73         (echo "#include \"gio-marshal.h\""; \
74         $(glib_genmarshal) --prefix=_gio_marshal $(srcdir)/gio-marshal.list --body --internal) > $@.tmp && \
75           mv $@.tmp $@
76
77 local_sources = \
78         glocaldirectorymonitor.c        \
79         glocaldirectorymonitor.h        \
80         glocalfile.c                    \
81         glocalfile.h                    \
82         glocalfileenumerator.c          \
83         glocalfileenumerator.h          \
84         glocalfileinfo.c                \
85         glocalfileinfo.h                \
86         glocalfileinputstream.c         \
87         glocalfileinputstream.h         \
88         glocalfilemonitor.c             \
89         glocalfilemonitor.h             \
90         glocalfileoutputstream.c        \
91         glocalfileoutputstream.h        \
92         glocalvfs.c                     \
93         glocalvfs.h                     \
94         $(NULL)
95
96 platform_libadd =
97 appinfo_sources =
98
99 if HAVE_INOTIFY
100 SUBDIRS += inotify
101 platform_libadd += inotify/libinotify.la
102 endif
103
104 if HAVE_FEN
105 AM_CPPFLAGS += -DHAVE_FEN
106 SUBDIRS += fen
107 platform_libadd += fen/libfen.la
108 endif
109
110 if OS_WIN32
111 SUBDIRS += win32
112 platform_libadd += win32/libgiowin32.la
113 endif
114
115
116 SUBDIRS += .
117
118 if HAVE_FAM
119 SUBDIRS += fam
120 endif
121
122 if OS_UNIX
123 appinfo_sources += gdesktopappinfo.c gdesktopappinfo.h
124 platform_libadd += xdgmime/libxdgmime.la
125 unix_sources = \
126         gunixmount.c            \
127         gunixmount.h            \
128         gunixmounts.c           \
129         gunixmounts.h           \
130         gunixvolume.c           \
131         gunixvolume.h           \
132         gunixvolumemonitor.c    \
133         gunixvolumemonitor.h    \
134         gunixinputstream.c      \
135         gunixoutputstream.c     \
136         $(NULL)
137
138
139 giounixincludedir=$(includedir)/gio-unix-2.0/gio
140 giounixinclude_HEADERS = \
141         gdesktopappinfo.h       \
142         gunixmounts.h           \
143         gunixinputstream.h      \
144         gunixoutputstream.h     \
145         $(NULL)
146 endif
147
148 if OS_WIN32
149 appinfo_sources += gwin32appinfo.c gwin32appinfo.h
150 platform_libadd += -lshlwapi -lwininet
151 win32_sources = \
152         gwin32mount.c \
153         gwin32mount.h \
154         gwin32volumemonitor.c \
155         gwin32volumemonitor.h \
156         $(NULL)
157
158 endif
159
160 SUBDIRS += tests
161
162 libgio_2_0_la_SOURCES =         \
163         gappinfo.c              \
164         gasynchelper.c          \
165         gasynchelper.h          \
166         gasyncresult.c          \
167         gbufferedinputstream.c  \
168         gbufferedoutputstream.c \
169         gcancellable.c          \
170         gcontenttype.c          \
171         gcontenttypeprivate.h   \
172         gdatainputstream.c      \
173         gdataoutputstream.c     \
174         gdrive.c                \
175         gdummyfile.h            \
176         gdummyfile.c            \
177         gemblemedicon.h         \
178         gemblemedicon.c         \
179         gfile.c                 \
180         gfileattribute.c        \
181         gfileattribute-priv.h   \
182         gfileenumerator.c       \
183         gfileicon.c             \
184         gfileinfo.c             \
185         gfileinputstream.c      \
186         gfilemonitor.c          \
187         gfilenamecompleter.c    \
188         gfileoutputstream.c     \
189         gfilterinputstream.c    \
190         gfilteroutputstream.c   \
191         gicon.c                 \
192         ginputstream.c          \
193         gioenums.h              \
194         gioerror.c              \
195         giomodule.c             \
196         giomodule-priv.h        \
197         gioscheduler.c          \
198         gloadableicon.c         \
199         gmount.c                \
200         gmemoryinputstream.c    \
201         gmemoryoutputstream.c   \
202         gmountoperation.c       \
203         gnativevolumemonitor.c  \
204         gnativevolumemonitor.h  \
205         goutputstream.c         \
206         gpollfilemonitor.c      \
207         gpollfilemonitor.h      \
208         gseekable.c             \
209         gsimpleasyncresult.c    \
210         gthemedicon.c           \
211         gunionvolumemonitor.c   \
212         gunionvolumemonitor.h   \
213         gvfs.c                  \
214         gvolume.c               \
215         gvolumemonitor.c        \
216         gmountprivate.h         \
217         gioenumtypes.h          \
218         gioenumtypes.c          \
219         gioalias.h              \
220         gioaliasdef.c           \
221         $(appinfo_sources)      \
222         $(unix_sources)         \
223         $(win32_sources)        \
224         $(local_sources)        \
225         $(marshal_sources)      \
226         $(NULL)
227
228 $(libgio_2_0_la_OBJECTS): $(marshal_sources)
229
230 libgio_2_0_la_LIBADD = \
231         $(top_builddir)/glib/libglib-2.0.la             \
232         $(top_builddir)/gobject/libgobject-2.0.la       \
233         $(top_builddir)/gmodule/libgmodule-2.0.la       \
234         $(platform_libadd)                              \
235         $(SELINUX_LIBS)                                 \
236         $(GLIB_LIBS)                                    \
237         $(XATTR_LIBS)                                   \
238         $(NULL)
239
240 if PLATFORM_WIN32
241 no_undefined = -no-undefined
242 endif
243
244 if OS_WIN32_AND_DLL_COMPILATION
245 export_symbols = -export-symbols gio.def
246 gio_def = gio.def
247
248 install-def-file:
249         $(INSTALL) gio.def $(DESTDIR)$(libdir)/gio-2.0.def
250
251 uninstall-def-file:
252         -rm $(DESTDIR)$(libdir)/gio-2.0.def
253 else
254 install-def-file:
255 uninstall-def-file:
256
257 export_symbols = -export-symbols-regex '^g_.*'
258 endif
259
260 install-data-local: install-ms-lib install-def-file
261
262 uninstall-local: uninstall-ms-lib uninstall-def-file
263
264 libgio_2_0_la_LDFLAGS = \
265         -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
266         -export-dynamic $(no_undefined) $(export_symbols)
267
268 libgio_2_0_la_DEPENDENCIES = $(gio_def)
269
270 gio_headers =                   \
271         gappinfo.h              \
272         gasyncresult.h          \
273         gbufferedinputstream.h  \
274         gbufferedoutputstream.h \
275         gcancellable.h          \
276         gcontenttype.h          \
277         gdatainputstream.h      \
278         gdataoutputstream.h     \
279         gdrive.h                \
280         gfile.h                 \
281         gfileattribute.h        \
282         gfileenumerator.h       \
283         gfileicon.h             \
284         gfileinfo.h             \
285         gfileinputstream.h      \
286         gfilemonitor.h          \
287         gfilenamecompleter.h    \
288         gfileoutputstream.h     \
289         gfilterinputstream.h    \
290         gfilteroutputstream.h   \
291         gicon.h                 \
292         ginputstream.h          \
293         gio.h                   \
294         giotypes.h              \
295         gioenums.h              \
296         gioerror.h              \
297         giomodule.h             \
298         gioscheduler.h          \
299         gloadableicon.h         \
300         gmount.h                \
301         gmemoryinputstream.h    \
302         gmemoryoutputstream.h   \
303         gmountoperation.h       \
304         gnativevolumemonitor.h  \
305         goutputstream.h         \
306         gseekable.h             \
307         gsimpleasyncresult.h    \
308         gthemedicon.h           \
309         gvfs.h                  \
310         gvolume.h               \
311         gvolumemonitor.h        \
312         $(NULL)
313
314 gioincludedir=$(includedir)/glib-2.0/gio/
315 gioinclude_HEADERS =            \
316         $(gio_headers)          \
317         gioenumtypes.h
318
319 # these sources (also mentioned above) are generated.
320 BUILT_SOURCES =                 \
321         gio-marshal.h           \
322         gio-marshal.c           \
323         gioalias.h              \
324         gioaliasdef.c           \
325         gioenumtypes.h          \
326         gioenumtypes.c          \
327         $(NULL)
328
329 EXTRA_DIST +=                   \
330         gio-marshal.list        \
331         gio.symbols             \
332         gioenumtypes.h.template \
333         gioenumtypes.c.template \
334         makefile.msc            \
335         makegioalias.pl         \
336         abicheck.sh             \
337         pltcheck.sh             \
338         $(NULL)
339
340 CLEANFILES =                    \
341         $(marshal_sources)      \
342         $(NULL)
343
344 gioenumtypes.h: $(gio_headers) gioenumtypes.h.template
345         ( top_builddir=`cd $(top_builddir) && pwd`; \
346           cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.h.template $(gio_headers) ) > \
347             gioenumtypes.h.tmp && mv gioenumtypes.h.tmp gioenumtypes.h
348
349 gioenumtypes.c: $(gio_headers) gioenumtypes.c.template
350         ( top_builddir=`cd $(top_builddir) && pwd`; \
351           cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.c.template $(gio_headers) ) > \
352             gioenumtypes.c.tmp && mv gioenumtypes.c.tmp gioenumtypes.c
353
354 gio-2.0.lib: libgio-2.0.la gio.def
355         lib -machine:@LIB_EXE_MACHINE_FLAG@ -name:libgio-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:gio.def -out:$@