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