gio: Add private API to create win32 streams from fds
[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         giowin32-priv.h         \
387         gloadableicon.c         \
388         gmount.c                \
389         gmemoryinputstream.c    \
390         gmemoryoutputstream.c   \
391         gmountoperation.c       \
392         gnativevolumemonitor.c  \
393         gnativevolumemonitor.h  \
394         gnetworkaddress.c       \
395         gnetworking.c           \
396         gnetworkingprivate.h    \
397         gnetworkmonitor.c       \
398         gnetworkmonitorbase.c   \
399         gnetworkmonitorbase.h   \
400         gnetworkservice.c       \
401         goutputstream.c         \
402         gpermission.c           \
403         gpollableinputstream.c  \
404         gpollableoutputstream.c \
405         gpollableutils.c        \
406         gpollfilemonitor.c      \
407         gpollfilemonitor.h      \
408         gproxy.c                \
409         gproxyaddress.c         \
410         gproxyaddressenumerator.c \
411         gproxyresolver.c        \
412         gresolver.c             \
413         gresource.c             \
414         gresourcefile.c         \
415         gresourcefile.h         \
416         gseekable.c             \
417         gsimpleasyncresult.c    \
418         gsimplepermission.c     \
419         gsocket.c               \
420         gsocketaddress.c        \
421         gsocketaddressenumerator.c \
422         gsocketclient.c         \
423         gsocketconnectable.c    \
424         gsocketconnection.c     \
425         gsocketcontrolmessage.c \
426         gsocketinputstream.c    \
427         gsocketinputstream.h    \
428         gsocketlistener.c       \
429         gsocketoutputstream.c   \
430         gsocketoutputstream.h   \
431         gsocketservice.c        \
432         gsrvtarget.c            \
433         gsimpleproxyresolver.c  \
434         gtask.c                 \
435         gtcpconnection.c        \
436         gtcpwrapperconnection.c \
437         gthreadedsocketservice.c\
438         gthemedicon.c           \
439         gthreadedresolver.c     \
440         gthreadedresolver.h     \
441         gtlsbackend.c           \
442         gtlscertificate.c       \
443         gtlsclientconnection.c  \
444         gtlsconnection.c        \
445         gtlsdatabase.c          \
446         gtlsfiledatabase.c      \
447         gtlsinteraction.c       \
448         gtlspassword.c          \
449         gtlsserverconnection.c  \
450         gunionvolumemonitor.c   \
451         gunionvolumemonitor.h   \
452         gvfs.c                  \
453         gvolume.c               \
454         gvolumemonitor.c        \
455         gzlibcompressor.c       \
456         gzlibdecompressor.c     \
457         gmountprivate.h         \
458         gioenumtypes.h          \
459         gioenumtypes.c          \
460         $(appinfo_sources)      \
461         $(unix_sources)         \
462         $(win32_sources)        \
463         $(application_sources)  \
464         $(settings_sources)     \
465         $(gdbus_sources)        \
466         $(local_sources)        \
467         $(NULL)
468
469 EXTRA_DIST += strinfo.c
470
471 libgio_2_0_la_LIBADD = \
472         $(top_builddir)/glib/libglib-2.0.la             \
473         $(top_builddir)/gobject/libgobject-2.0.la       \
474         $(top_builddir)/gmodule/libgmodule-2.0.la       \
475         $(platform_libadd)                              \
476         $(ZLIB_LIBS)                                    \
477         $(SELINUX_LIBS)                                 \
478         $(GLIB_LIBS)                                    \
479         $(XATTR_LIBS)                                   \
480         $(NETWORK_LIBS)                                 \
481         $(NULL)
482
483 libgio_2_0_la_CPPFLAGS = $(ZLIB_CFLAGS) $(AM_CPPFLAGS)
484
485 if PLATFORM_WIN32
486 no_undefined = -no-undefined
487 endif
488
489 if OS_WIN32_AND_DLL_COMPILATION
490 gio_win32_res = gio-win32-res.o
491 gio_win32_res_ldflag = -Wl,$(gio_win32_res)
492 endif
493
494 install-data-local: install-ms-lib
495         $(mkinstalldirs) $(DESTDIR)$(GIO_MODULE_DIR)
496
497 uninstall-local: uninstall-ms-lib
498
499 libgio_2_0_la_CFLAGS = $(AM_CFLAGS) $(GLIB_HIDDEN_VISIBILITY_CFLAGS)
500 libgio_2_0_la_LDFLAGS = $(GLIB_LINK_FLAGS) \
501         $(gio_win32_res_ldflag) \
502         -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
503         -export-dynamic $(no_undefined)
504
505 if OS_COCOA
506 # This is dumb.  The ObjC source file should be properly named .m
507 libgio_2_0_la_CFLAGS += -xobjective-c
508 libgio_2_0_la_LDFLAGS += -Wl,-framework,Foundation
509 endif
510
511 libgio_2_0_la_DEPENDENCIES = $(gio_win32_res) $(gio_def) $(platform_deps)
512
513 gio-win32-res.o: gio.rc
514         $(WINDRES) gio.rc $@
515
516 gio_headers =                   \
517         gappinfo.h              \
518         gasyncinitable.h        \
519         gasyncresult.h          \
520         gbufferedinputstream.h  \
521         gbufferedoutputstream.h \
522         gbytesicon.h            \
523         gcancellable.h          \
524         gcontenttype.h          \
525         gcharsetconverter.h     \
526         gconverter.h            \
527         gconverterinputstream.h \
528         gconverteroutputstream.h        \
529         gdatainputstream.h      \
530         gdataoutputstream.h     \
531         gdrive.h                \
532         gemblem.h               \
533         gemblemedicon.h         \
534         gfile.h                 \
535         gfileattribute.h        \
536         gfileenumerator.h       \
537         gfileicon.h             \
538         gfileinfo.h             \
539         gfileinputstream.h      \
540         gfilemonitor.h          \
541         gfilenamecompleter.h    \
542         gfileoutputstream.h     \
543         gfileiostream.h         \
544         gfilterinputstream.h    \
545         gfilteroutputstream.h   \
546         gicon.h                 \
547         ginetaddress.h          \
548         ginetaddressmask.h      \
549         ginetsocketaddress.h    \
550         ginputstream.h          \
551         ginitable.h             \
552         gio.h                   \
553         giotypes.h              \
554         gioenums.h              \
555         gioerror.h              \
556         giomodule.h             \
557         gioscheduler.h          \
558         giostream.h             \
559         gloadableicon.h         \
560         gmount.h                \
561         gmemoryinputstream.h    \
562         gmemoryoutputstream.h   \
563         gmountoperation.h       \
564         gnativevolumemonitor.h  \
565         gnetworkaddress.h       \
566         gnetworkmonitor.h       \
567         gnetworkservice.h       \
568         goutputstream.h         \
569         gpermission.h           \
570         gpollableinputstream.h  \
571         gpollableoutputstream.h \
572         gpollableutils.h        \
573         gproxyaddress.h         \
574         gproxy.h                \
575         gproxyaddressenumerator.h \
576         gproxyresolver.h        \
577         gresolver.h             \
578         gresource.h             \
579         gseekable.h             \
580         gsimpleasyncresult.h    \
581         gsimplepermission.h     \
582         gsocket.h               \
583         gsocketaddress.h        \
584         gsocketaddressenumerator.h \
585         gsocketclient.h         \
586         gsocketconnectable.h    \
587         gsocketconnection.h     \
588         gsocketcontrolmessage.h \
589         gsocketlistener.h       \
590         gsocketservice.h        \
591         gsrvtarget.h            \
592         gsimpleproxyresolver.h  \
593         gtask.h                 \
594         gtcpconnection.h        \
595         gtcpwrapperconnection.h \
596         gthreadedsocketservice.h\
597         gthemedicon.h           \
598         gtlsbackend.h           \
599         gtlscertificate.h       \
600         gtlsclientconnection.h  \
601         gtlsconnection.h        \
602         gtlsdatabase.h          \
603         gtlsfiledatabase.h      \
604         gtlsinteraction.h       \
605         gtlspassword.h          \
606         gtlsserverconnection.h  \
607         gvfs.h                  \
608         gvolume.h               \
609         gvolumemonitor.h        \
610         gzlibcompressor.h       \
611         gzlibdecompressor.h     \
612         $(application_headers)  \
613         $(settings_headers)     \
614         $(gdbus_headers)        \
615         $(NULL)
616
617 gioincludedir=$(includedir)/glib-2.0/gio/
618 gioinclude_HEADERS =            \
619         $(gio_headers)          \
620         gioenumtypes.h
621
622 nodist_gioinclude_HEADERS =     \
623         gnetworking.h           \
624         $(NULL)
625
626 # these sources (also mentioned above) are generated.
627 BUILT_SOURCES +=                \
628         gconstructor_as_data.h  \
629         gioenumtypes.h          \
630         gioenumtypes.c          \
631         gdbus-daemon-generated.c \
632         gdbus-daemon-generated.h \
633         gnetworking.h           \
634         $(NULL)
635
636 EXTRA_DIST +=                   \
637         data-to-c.pl            \
638         gioenumtypes.h.template \
639         gioenumtypes.c.template \
640         makefile.msc            \
641         gio.rc.in               \
642         gschema.dtd             \
643         gconstructor_as_data.h  \
644         gnetworking.h.win32     \
645         $(NULL)
646
647 BUILT_EXTRA_DIST +=             \
648         gio.rc
649
650 # This is read by gobject-introspection/misc/ and gtk-doc
651 gio-public-headers.txt: Makefile
652         $(AM_V_GEN) echo $(gioinclude_HEADERS) $(giowin32include_HEADERS) $(giounixinclude_HEADERS) > $@.tmp && mv $@.tmp $@
653
654 CLEANFILES += gdbus-daemon-generated.c gdbus-daemon-generated.h gio-public-headers.txt gconstructor_as_data.h
655
656
657 DISTCLEANFILES +=               \
658         gioenumtypes.h          \
659         gioenumtypes.c
660
661 all-local: gio-public-headers.txt
662
663 gioenumtypes.h: $(gio_headers) gioenumtypes.h.template
664         $(AM_V_GEN) $(top_builddir)/gobject/glib-mkenums --template $(filter %.template,$^) $(filter-out %.template,$^) > \
665             gioenumtypes.h.tmp && mv gioenumtypes.h.tmp gioenumtypes.h
666
667 gioenumtypes.c: $(gio_headers) gioenumtypes.c.template
668         $(AM_V_GEN) $(top_builddir)/gobject/glib-mkenums --template $(filter %.template,$^) $(filter-out %.template,$^) > \
669             gioenumtypes.c.tmp && mv gioenumtypes.c.tmp gioenumtypes.c
670
671 gio-2.0.lib: libgio-2.0.la gio.def
672         lib -machine:@LIB_EXE_MACHINE_FLAG@ -name:libgio-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:$(builddir)/gio.def -out:$@
673
674 bin_PROGRAMS = gio-querymodules glib-compile-schemas glib-compile-resources gsettings
675
676 glib_compile_resources_LDADD = \
677         $(top_builddir)/glib/libglib-2.0.la \
678         $(top_builddir)/gobject/libgobject-2.0.la       \
679         libgio-2.0.la
680
681 glib_compile_resources_SOURCES = \
682         gvdb/gvdb-format.h              \
683         gvdb/gvdb-builder.h             \
684         gvdb/gvdb-builder.c             \
685         glib-compile-resources.c
686
687 gio_querymodules_SOURCES = gio-querymodules.c
688 gio_querymodules_LDADD   = \
689         $(top_builddir)/glib/libglib-2.0.la             \
690         $(top_builddir)/gobject/libgobject-2.0.la       \
691         $(top_builddir)/gmodule/libgmodule-2.0.la       \
692         libgio-2.0.la                                   \
693         $(NULL)
694
695 gconstructor_as_data.h: $(top_srcdir)/glib/gconstructor.h data-to-c.pl
696         $(AM_V_GEN) $(srcdir)/data-to-c.pl $(top_srcdir)/glib/gconstructor.h gconstructor_code > $@.tmp && mv $@.tmp $@
697
698 glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
699 glib_compile_schemas_SOURCES = \
700         gconstructor_as_data.h \
701         gvdb/gvdb-format.h              \
702         gvdb/gvdb-builder.h             \
703         gvdb/gvdb-builder.c             \
704         glib-compile-schemas.c
705
706 gsettings_LDADD = \
707         $(top_builddir)/glib/libglib-2.0.la             \
708         $(top_builddir)/gobject/libgobject-2.0.la       \
709         libgio-2.0.la
710 gsettings_SOURCES = gsettings-tool.c
711
712 schemadir = $(datadir)/glib-2.0/schemas
713 dist_schema_DATA = gschema.dtd
714
715 # ------------------------------------------------------------------------
716 # gdbus(1) tool
717
718 bin_PROGRAMS += gdbus
719 gdbus_SOURCES = gdbus-tool.c
720 gdbus_LDADD = libgio-2.0.la \
721         $(top_builddir)/glib/libglib-2.0.la             \
722         $(top_builddir)/gobject/libgobject-2.0.la
723
724 # ------------------------------------------------------------------------
725 # gapplication(1) tool
726 bin_PROGRAMS += gapplication
727 gapplication_SOURCES = gapplication-tool.c
728 gapplication_LDADD = libgio-2.0.la \
729         $(top_builddir)/glib/libglib-2.0.la             \
730         $(top_builddir)/gobject/libgobject-2.0.la
731
732 completiondir = $(datadir)/bash-completion/completions
733 completion_DATA = \
734         completion/gapplication                         \
735         completion/gdbus                                \
736         completion/gsettings                            \
737         completion/gresource
738 EXTRA_DIST += $(completion_DATA)
739
740 # ------------------------------------------------------------------------
741 # gresource tool
742
743 bin_PROGRAMS += gresource
744 gresource_SOURCES = gresource-tool.c
745 gresource_CPPFLAGS = $(LIBELF_CFLAGS) $(AM_CPPFLAGS)
746 gresource_LDADD = libgio-2.0.la \
747         $(top_builddir)/glib/libglib-2.0.la             \
748         $(top_builddir)/gobject/libgobject-2.0.la \
749         $(LIBELF_LIBS)
750
751 # ------------------------------------------------------------------------
752
753 dist-hook: $(BUILT_EXTRA_DIST) ../build/win32/vs9/gio.vcproj ../build/win32/vs10/gio.vcxproj ../build/win32/vs10/gio.vcxproj.filters
754         files='$(BUILT_EXTRA_DIST)'; \
755         for f in $$files; do \
756           if test -f $$f; then d=.; else d=$(srcdir); fi; \
757           cp $$d/$$f $(distdir) || exit 1; done
758
759 ../build/win32/vs9/gio.vcproj: $(top_srcdir)/build/win32/vs9/gio.vcprojin
760         for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
761                 case $$F in \
762                 gunix*.c|gdesktopappinfo.c|gnetworkmonitornetlink.c|gcontenttype.c) ;; \
763                 *.c) echo '   <File RelativePath="..\..\..\gio\'$$F'" />' \
764                      ;; \
765                 esac; \
766         done | sort -u >libgio.sourcefiles
767         $(CPP) -P - <$(top_srcdir)/build/win32/vs9/gio.vcprojin >$@
768         rm libgio.sourcefiles
769
770 ../build/win32/vs10/gio.vcxproj: $(top_srcdir)/build/win32/vs10/gio.vcxprojin
771         for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
772                 case $$F in \
773                 gunix*.c|gdesktopappinfo.c|gnetworkmonitornetlink.c|gcontenttype.c) ;; \
774                 *.c) echo '    <ClCompile Include="..\..\..\gio\'$$F'" />' \
775                      ;; \
776                 esac; \
777         done | sort -u >libgio.vs10.sourcefiles
778         $(CPP) -P - <$(top_srcdir)/build/win32/vs10/gio.vcxprojin >$@
779         rm libgio.vs10.sourcefiles
780
781 ../build/win32/vs10/gio.vcxproj.filters: $(top_srcdir)/build/win32/vs10/gio.vcxproj.filtersin
782         for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
783                 case $$F in \
784                 gunix*.c|gdesktopappinfo.c|gnetworkmonitornetlink.c|gcontenttype.c) ;; \
785                 *.c) echo '    <ClCompile Include="..\..\..\gio\'$$F'"><Filter>Source Files</Filter></ClCompile>' \
786                      ;; \
787                 esac; \
788         done | sort -u >libgio.vs10.sourcefiles.filters
789         $(CPP) -P - <$(top_srcdir)/build/win32/vs10/gio.vcxproj.filtersin >$@
790         rm libgio.vs10.sourcefiles.filters
791
792 if HAVE_GLIB_RUNTIME_LIBDIR
793 install-data-hook:
794         mkdir -p $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
795         mv $(DESTDIR)$(libdir)/libgio-2.0.so.0 $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
796         mv $(DESTDIR)$(libdir)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
797         rm -f $(DESTDIR)$(libdir)/libgio-2.0.so
798         ln -s $(GLIB_RUNTIME_LIBDIR)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/libgio-2.0.so
799 endif