1 include $(top_srcdir)/Makefile.decl
8 SUBDIRS += libasyncns xdgmime
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 -e 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) > gio.def.tmp && \
28 mv gio.def.tmp gio.def
31 if HAVE_GNUC_VISIBILITY
37 THREAD_FLAGS=-DG_THREADS_MANDATORY
41 -DG_LOG_DOMAIN=\"GLib-GIO\" \
45 -DG_DISABLE_DEPRECATED \
47 -DGIO_MODULE_DIR=\"$(GIO_MODULE_DIR)\"
49 lib_LTLIBRARIES = libgio-2.0.la
57 glib_genmarshal=$(GLIB_GENMARSHAL)
59 glib_genmarshal=../gobject/glib-genmarshal
62 gio-marshal.h: gio-marshal.list
63 $(AM_V_GEN) $(glib_genmarshal) --prefix=_gio_marshal $(srcdir)/gio-marshal.list --header --internal > $@.tmp && \
66 gio-marshal.c: gio-marshal.h gio-marshal.list
67 $(AM_V_GEN) (echo "#include \"gio-marshal.h\""; \
68 $(glib_genmarshal) --prefix=_gio_marshal $(srcdir)/gio-marshal.list --body --internal) > $@.tmp && \
82 gdbusintrospection.h \
83 gdbusmethodinvocation.h \
88 gdbusutils.h gdbusutils.c \
89 gdbusaddress.h gdbusaddress.c \
90 gdbusauthobserver.h gdbusauthobserver.c \
91 gdbusauth.h gdbusauth.c \
92 gdbusauthmechanism.h gdbusauthmechanism.c \
93 gdbusauthmechanismanon.h gdbusauthmechanismanon.c \
94 gdbusauthmechanismexternal.h gdbusauthmechanismexternal.c \
95 gdbusauthmechanismsha1.h gdbusauthmechanismsha1.c \
96 gdbuserror.h gdbuserror.c \
97 gdbusconnection.h gdbusconnection.c \
98 gdbusmessage.h gdbusmessage.c \
99 gdbusnameowning.h gdbusnameowning.c \
100 gdbusnamewatching.h gdbusnamewatching.c \
101 gdbusproxy.h gdbusproxy.c \
102 gdbusprivate.h gdbusprivate.c \
103 gdbusintrospection.h gdbusintrospection.c \
104 gdbusmethodinvocation.h gdbusmethodinvocation.c \
105 gdbusserver.h gdbusserver.c \
116 gdelayedsettingsbackend.h \
117 gdelayedsettingsbackend.c \
118 gkeyfilesettingsbackend.c \
119 gmemorysettingsbackend.c \
120 gnullsettingsbackend.c \
121 gsettingsbackendinternal.h \
125 gsettings-mapping.h \
126 gsettings-mapping.c \
130 settings_sources += \
131 gregistrysettingsbackend.h \
132 gregistrysettingsbackend.c
135 application_headers = \
137 gsimpleactiongroup.h \
140 gapplicationcommandline.h \
143 application_sources = \
145 gsimpleactiongroup.c \
148 gapplicationcommandline.c \
150 gapplicationimpl-dbus.c \
154 glocaldirectorymonitor.c \
155 glocaldirectorymonitor.h \
158 glocalfileenumerator.c \
159 glocalfileenumerator.h \
162 glocalfileinputstream.c \
163 glocalfileinputstream.h \
164 glocalfilemonitor.c \
165 glocalfilemonitor.h \
166 glocalfileoutputstream.c \
167 glocalfileoutputstream.h \
168 glocalfileiostream.c \
169 glocalfileiostream.h \
186 platform_libadd += inotify/libinotify.la
187 platform_deps += inotify/libinotify.la
191 AM_CPPFLAGS += -DHAVE_FEN
193 platform_libadd += fen/libfen.la
194 platform_deps += fen/libfen.la
199 platform_libadd += win32/libgiowin32.la
200 platform_deps += win32/libgiowin32.la
210 appinfo_sources += gdesktopappinfo.c
211 platform_libadd += libasyncns/libasyncns.la xdgmime/libxdgmime.la
212 platform_deps += libasyncns/libasyncns.la xdgmime/libxdgmime.la
214 gfiledescriptorbased.c \
216 gunixcredentialsmessage.c \
224 gunixsocketaddress.c \
227 gunixvolumemonitor.c \
228 gunixvolumemonitor.h \
230 gunixoutputstream.c \
234 giounixincludedir=$(includedir)/gio-unix-2.0/gio
235 giounixinclude_HEADERS = \
237 gfiledescriptorbased.h \
239 gunixcredentialsmessage.h \
244 gunixoutputstream.h \
245 gunixsocketaddress.h \
249 win32_actual_sources = \
254 gwin32volumemonitor.c \
255 gwin32volumemonitor.h \
256 gwin32inputstream.c \
257 gwin32outputstream.c \
258 gwin32outputstream.h \
261 win32_more_sources_for_vcproj = \
263 win32/gwin32directorymonitor.c \
264 win32/gwinhttpfile.c \
265 win32/gwinhttpfileinputstream.c \
266 win32/gwinhttpfileoutputstream.c \
270 appinfo_sources += gwin32appinfo.c gwin32appinfo.h
271 platform_libadd += -lshlwapi -lws2_32 -ldnsapi
272 win32_sources = $(win32_actual_sources)
274 giowin32includedir=$(includedir)/gio-win32-2.0/gio
275 giowin32include_HEADERS = \
276 gwin32inputstream.h \
277 gwin32outputstream.h \
284 libgio_2_0_la_SOURCES = \
290 gbufferedinputstream.c \
291 gbufferedoutputstream.c \
294 gcontenttypeprivate.h \
295 gcharsetconverter.c \
297 gconverterinputstream.c \
298 gconverteroutputstream.c \
301 gdataoutputstream.c \
305 gdummyproxyresolver.c \
306 gdummyproxyresolver.h \
315 gfileattribute-priv.h \
322 gfilenamecompleter.c \
323 gfileoutputstream.c \
325 gfilterinputstream.c \
326 gfilteroutputstream.c \
329 ginetsocketaddress.c \
340 gmemoryinputstream.c \
341 gmemoryoutputstream.c \
343 gnativevolumemonitor.c \
344 gnativevolumemonitor.h \
346 gnetworkingprivate.h \
350 gpollableinputstream.c \
351 gpollableoutputstream.c \
357 gsimpleasyncresult.c \
358 gsimplepermission.c \
361 gsocketaddressenumerator.c \
363 gsocketconnectable.c \
364 gsocketconnection.c \
365 gsocketcontrolmessage.c \
366 gsocketinputstream.c \
367 gsocketinputstream.h \
369 gsocketoutputstream.c \
370 gsocketoutputstream.h \
373 gproxyaddressenumerator.c \
377 gtcpwrapperconnection.c \
378 gthreadedsocketservice.c\
380 gthreadedresolver.c \
381 gthreadedresolver.h \
384 gtlsclientconnection.c \
386 gtlsserverconnection.c \
387 gunionvolumemonitor.c \
388 gunionvolumemonitor.h \
393 gzlibdecompressor.c \
400 $(application_sources) \
401 $(settings_sources) \
407 EXTRA_DIST += strinfo.c
409 $(libgio_2_0_la_OBJECTS): $(marshal_sources)
411 libgio_2_0_la_LIBADD = \
412 $(top_builddir)/glib/libglib-2.0.la \
413 $(top_builddir)/gobject/libgobject-2.0.la \
414 $(top_builddir)/gmodule/libgmodule-2.0.la \
423 no_undefined = -no-undefined
426 if OS_WIN32_AND_DLL_COMPILATION
427 export_symbols = -export-symbols gio.def
430 gio_win32_res = gio-win32-res.o
431 gio_win32_res_ldflag = -Wl,$(gio_win32_res)
434 $(INSTALL) gio.def $(DESTDIR)$(libdir)/gio-2.0.def
437 -rm $(DESTDIR)$(libdir)/gio-2.0.def
442 export_symbols = -export-symbols-regex '^g_.*'
445 install-data-local: install-ms-lib install-def-file
446 $(mkinstalldirs) $(DESTDIR)$(GIO_MODULE_DIR)
448 uninstall-local: uninstall-ms-lib uninstall-def-file
450 libgio_2_0_la_LDFLAGS = $(GLIB_LINK_FLAGS) \
451 $(gio_win32_res_ldflag) \
452 -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
453 -export-dynamic $(no_undefined) $(export_symbols)
455 libgio_2_0_la_DEPENDENCIES = $(gio_win32_res) $(gio_def) $(platform_deps)
457 gio-win32-res.o: gio.rc
464 gbufferedinputstream.h \
465 gbufferedoutputstream.h \
468 gcharsetconverter.h \
470 gconverterinputstream.h \
471 gconverteroutputstream.h \
473 gdataoutputstream.h \
484 gfilenamecompleter.h \
485 gfileoutputstream.h \
487 gfilterinputstream.h \
488 gfilteroutputstream.h \
491 ginetsocketaddress.h \
503 gmemoryinputstream.h \
504 gmemoryoutputstream.h \
506 gnativevolumemonitor.h \
511 gpollableinputstream.h \
512 gpollableoutputstream.h \
515 gproxyaddressenumerator.h \
519 gsimpleasyncresult.h \
520 gsimplepermission.h \
523 gsocketaddressenumerator.h \
525 gsocketconnectable.h \
526 gsocketconnection.h \
527 gsocketcontrolmessage.h \
532 gtcpwrapperconnection.h \
533 gthreadedsocketservice.h\
537 gtlsclientconnection.h \
539 gtlsserverconnection.h \
544 gzlibdecompressor.h \
545 $(application_headers) \
546 $(settings_headers) \
550 gioincludedir=$(includedir)/glib-2.0/gio/
551 gioinclude_HEADERS = \
555 # these sources (also mentioned above) are generated.
566 gioenumtypes.h.template \
567 gioenumtypes.c.template \
581 gioenumtypes.h: $(gio_headers) gioenumtypes.h.template
582 $(AM_V_GEN) ( top_builddir=`cd $(top_builddir) && pwd`; \
583 cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.h.template $(gio_headers) ) > \
584 gioenumtypes.h.tmp && mv gioenumtypes.h.tmp gioenumtypes.h
586 gioenumtypes.c: $(gio_headers) gioenumtypes.c.template
587 $(AM_V_GEN) ( top_builddir=`cd $(top_builddir) && pwd`; \
588 cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.c.template $(gio_headers) ) > \
589 gioenumtypes.c.tmp && mv gioenumtypes.c.tmp gioenumtypes.c
591 gio-2.0.lib: libgio-2.0.la gio.def
592 lib -machine:@LIB_EXE_MACHINE_FLAG@ -name:libgio-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:gio.def -out:$@
594 bin_PROGRAMS = gio-querymodules glib-compile-schemas gsettings
596 gio_querymodules_SOURCES = gio-querymodules.c
597 gio_querymodules_LDADD = \
598 $(top_builddir)/glib/libglib-2.0.la \
599 $(top_builddir)/gobject/libgobject-2.0.la \
600 $(top_builddir)/gmodule/libgmodule-2.0.la \
604 glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
605 glib_compile_schemas_SOURCES = \
607 gvdb/gvdb-builder.h \
608 gvdb/gvdb-builder.c \
609 glib-compile-schemas.c
612 $(top_builddir)/glib/libglib-2.0.la \
613 $(top_builddir)/gobject/libgobject-2.0.la \
615 gsettings_SOURCES = gsettings-tool.c
617 schemadir = $(datadir)/glib-2.0/schemas
618 dist_schema_DATA = gschema.dtd
620 # ------------------------------------------------------------------------
623 bin_PROGRAMS += gdbus
624 gdbus_SOURCES = gdbus-tool.c
625 gdbus_LDADD = libgio-2.0.la \
626 $(top_builddir)/glib/libglib-2.0.la \
627 $(top_builddir)/gobject/libgobject-2.0.la
629 completiondir = $(sysconfdir)/bash_completion.d
630 completion_SCRIPTS = \
631 gdbus-bash-completion.sh \
632 gsettings-bash-completion.sh
633 EXTRA_DIST += $(completion_SCRIPTS)
635 # ------------------------------------------------------------------------
637 dist-hook: $(BUILT_EXTRA_DIST) ../build/win32/vs9/gio.vcproj
638 files='$(BUILT_EXTRA_DIST)'; \
639 for f in $$files; do \
640 if test -f $$f; then d=.; else d=$(srcdir); fi; \
641 cp $$d/$$f $(distdir) || exit 1; done
643 ../build/win32/vs9/gio.vcproj: $(top_srcdir)/build/win32/vs9/gio.vcprojin
644 for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_actual_more_sources_for_vcproj) | tr '/' '\\'`; do \
646 gunix*.c|gdesktopappinfo.c) ;; \
647 *.c) echo ' <File RelativePath="..\..\..\gio\'$$F'" />' \
650 done | sort -u >libgio.sourcefiles
651 $(CPP) -P - <$(top_srcdir)/build/win32/vs9/gio.vcprojin >$@
652 rm libgio.sourcefiles
654 if HAVE_GLIB_RUNTIME_LIBDIR
656 mkdir -p $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
657 mv $(DESTDIR)$(libdir)/libgio-2.0.so.0 $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
658 mv $(DESTDIR)$(libdir)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
659 rm -f $(DESTDIR)$(libdir)/libgio-2.0.so
660 ln -s $(GLIB_RUNTIME_LIBDIR)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/libgio-2.0.so