1 include $(top_srcdir)/Makefile.decl
5 SUBDIRS = gdbus-2.0/codegen
11 if OS_WIN32_AND_DLL_COMPILATION
13 noinst_DATA = gio-2.0.lib
15 install_ms_lib_cmd = $(INSTALL) gio-2.0.lib $(DESTDIR)$(libdir)
16 uninstall_ms_lib_cmd = -rm $(DESTDIR)$(libdir)/gio-2.0.lib
24 $(uninstall_ms_lib_cmd)
27 $(AM_V_GEN) (echo EXPORTS; $(CPP) -P -DINCLUDE_VARIABLES -DINCLUDE_INTERNAL_SYMBOLS -DG_OS_WIN32 -DALL_FILES - <$(srcdir)/gio.symbols | sed -e '/^$$/d' -e 's/^/ /' -e 's/G_GNUC_[^ ]*//g' | sort) > $(builddir)/gio.def.tmp && \
28 mv $(builddir)/gio.def.tmp $(builddir)/gio.def
31 if HAVE_GNUC_VISIBILITY
37 -DG_LOG_DOMAIN=\"GLib-GIO\" \
41 -DGIO_MODULE_DIR=\"$(GIO_MODULE_DIR)\"
43 lib_LTLIBRARIES = libgio-2.0.la
56 gdbusintrospection.h \
57 gdbusmethodinvocation.h \
60 gdbusinterfaceskeleton.h \
62 gdbusobjectskeleton.h \
64 gdbusobjectmanager.h \
65 gdbusobjectmanagerclient.h \
66 gdbusobjectmanagerserver.h \
70 gdbusutils.h gdbusutils.c \
71 gdbusaddress.h gdbusaddress.c \
72 gdbusauthobserver.h gdbusauthobserver.c \
73 gdbusauth.h gdbusauth.c \
74 gdbusauthmechanism.h gdbusauthmechanism.c \
75 gdbusauthmechanismanon.h gdbusauthmechanismanon.c \
76 gdbusauthmechanismexternal.h gdbusauthmechanismexternal.c \
77 gdbusauthmechanismsha1.h gdbusauthmechanismsha1.c \
78 gdbuserror.h gdbuserror.c \
79 gdbusconnection.h gdbusconnection.c \
80 gdbusmessage.h gdbusmessage.c \
81 gdbusnameowning.h gdbusnameowning.c \
82 gdbusnamewatching.h gdbusnamewatching.c \
83 gdbusproxy.h gdbusproxy.c \
84 gdbusprivate.h gdbusprivate.c \
85 gdbusintrospection.h gdbusintrospection.c \
86 gdbusmethodinvocation.h gdbusmethodinvocation.c \
87 gdbusserver.h gdbusserver.c \
88 gdbusinterface.h gdbusinterface.c \
89 gdbusinterfaceskeleton.h gdbusinterfaceskeleton.c \
90 gdbusobject.h gdbusobject.c \
91 gdbusobjectskeleton.h gdbusobjectskeleton.c \
92 gdbusobjectproxy.h gdbusobjectproxy.c \
93 gdbusobjectmanager.h gdbusobjectmanager.c \
94 gdbusobjectmanagerclient.h gdbusobjectmanagerclient.c \
95 gdbusobjectmanagerserver.h gdbusobjectmanagerserver.c \
107 gdelayedsettingsbackend.h \
108 gdelayedsettingsbackend.c \
109 gkeyfilesettingsbackend.c \
110 gmemorysettingsbackend.c \
111 gnullsettingsbackend.c \
112 gsettingsbackendinternal.h \
115 gsettingsschema-internal.h \
117 gsettings-mapping.h \
118 gsettings-mapping.c \
122 settings_sources += \
123 gregistrysettingsbackend.h \
124 gregistrysettingsbackend.c
128 settings_sources += \
129 gnextstepsettingsbackend.c
132 application_headers = \
134 gapplicationcommandline.h \
138 gsimpleactiongroup.h \
139 gremoteactiongroup.h \
140 gactiongroupexporter.h \
151 application_sources = \
153 gapplicationcommandline.c \
154 gapplicationimpl-dbus.c \
159 gsimpleactiongroup.c \
160 gremoteactiongroup.c \
161 gactiongroupexporter.c \
173 glocaldirectorymonitor.c \
174 glocaldirectorymonitor.h \
177 glocalfileenumerator.c \
178 glocalfileenumerator.h \
181 glocalfileinputstream.c \
182 glocalfileinputstream.h \
183 glocalfilemonitor.c \
184 glocalfilemonitor.h \
185 glocalfileoutputstream.c \
186 glocalfileoutputstream.h \
187 glocalfileiostream.c \
188 glocalfileiostream.h \
205 platform_libadd += inotify/libinotify.la
206 platform_deps += inotify/libinotify.la
210 AM_CPPFLAGS += -DHAVE_FEN
212 platform_libadd += fen/libfen.la
213 platform_deps += fen/libfen.la
218 platform_libadd += win32/libgiowin32.la
219 platform_deps += win32/libgiowin32.la
229 appinfo_sources += gdesktopappinfo.c
230 platform_libadd += xdgmime/libxdgmime.la $(RESOLVER_LIBADD)
231 platform_deps += xdgmime/libxdgmime.la
233 gfiledescriptorbased.c \
235 gunixcredentialsmessage.c \
241 gunixsocketaddress.c \
244 gunixvolumemonitor.c \
245 gunixvolumemonitor.h \
247 gunixoutputstream.c \
251 giounixincludedir=$(includedir)/gio-unix-2.0/gio
252 giounixinclude_HEADERS = \
254 gfiledescriptorbased.h \
256 gunixcredentialsmessage.h \
261 gunixoutputstream.h \
262 gunixsocketaddress.h \
267 gnetworkmonitornetlink.c \
268 gnetworkmonitornetlink.h \
273 win32_actual_sources = \
276 gwin32volumemonitor.c \
277 gwin32volumemonitor.h \
278 gwin32inputstream.c \
279 gwin32outputstream.c \
280 gwin32outputstream.h \
283 win32_more_sources_for_vcproj = \
285 gregistrysettingsbackend.c \
286 win32/gwin32directorymonitor.c \
287 win32/gwinhttpfile.c \
288 win32/gwinhttpfileinputstream.c \
289 win32/gwinhttpfileoutputstream.c \
293 appinfo_sources += gwin32appinfo.c gwin32appinfo.h
294 platform_libadd += -lshlwapi -lws2_32 -ldnsapi
295 win32_sources = $(win32_actual_sources)
297 giowin32includedir=$(includedir)/gio-win32-2.0/gio
298 giowin32include_HEADERS = \
299 gwin32inputstream.h \
300 gwin32outputstream.h \
307 libgio_2_0_la_SOURCES = \
313 gbufferedinputstream.c \
314 gbufferedoutputstream.c \
317 gcontenttypeprivate.h \
318 gcharsetconverter.c \
320 gconverterinputstream.c \
321 gconverteroutputstream.c \
324 gdataoutputstream.c \
328 gdummyproxyresolver.c \
329 gdummyproxyresolver.h \
338 gfileattribute-priv.h \
345 gfilenamecompleter.c \
346 gfileoutputstream.c \
348 gfilterinputstream.c \
349 gfilteroutputstream.c \
353 ginetsocketaddress.c \
364 gmemoryinputstream.c \
365 gmemoryoutputstream.c \
367 gnativevolumemonitor.c \
368 gnativevolumemonitor.h \
370 gnetworkingprivate.h \
372 gnetworkmonitorbase.c \
373 gnetworkmonitorbase.h \
377 gpollableinputstream.c \
378 gpollableoutputstream.c \
387 gsimpleasyncresult.c \
388 gsimplepermission.c \
391 gsocketaddressenumerator.c \
393 gsocketconnectable.c \
394 gsocketconnection.c \
395 gsocketcontrolmessage.c \
396 gsocketinputstream.c \
397 gsocketinputstream.h \
399 gsocketoutputstream.c \
400 gsocketoutputstream.h \
403 gproxyaddressenumerator.c \
407 gtcpwrapperconnection.c \
408 gthreadedsocketservice.c\
410 gthreadedresolver.c \
411 gthreadedresolver.h \
414 gtlsclientconnection.c \
420 gtlsserverconnection.c \
421 gunionvolumemonitor.c \
422 gunionvolumemonitor.h \
427 gzlibdecompressor.c \
434 $(application_sources) \
435 $(settings_sources) \
440 EXTRA_DIST += strinfo.c
442 libgio_2_0_la_LIBADD = \
443 $(top_builddir)/glib/libglib-2.0.la \
444 $(top_builddir)/gobject/libgobject-2.0.la \
445 $(top_builddir)/gmodule/libgmodule-2.0.la \
454 libgio_2_0_la_CPPFLAGS = $(ZLIB_CFLAGS) $(AM_CPPFLAGS)
457 no_undefined = -no-undefined
460 if OS_WIN32_AND_DLL_COMPILATION
461 export_symbols = -export-symbols $(builddir)/gio.def
464 gio_win32_res = gio-win32-res.o
465 gio_win32_res_ldflag = -Wl,$(gio_win32_res)
468 $(INSTALL) $(builddir)/gio.def $(DESTDIR)$(libdir)/gio-2.0.def
471 -rm $(DESTDIR)$(libdir)/gio-2.0.def
476 export_symbols = $(LIBTOOL_EXPORT_OPTIONS)
479 install-data-local: install-ms-lib install-def-file
480 $(mkinstalldirs) $(DESTDIR)$(GIO_MODULE_DIR)
482 uninstall-local: uninstall-ms-lib uninstall-def-file
484 libgio_2_0_la_LDFLAGS = $(GLIB_LINK_FLAGS) \
485 $(gio_win32_res_ldflag) \
486 -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
487 -export-dynamic $(no_undefined) $(export_symbols)
490 # This is dumb. The ObjC source file should be properly named .m
491 libgio_2_0_la_CFLAGS = -xobjective-c
492 libgio_2_0_la_LDFLAGS += -framework Foundation
495 libgio_2_0_la_DEPENDENCIES = $(gio_win32_res) $(gio_def) $(platform_deps)
497 gio-win32-res.o: gio.rc
504 gbufferedinputstream.h \
505 gbufferedoutputstream.h \
508 gcharsetconverter.h \
510 gconverterinputstream.h \
511 gconverteroutputstream.h \
513 gdataoutputstream.h \
524 gfilenamecompleter.h \
525 gfileoutputstream.h \
527 gfilterinputstream.h \
528 gfilteroutputstream.h \
532 ginetsocketaddress.h \
544 gmemoryinputstream.h \
545 gmemoryoutputstream.h \
547 gnativevolumemonitor.h \
553 gpollableinputstream.h \
554 gpollableoutputstream.h \
557 gproxyaddressenumerator.h \
562 gsimpleasyncresult.h \
563 gsimplepermission.h \
566 gsocketaddressenumerator.h \
568 gsocketconnectable.h \
569 gsocketconnection.h \
570 gsocketcontrolmessage.h \
575 gtcpwrapperconnection.h \
576 gthreadedsocketservice.h\
580 gtlsclientconnection.h \
586 gtlsserverconnection.h \
591 gzlibdecompressor.h \
592 $(application_headers) \
593 $(settings_headers) \
597 gioincludedir=$(includedir)/glib-2.0/gio/
598 gioinclude_HEADERS = \
602 # these sources (also mentioned above) are generated.
604 gconstructor_as_data.h \
612 gioenumtypes.h.template \
613 gioenumtypes.c.template \
618 gconstructor_as_data.h \
624 # This is read by gobject-introspection/misc/ and gtk-doc
625 gio-public-headers.txt: Makefile
626 echo $(gioinclude_HEADERS) $(giowin32include_HEADERS) $(giounixinclude_HEADERS) > $@.tmp && mv $@.tmp $@
628 CLEANFILES = gio-public-headers.txt gconstructor_as_data.h
630 all-local: gio-public-headers.txt
632 gioenumtypes.h: $(gio_headers) gioenumtypes.h.template
633 $(AM_V_GEN) ( top_builddir=`cd $(top_builddir) && pwd`; \
634 cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.h.template $(gio_headers) ) > \
635 gioenumtypes.h.tmp && mv gioenumtypes.h.tmp gioenumtypes.h
637 gioenumtypes.c: $(gio_headers) gioenumtypes.c.template
638 $(AM_V_GEN) ( top_builddir=`cd $(top_builddir) && pwd`; \
639 cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.c.template $(gio_headers) ) > \
640 gioenumtypes.c.tmp && mv gioenumtypes.c.tmp gioenumtypes.c
642 gio-2.0.lib: libgio-2.0.la gio.def
643 lib -machine:@LIB_EXE_MACHINE_FLAG@ -name:libgio-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:$(builddir)/gio.def -out:$@
645 bin_PROGRAMS = gio-querymodules glib-compile-schemas glib-compile-resources gsettings
647 glib_compile_resources_LDADD = \
648 $(top_builddir)/glib/libglib-2.0.la \
649 $(top_builddir)/gobject/libgobject-2.0.la \
652 glib_compile_resources_SOURCES = \
654 gvdb/gvdb-builder.h \
655 gvdb/gvdb-builder.c \
656 glib-compile-resources.c
658 gio_querymodules_SOURCES = gio-querymodules.c
659 gio_querymodules_LDADD = \
660 $(top_builddir)/glib/libglib-2.0.la \
661 $(top_builddir)/gobject/libgobject-2.0.la \
662 $(top_builddir)/gmodule/libgmodule-2.0.la \
666 gconstructor_as_data.h: $(top_srcdir)/glib/gconstructor.h data-to-c.pl
667 $(AM_V_GEN) $(srcdir)/data-to-c.pl $(top_srcdir)/glib/gconstructor.h gconstructor_code > $@.tmp && mv $@.tmp $@
669 glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
670 glib_compile_schemas_SOURCES = \
671 gconstructor_as_data.h \
673 gvdb/gvdb-builder.h \
674 gvdb/gvdb-builder.c \
675 glib-compile-schemas.c
678 $(top_builddir)/glib/libglib-2.0.la \
679 $(top_builddir)/gobject/libgobject-2.0.la \
681 gsettings_SOURCES = gsettings-tool.c
683 schemadir = $(datadir)/glib-2.0/schemas
684 dist_schema_DATA = gschema.dtd
686 # ------------------------------------------------------------------------
689 bin_PROGRAMS += gdbus
690 gdbus_SOURCES = gdbus-tool.c
691 gdbus_LDADD = libgio-2.0.la \
692 $(top_builddir)/glib/libglib-2.0.la \
693 $(top_builddir)/gobject/libgobject-2.0.la
695 completiondir = $(sysconfdir)/bash_completion.d
697 gdbus-bash-completion.sh \
698 gsettings-bash-completion.sh \
699 gresource-bash-completion.sh
700 EXTRA_DIST += $(completion_DATA)
702 # ------------------------------------------------------------------------
705 bin_PROGRAMS += gresource
706 gresource_SOURCES = gresource-tool.c
707 gresource_CPPFLAGS = $(LIBELF_CFLAGS) $(AM_CPPFLAGS)
708 gresource_LDADD = libgio-2.0.la \
709 $(top_builddir)/glib/libglib-2.0.la \
710 $(top_builddir)/gobject/libgobject-2.0.la \
713 # ------------------------------------------------------------------------
715 dist-hook: $(BUILT_EXTRA_DIST) ../build/win32/vs9/gio.vcproj ../build/win32/vs10/gio.vcxproj ../build/win32/vs10/gio.vcxproj.filters
716 files='$(BUILT_EXTRA_DIST)'; \
717 for f in $$files; do \
718 if test -f $$f; then d=.; else d=$(srcdir); fi; \
719 cp $$d/$$f $(distdir) || exit 1; done
721 ../build/win32/vs9/gio.vcproj: $(top_srcdir)/build/win32/vs9/gio.vcprojin
722 for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
724 gunix*.c|gdesktopappinfo.c|gnetworkmonitornetlink.c) ;; \
725 *.c) echo ' <File RelativePath="..\..\..\gio\'$$F'" />' \
728 done | sort -u >libgio.sourcefiles
729 $(CPP) -P - <$(top_srcdir)/build/win32/vs9/gio.vcprojin >$@
730 rm libgio.sourcefiles
732 ../build/win32/vs10/gio.vcxproj: $(top_srcdir)/build/win32/vs10/gio.vcxprojin
733 for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
735 gunix*.c|gdesktopappinfo.c|gnetworkmonitornetlink.c) ;; \
736 *.c) echo ' <ClCompile Include="..\..\..\gio\'$$F'" />' \
739 done | sort -u >libgio.vs10.sourcefiles
740 $(CPP) -P - <$(top_srcdir)/build/win32/vs10/gio.vcxprojin >$@
741 rm libgio.vs10.sourcefiles
743 ../build/win32/vs10/gio.vcxproj.filters: $(top_srcdir)/build/win32/vs10/gio.vcxproj.filtersin
744 for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
746 gunix*.c|gdesktopappinfo.c|gnetworkmonitornetlink.c) ;; \
747 *.c) echo ' <ClCompile Include="..\..\..\gio\'$$F'"><Filter>Source Files</Filter></ClCompile>' \
750 done | sort -u >libgio.vs10.sourcefiles.filters
751 $(CPP) -P - <$(top_srcdir)/build/win32/vs10/gio.vcxproj.filtersin >$@
752 rm libgio.vs10.sourcefiles.filters
754 if HAVE_GLIB_RUNTIME_LIBDIR
756 mkdir -p $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
757 mv $(DESTDIR)$(libdir)/libgio-2.0.so.0 $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
758 mv $(DESTDIR)$(libdir)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
759 rm -f $(DESTDIR)$(libdir)/libgio-2.0.so
760 ln -s $(GLIB_RUNTIME_LIBDIR)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/libgio-2.0.so