build: Add --disable-modular-tests build option
[platform/upstream/glib.git] / gio / Makefile.am
1 include $(top_srcdir)/Makefile.decl
2
3 NULL =
4
5 DIST_SUBDIRS =
6 SUBDIRS = gdbus-2.0/codegen
7
8 if OS_UNIX
9 SUBDIRS += xdgmime
10 endif
11
12 if OS_WIN32_AND_DLL_COMPILATION
13 if MS_LIB_AVAILABLE
14 noinst_DATA = gio-2.0.lib
15
16 install_ms_lib_cmd = $(INSTALL) gio-2.0.lib $(DESTDIR)$(libdir)
17 uninstall_ms_lib_cmd = -rm $(DESTDIR)$(libdir)/gio-2.0.lib
18 endif
19 endif
20
21 install-ms-lib:
22         $(install_ms_lib_cmd)
23
24 uninstall-ms-lib:
25         $(uninstall_ms_lib_cmd)
26
27 gio.def: gio.symbols
28         $(AM_V_GEN) (echo 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) > $(builddir)/gio.def.tmp && \
29           mv $(builddir)/gio.def.tmp $(builddir)/gio.def
30
31 if OS_LINUX
32 if HAVE_GNUC_VISIBILITY
33 TESTS = abicheck.sh
34 endif
35 endif
36
37 AM_CPPFLAGS = \
38         -DG_LOG_DOMAIN=\"GLib-GIO\"                     \
39         $(gmodule_INCLUDES)                             \
40         $(GLIB_DEBUG_FLAGS)                             \
41         -DGIO_COMPILATION                               \
42         -DGIO_MODULE_DIR=\"$(GIO_MODULE_DIR)\"  
43
44 lib_LTLIBRARIES = libgio-2.0.la
45
46 gdbus_headers =                         \
47         gdbusauthobserver.h             \
48         gcredentials.h                  \
49         gdbusutils.h                    \
50         gdbuserror.h                    \
51         gdbusaddress.h                  \
52         gdbusconnection.h               \
53         gdbusmessage.h                  \
54         gdbusnameowning.h               \
55         gdbusnamewatching.h             \
56         gdbusproxy.h                    \
57         gdbusintrospection.h            \
58         gdbusmethodinvocation.h         \
59         gdbusserver.h                   \
60         gdbusinterface.h                \
61         gdbusinterfaceskeleton.h        \
62         gdbusobject.h                   \
63         gdbusobjectskeleton.h           \
64         gdbusobjectproxy.h              \
65         gdbusobjectmanager.h            \
66         gdbusobjectmanagerclient.h      \
67         gdbusobjectmanagerserver.h      \
68         $(NULL)
69
70 gdbus_sources =                                                         \
71         gdbusutils.h                    gdbusutils.c                    \
72         gdbusaddress.h                  gdbusaddress.c                  \
73         gdbusauthobserver.h             gdbusauthobserver.c             \
74         gdbusauth.h                     gdbusauth.c                     \
75         gdbusauthmechanism.h            gdbusauthmechanism.c            \
76         gdbusauthmechanismanon.h        gdbusauthmechanismanon.c        \
77         gdbusauthmechanismexternal.h    gdbusauthmechanismexternal.c    \
78         gdbusauthmechanismsha1.h        gdbusauthmechanismsha1.c        \
79         gdbuserror.h                    gdbuserror.c                    \
80         gdbusconnection.h               gdbusconnection.c               \
81         gdbusmessage.h                  gdbusmessage.c                  \
82         gdbusnameowning.h               gdbusnameowning.c               \
83         gdbusnamewatching.h             gdbusnamewatching.c             \
84         gdbusproxy.h                    gdbusproxy.c                    \
85         gdbusprivate.h                  gdbusprivate.c                  \
86         gdbusintrospection.h            gdbusintrospection.c            \
87         gdbusmethodinvocation.h         gdbusmethodinvocation.c         \
88         gdbusserver.h                   gdbusserver.c                   \
89         gdbusinterface.h                gdbusinterface.c                \
90         gdbusinterfaceskeleton.h        gdbusinterfaceskeleton.c        \
91         gdbusobject.h                   gdbusobject.c                   \
92         gdbusobjectskeleton.h           gdbusobjectskeleton.c           \
93         gdbusobjectproxy.h              gdbusobjectproxy.c              \
94         gdbusobjectmanager.h            gdbusobjectmanager.c            \
95         gdbusobjectmanagerclient.h      gdbusobjectmanagerclient.c      \
96         gdbusobjectmanagerserver.h      gdbusobjectmanagerserver.c      \
97         $(NULL)
98
99 settings_headers = \
100         gsettingsbackend.h              \
101         gsettingsschema.h               \
102         gsettings.h
103
104 settings_sources = \
105         gvdb/gvdb-format.h              \
106         gvdb/gvdb-reader.h              \
107         gvdb/gvdb-reader.c              \
108         gdelayedsettingsbackend.h       \
109         gdelayedsettingsbackend.c       \
110         gkeyfilesettingsbackend.c       \
111         gmemorysettingsbackend.c        \
112         gnullsettingsbackend.c          \
113         gsettingsbackendinternal.h      \
114         gsettingsbackend.c              \
115         gsettingsschema.h               \
116         gsettingsschema-internal.h      \
117         gsettingsschema.c               \
118         gsettings-mapping.h             \
119         gsettings-mapping.c             \
120         gsettings.c
121
122 if OS_WIN32
123 settings_sources += \
124         gregistrysettingsbackend.h      \
125         gregistrysettingsbackend.c
126 endif
127
128 if OS_COCOA
129 settings_sources += \
130         gnextstepsettingsbackend.c
131 endif
132
133 application_headers = \
134         gapplication.h                  \
135         gapplicationcommandline.h       \
136                                         \
137         gactiongroup.h                  \
138         gactionmap.h                    \
139         gsimpleactiongroup.h            \
140         gremoteactiongroup.h            \
141         gactiongroupexporter.h          \
142         gdbusactiongroup.h              \
143         gaction.h                       \
144         gsimpleaction.h                 \
145                                         \
146         gmenumodel.h                    \
147         gmenu.h                         \
148         gmenuexporter.h                 \
149         gdbusmenumodel.h                \
150         $(NULL)
151
152 application_sources = \
153         gapplication.c                          \
154         gapplicationcommandline.c               \
155         gapplicationimpl-dbus.c                 \
156         gapplicationimpl.h                      \
157                                                 \
158         gactiongroup.c                          \
159         gactionmap.c                            \
160         gsimpleactiongroup.c                    \
161         gremoteactiongroup.c                    \
162         gactiongroupexporter.c                  \
163         gdbusactiongroup.c                      \
164         gaction.c                               \
165         gsimpleaction.c                         \
166                                                 \
167         gmenumodel.c                            \
168         gmenu.c                                 \
169         gmenuexporter.c                         \
170         gdbusmenumodel.c                        \
171         $(NULL)
172
173 local_sources = \
174         glocaldirectorymonitor.c        \
175         glocaldirectorymonitor.h        \
176         glocalfile.c                    \
177         glocalfile.h                    \
178         glocalfileenumerator.c          \
179         glocalfileenumerator.h          \
180         glocalfileinfo.c                \
181         glocalfileinfo.h                \
182         glocalfileinputstream.c         \
183         glocalfileinputstream.h         \
184         glocalfilemonitor.c             \
185         glocalfilemonitor.h             \
186         glocalfileoutputstream.c        \
187         glocalfileoutputstream.h        \
188         glocalfileiostream.c            \
189         glocalfileiostream.h            \
190         glocalvfs.c                     \
191         glocalvfs.h                     \
192         gsocks4proxy.c                  \
193         gsocks4proxy.h                  \
194         gsocks4aproxy.c                 \
195         gsocks4aproxy.h                 \
196         gsocks5proxy.c                  \
197         gsocks5proxy.h                  \
198         $(NULL)
199
200 platform_libadd =
201 platform_deps =
202 appinfo_sources =
203
204 if HAVE_INOTIFY
205 SUBDIRS += inotify
206 platform_libadd += inotify/libinotify.la
207 platform_deps += inotify/libinotify.la
208 endif
209
210 if HAVE_FEN
211 AM_CPPFLAGS += -DHAVE_FEN
212 SUBDIRS += fen
213 platform_libadd += fen/libfen.la
214 platform_deps += fen/libfen.la
215 endif
216
217 if OS_WIN32
218 SUBDIRS += win32
219 platform_libadd += win32/libgiowin32.la
220 platform_deps += win32/libgiowin32.la
221 endif
222
223 SUBDIRS += .
224
225 if HAVE_FAM
226 SUBDIRS += fam
227 endif
228
229 if OS_UNIX
230 appinfo_sources += gdesktopappinfo.c
231 platform_libadd += xdgmime/libxdgmime.la $(RESOLVER_LIBADD)
232 platform_deps += xdgmime/libxdgmime.la
233 unix_sources = \
234         gfiledescriptorbased.c  \
235         gunixconnection.c       \
236         gunixcredentialsmessage.c       \
237         gunixfdlist.c           \
238         gunixfdmessage.c        \
239         gunixmount.c            \
240         gunixmount.h            \
241         gunixmounts.c           \
242         gunixsocketaddress.c    \
243         gunixvolume.c           \
244         gunixvolume.h           \
245         gunixvolumemonitor.c    \
246         gunixvolumemonitor.h    \
247         gunixinputstream.c      \
248         gunixoutputstream.c     \
249         $(NULL)
250
251
252 giounixincludedir=$(includedir)/gio-unix-2.0/gio
253 giounixinclude_HEADERS = \
254         gdesktopappinfo.h       \
255         gfiledescriptorbased.h  \
256         gunixconnection.h       \
257         gunixcredentialsmessage.h       \
258         gunixmounts.h           \
259         gunixfdlist.h           \
260         gunixfdmessage.h        \
261         gunixinputstream.h      \
262         gunixoutputstream.h     \
263         gunixsocketaddress.h    \
264         $(NULL)
265
266 if HAVE_NETLINK
267 unix_sources +=                  \
268         gnetworkmonitornetlink.c \
269         gnetworkmonitornetlink.h \
270         $(NULL)
271 endif
272 endif
273
274 win32_actual_sources = \
275         gwin32mount.c \
276         gwin32mount.h \
277         gwin32volumemonitor.c \
278         gwin32volumemonitor.h \
279         gwin32inputstream.c \
280         gwin32outputstream.c \
281         gwin32outputstream.h \
282         $(NULL)
283
284 win32_more_sources_for_vcproj = \
285         gwin32appinfo.c \
286         gregistrysettingsbackend.c \
287         win32/gwin32directorymonitor.c \
288         win32/gwinhttpfile.c \
289         win32/gwinhttpfileinputstream.c \
290         win32/gwinhttpfileoutputstream.c \
291         win32/gwinhttpvfs.c
292
293 if OS_WIN32
294 appinfo_sources += gwin32appinfo.c gwin32appinfo.h
295 platform_libadd += -lshlwapi -lws2_32 -ldnsapi
296 win32_sources = $(win32_actual_sources)
297
298 giowin32includedir=$(includedir)/gio-win32-2.0/gio
299 giowin32include_HEADERS = \
300         gwin32inputstream.h \
301         gwin32outputstream.h \
302         $(NULL)
303
304 endif
305
306 if BUILD_MODULAR_TESTS
307 SUBDIRS += tests 
308 else
309 DIST_SUBDIRS += tests
310 endif
311
312 libgio_2_0_la_SOURCES =         \
313         gappinfo.c              \
314         gasynchelper.c          \
315         gasynchelper.h          \
316         gasyncinitable.c        \
317         gasyncresult.c          \
318         gbufferedinputstream.c  \
319         gbufferedoutputstream.c \
320         gcancellable.c          \
321         gcontenttype.c          \
322         gcontenttypeprivate.h   \
323         gcharsetconverter.c     \
324         gconverter.c            \
325         gconverterinputstream.c \
326         gconverteroutputstream.c        \
327         gcredentials.c          \
328         gdatainputstream.c      \
329         gdataoutputstream.c     \
330         gdrive.c                \
331         gdummyfile.h            \
332         gdummyfile.c            \
333         gdummyproxyresolver.c   \
334         gdummyproxyresolver.h   \
335         gdummytlsbackend.c      \
336         gdummytlsbackend.h      \
337         gemblem.h               \
338         gemblem.c               \
339         gemblemedicon.h         \
340         gemblemedicon.c         \
341         gfile.c                 \
342         gfileattribute.c        \
343         gfileattribute-priv.h   \
344         gfileenumerator.c       \
345         gfileicon.c             \
346         gfileinfo.c             \
347         gfileinfo-priv.h        \
348         gfileinputstream.c      \
349         gfilemonitor.c          \
350         gfilenamecompleter.c    \
351         gfileoutputstream.c     \
352         gfileiostream.c         \
353         gfilterinputstream.c    \
354         gfilteroutputstream.c   \
355         gicon.c                 \
356         ginetaddress.c          \
357         ginetaddressmask.c      \
358         ginetsocketaddress.c    \
359         ginitable.c             \
360         ginputstream.c          \
361         gioenums.h              \
362         gioerror.c              \
363         giomodule.c             \
364         giomodule-priv.h        \
365         gioscheduler.c          \
366         giostream.c             \
367         gloadableicon.c         \
368         gmount.c                \
369         gmemoryinputstream.c    \
370         gmemoryoutputstream.c   \
371         gmountoperation.c       \
372         gnativevolumemonitor.c  \
373         gnativevolumemonitor.h  \
374         gnetworkaddress.c       \
375         gnetworkingprivate.h    \
376         gnetworkmonitor.c       \
377         gnetworkmonitorbase.c   \
378         gnetworkmonitorbase.h   \
379         gnetworkservice.c       \
380         goutputstream.c         \
381         gpermission.c           \
382         gpollableinputstream.c  \
383         gpollableoutputstream.c \
384         gpollfilemonitor.c      \
385         gpollfilemonitor.h      \
386         gproxyresolver.c        \
387         gresolver.c             \
388         gresource.c             \
389         gresourcefile.c         \
390         gresourcefile.h         \
391         gseekable.c             \
392         gsimpleasyncresult.c    \
393         gsimplepermission.c     \
394         gsocket.c               \
395         gsocketaddress.c        \
396         gsocketaddressenumerator.c \
397         gsocketclient.c         \
398         gsocketconnectable.c    \
399         gsocketconnection.c     \
400         gsocketcontrolmessage.c \
401         gsocketinputstream.c    \
402         gsocketinputstream.h    \
403         gsocketlistener.c       \
404         gsocketoutputstream.c   \
405         gsocketoutputstream.h   \
406         gproxy.c                \
407         gproxyaddress.c         \
408         gproxyaddressenumerator.c \
409         gsocketservice.c        \
410         gsrvtarget.c            \
411         gtcpconnection.c        \
412         gtcpwrapperconnection.c \
413         gthreadedsocketservice.c\
414         gthemedicon.c           \
415         gthreadedresolver.c     \
416         gthreadedresolver.h     \
417         gtlsbackend.c           \
418         gtlscertificate.c       \
419         gtlsclientconnection.c  \
420         gtlsconnection.c        \
421         gtlsdatabase.c          \
422         gtlsfiledatabase.c      \
423         gtlsinteraction.c       \
424         gtlspassword.c          \
425         gtlsserverconnection.c  \
426         gunionvolumemonitor.c   \
427         gunionvolumemonitor.h   \
428         gvfs.c                  \
429         gvolume.c               \
430         gvolumemonitor.c        \
431         gzlibcompressor.c       \
432         gzlibdecompressor.c     \
433         gmountprivate.h         \
434         gioenumtypes.h          \
435         gioenumtypes.c          \
436         $(appinfo_sources)      \
437         $(unix_sources)         \
438         $(win32_sources)        \
439         $(application_sources)  \
440         $(settings_sources)     \
441         $(gdbus_sources)        \
442         $(local_sources)        \
443         $(NULL)
444
445 EXTRA_DIST += strinfo.c
446
447 libgio_2_0_la_LIBADD = \
448         $(top_builddir)/glib/libglib-2.0.la             \
449         $(top_builddir)/gobject/libgobject-2.0.la       \
450         $(top_builddir)/gmodule/libgmodule-2.0.la       \
451         $(platform_libadd)                              \
452         $(ZLIB_LIBS)                                    \
453         $(SELINUX_LIBS)                                 \
454         $(GLIB_LIBS)                                    \
455         $(XATTR_LIBS)                                   \
456         $(NETWORK_LIBS)                                 \
457         $(NULL)
458
459 libgio_2_0_la_CPPFLAGS = $(ZLIB_CFLAGS) $(AM_CPPFLAGS)
460
461 if PLATFORM_WIN32
462 no_undefined = -no-undefined
463 endif
464
465 if OS_WIN32_AND_DLL_COMPILATION
466 export_symbols = -export-symbols $(builddir)/gio.def
467 gio_def = gio.def
468
469 gio_win32_res = gio-win32-res.o
470 gio_win32_res_ldflag = -Wl,$(gio_win32_res)
471
472 install-def-file:
473         $(INSTALL) $(builddir)/gio.def $(DESTDIR)$(libdir)/gio-2.0.def
474
475 uninstall-def-file:
476         -rm $(DESTDIR)$(libdir)/gio-2.0.def
477 else
478 install-def-file:
479 uninstall-def-file:
480
481 export_symbols = $(LIBTOOL_EXPORT_OPTIONS)
482 endif
483
484 install-data-local: install-ms-lib install-def-file
485         $(mkinstalldirs) $(DESTDIR)$(GIO_MODULE_DIR)
486
487 uninstall-local: uninstall-ms-lib uninstall-def-file
488
489 libgio_2_0_la_LDFLAGS = $(GLIB_LINK_FLAGS) \
490         $(gio_win32_res_ldflag) \
491         -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
492         -export-dynamic $(no_undefined) $(export_symbols)
493
494 if OS_COCOA
495 # This is dumb.  The ObjC source file should be properly named .m
496 libgio_2_0_la_CFLAGS = -xobjective-c
497 libgio_2_0_la_LDFLAGS += -framework Foundation
498 endif
499
500 libgio_2_0_la_DEPENDENCIES = $(gio_win32_res) $(gio_def) $(platform_deps)
501
502 gio-win32-res.o: gio.rc
503         $(WINDRES) gio.rc $@
504
505 gio_headers =                   \
506         gappinfo.h              \
507         gasyncinitable.h        \
508         gasyncresult.h          \
509         gbufferedinputstream.h  \
510         gbufferedoutputstream.h \
511         gcancellable.h          \
512         gcontenttype.h          \
513         gcharsetconverter.h     \
514         gconverter.h            \
515         gconverterinputstream.h \
516         gconverteroutputstream.h        \
517         gdatainputstream.h      \
518         gdataoutputstream.h     \
519         gdrive.h                \
520         gemblem.h               \
521         gemblemedicon.h         \
522         gfile.h                 \
523         gfileattribute.h        \
524         gfileenumerator.h       \
525         gfileicon.h             \
526         gfileinfo.h             \
527         gfileinputstream.h      \
528         gfilemonitor.h          \
529         gfilenamecompleter.h    \
530         gfileoutputstream.h     \
531         gfileiostream.h         \
532         gfilterinputstream.h    \
533         gfilteroutputstream.h   \
534         gicon.h                 \
535         ginetaddress.h          \
536         ginetaddressmask.h      \
537         ginetsocketaddress.h    \
538         ginputstream.h          \
539         ginitable.h             \
540         gio.h                   \
541         giotypes.h              \
542         gioenums.h              \
543         gioerror.h              \
544         giomodule.h             \
545         gioscheduler.h          \
546         giostream.h             \
547         gloadableicon.h         \
548         gmount.h                \
549         gmemoryinputstream.h    \
550         gmemoryoutputstream.h   \
551         gmountoperation.h       \
552         gnativevolumemonitor.h  \
553         gnetworkaddress.h       \
554         gnetworkmonitor.h       \
555         gnetworkservice.h       \
556         goutputstream.h         \
557         gpermission.h           \
558         gpollableinputstream.h  \
559         gpollableoutputstream.h \
560         gproxyaddress.h         \
561         gproxy.h                \
562         gproxyaddressenumerator.h \
563         gproxyresolver.h        \
564         gresolver.h             \
565         gresource.h             \
566         gseekable.h             \
567         gsimpleasyncresult.h    \
568         gsimplepermission.h     \
569         gsocket.h               \
570         gsocketaddress.h        \
571         gsocketaddressenumerator.h \
572         gsocketclient.h         \
573         gsocketconnectable.h    \
574         gsocketconnection.h     \
575         gsocketcontrolmessage.h \
576         gsocketlistener.h       \
577         gsocketservice.h        \
578         gsrvtarget.h            \
579         gtcpconnection.h        \
580         gtcpwrapperconnection.h \
581         gthreadedsocketservice.h\
582         gthemedicon.h           \
583         gtlsbackend.h           \
584         gtlscertificate.h       \
585         gtlsclientconnection.h  \
586         gtlsconnection.h        \
587         gtlsdatabase.h          \
588         gtlsfiledatabase.h      \
589         gtlsinteraction.h       \
590         gtlspassword.h          \
591         gtlsserverconnection.h  \
592         gvfs.h                  \
593         gvolume.h               \
594         gvolumemonitor.h        \
595         gzlibcompressor.h       \
596         gzlibdecompressor.h     \
597         $(application_headers)  \
598         $(settings_headers)     \
599         $(gdbus_headers)        \
600         $(NULL)
601
602 gioincludedir=$(includedir)/glib-2.0/gio/
603 gioinclude_HEADERS =            \
604         $(gio_headers)          \
605         gioenumtypes.h
606
607 # these sources (also mentioned above) are generated.
608 BUILT_SOURCES =                 \
609         gconstructor_as_data.h  \
610         gioenumtypes.h          \
611         gioenumtypes.c          \
612         $(NULL)
613
614 EXTRA_DIST +=                   \
615         data-to-c.pl            \
616         gio.symbols             \
617         gioenumtypes.h.template \
618         gioenumtypes.c.template \
619         makefile.msc            \
620         abicheck.sh             \
621         gio.rc.in               \
622         gschema.dtd             \
623         gconstructor_as_data.h  \
624         $(NULL)
625
626 BUILT_EXTRA_DIST =              \
627         gio.rc
628
629 # This is read by gobject-introspection/misc/ and gtk-doc
630 gio-public-headers.txt: Makefile
631         echo $(gioinclude_HEADERS) $(giowin32include_HEADERS) $(giounixinclude_HEADERS) > $@.tmp && mv $@.tmp $@
632
633 CLEANFILES = gio-public-headers.txt gconstructor_as_data.h
634
635 all-local: gio-public-headers.txt
636
637 gioenumtypes.h: $(gio_headers) gioenumtypes.h.template
638         $(AM_V_GEN) ( top_builddir=`cd $(top_builddir) && pwd`; \
639           cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.h.template $(gio_headers) ) > \
640             gioenumtypes.h.tmp && mv gioenumtypes.h.tmp gioenumtypes.h
641
642 gioenumtypes.c: $(gio_headers) gioenumtypes.c.template
643         $(AM_V_GEN) ( top_builddir=`cd $(top_builddir) && pwd`; \
644           cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.c.template $(gio_headers) ) > \
645             gioenumtypes.c.tmp && mv gioenumtypes.c.tmp gioenumtypes.c
646
647 gio-2.0.lib: libgio-2.0.la gio.def
648         lib -machine:@LIB_EXE_MACHINE_FLAG@ -name:libgio-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:$(builddir)/gio.def -out:$@
649
650 bin_PROGRAMS = gio-querymodules glib-compile-schemas glib-compile-resources gsettings
651
652 glib_compile_resources_LDADD = \
653         $(top_builddir)/glib/libglib-2.0.la \
654         $(top_builddir)/gobject/libgobject-2.0.la       \
655         libgio-2.0.la
656
657 glib_compile_resources_SOURCES = \
658         gvdb/gvdb-format.h              \
659         gvdb/gvdb-builder.h             \
660         gvdb/gvdb-builder.c             \
661         glib-compile-resources.c
662
663 gio_querymodules_SOURCES = gio-querymodules.c
664 gio_querymodules_LDADD   = \
665         $(top_builddir)/glib/libglib-2.0.la             \
666         $(top_builddir)/gobject/libgobject-2.0.la       \
667         $(top_builddir)/gmodule/libgmodule-2.0.la       \
668         libgio-2.0.la                                   \
669         $(NULL)
670
671 gconstructor_as_data.h: $(top_srcdir)/glib/gconstructor.h data-to-c.pl
672         $(AM_V_GEN) $(srcdir)/data-to-c.pl $(top_srcdir)/glib/gconstructor.h gconstructor_code > $@.tmp && mv $@.tmp $@
673
674 glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
675 glib_compile_schemas_SOURCES = \
676         gconstructor_as_data.h \
677         gvdb/gvdb-format.h              \
678         gvdb/gvdb-builder.h             \
679         gvdb/gvdb-builder.c             \
680         glib-compile-schemas.c
681
682 gsettings_LDADD = \
683         $(top_builddir)/glib/libglib-2.0.la             \
684         $(top_builddir)/gobject/libgobject-2.0.la       \
685         libgio-2.0.la
686 gsettings_SOURCES = gsettings-tool.c
687
688 schemadir = $(datadir)/glib-2.0/schemas
689 dist_schema_DATA = gschema.dtd
690
691 # ------------------------------------------------------------------------
692 # gdbus(1) tool
693
694 bin_PROGRAMS += gdbus
695 gdbus_SOURCES = gdbus-tool.c
696 gdbus_LDADD = libgio-2.0.la \
697         $(top_builddir)/glib/libglib-2.0.la             \
698         $(top_builddir)/gobject/libgobject-2.0.la
699
700 completiondir = $(sysconfdir)/bash_completion.d
701 completion_DATA = \
702         gdbus-bash-completion.sh                \
703         gsettings-bash-completion.sh            \
704         gresource-bash-completion.sh
705 EXTRA_DIST += $(completion_DATA)
706
707 # ------------------------------------------------------------------------
708 # gresource tool
709
710 bin_PROGRAMS += gresource
711 gresource_SOURCES = gresource-tool.c
712 gresource_CPPFLAGS = $(LIBELF_CFLAGS) $(AM_CPPFLAGS)
713 gresource_LDADD = libgio-2.0.la \
714         $(top_builddir)/glib/libglib-2.0.la             \
715         $(top_builddir)/gobject/libgobject-2.0.la \
716         $(LIBELF_LIBS)
717
718 # ------------------------------------------------------------------------
719
720 dist-hook: $(BUILT_EXTRA_DIST) ../build/win32/vs9/gio.vcproj ../build/win32/vs10/gio.vcxproj ../build/win32/vs10/gio.vcxproj.filters
721         files='$(BUILT_EXTRA_DIST)'; \
722         for f in $$files; do \
723           if test -f $$f; then d=.; else d=$(srcdir); fi; \
724           cp $$d/$$f $(distdir) || exit 1; done
725
726 ../build/win32/vs9/gio.vcproj: $(top_srcdir)/build/win32/vs9/gio.vcprojin
727         for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
728                 case $$F in \
729                 gunix*.c|gdesktopappinfo.c|gnetworkmonitornetlink.c) ;; \
730                 *.c) echo '   <File RelativePath="..\..\..\gio\'$$F'" />' \
731                      ;; \
732                 esac; \
733         done | sort -u >libgio.sourcefiles
734         $(CPP) -P - <$(top_srcdir)/build/win32/vs9/gio.vcprojin >$@
735         rm libgio.sourcefiles
736
737 ../build/win32/vs10/gio.vcxproj: $(top_srcdir)/build/win32/vs10/gio.vcxprojin
738         for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
739                 case $$F in \
740                 gunix*.c|gdesktopappinfo.c|gnetworkmonitornetlink.c) ;; \
741                 *.c) echo '    <ClCompile Include="..\..\..\gio\'$$F'" />' \
742                      ;; \
743                 esac; \
744         done | sort -u >libgio.vs10.sourcefiles
745         $(CPP) -P - <$(top_srcdir)/build/win32/vs10/gio.vcxprojin >$@
746         rm libgio.vs10.sourcefiles
747
748 ../build/win32/vs10/gio.vcxproj.filters: $(top_srcdir)/build/win32/vs10/gio.vcxproj.filtersin
749         for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
750                 case $$F in \
751                 gunix*.c|gdesktopappinfo.c|gnetworkmonitornetlink.c) ;; \
752                 *.c) echo '    <ClCompile Include="..\..\..\gio\'$$F'"><Filter>Source Files</Filter></ClCompile>' \
753                      ;; \
754                 esac; \
755         done | sort -u >libgio.vs10.sourcefiles.filters
756         $(CPP) -P - <$(top_srcdir)/build/win32/vs10/gio.vcxproj.filtersin >$@
757         rm libgio.vs10.sourcefiles.filters
758
759 if HAVE_GLIB_RUNTIME_LIBDIR
760 install-data-hook:
761         mkdir -p $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
762         mv $(DESTDIR)$(libdir)/libgio-2.0.so.0 $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
763         mv $(DESTDIR)$(libdir)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
764         rm -f $(DESTDIR)$(libdir)/libgio-2.0.so
765         ln -s $(GLIB_RUNTIME_LIBDIR)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/libgio-2.0.so
766 endif