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