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.h \
120 gmemorysettingsbackend.c \
121 gnullsettingsbackend.h \
122 gnullsettingsbackend.c \
123 gsettingsbackendinternal.h \
127 gsettings-mapping.h \
128 gsettings-mapping.c \
132 settings_sources += \
133 gregistrysettingsbackend.h \
134 gregistrysettingsbackend.c
137 application_headers = \
139 gsimpleactiongroup.h \
144 application_sources = \
146 gsimpleactiongroup.c \
152 glocaldirectorymonitor.c \
153 glocaldirectorymonitor.h \
156 glocalfileenumerator.c \
157 glocalfileenumerator.h \
160 glocalfileinputstream.c \
161 glocalfileinputstream.h \
162 glocalfilemonitor.c \
163 glocalfilemonitor.h \
164 glocalfileoutputstream.c \
165 glocalfileoutputstream.h \
166 glocalfileiostream.c \
167 glocalfileiostream.h \
184 platform_libadd += inotify/libinotify.la
185 platform_deps += inotify/libinotify.la
189 AM_CPPFLAGS += -DHAVE_FEN
191 platform_libadd += fen/libfen.la
192 platform_deps += fen/libfen.la
197 platform_libadd += win32/libgiowin32.la
198 platform_deps += win32/libgiowin32.la
209 appinfo_sources += gdesktopappinfo.c
210 platform_libadd += libasyncns/libasyncns.la xdgmime/libxdgmime.la
211 platform_deps += libasyncns/libasyncns.la xdgmime/libxdgmime.la
213 gfiledescriptorbased.c \
215 gunixcredentialsmessage.c \
223 gunixsocketaddress.c \
226 gunixvolumemonitor.c \
227 gunixvolumemonitor.h \
229 gunixoutputstream.c \
233 giounixincludedir=$(includedir)/gio-unix-2.0/gio
234 giounixinclude_HEADERS = \
236 gfiledescriptorbased.h \
238 gunixcredentialsmessage.h \
243 gunixoutputstream.h \
244 gunixsocketaddress.h \
248 win32_actual_sources = \
253 gwin32volumemonitor.c \
254 gwin32volumemonitor.h \
255 gwin32inputstream.c \
256 gwin32outputstream.c \
257 gwin32outputstream.h \
260 win32_more_sources_for_vcproj = \
262 win32/gwin32directorymonitor.c \
263 win32/gwinhttpfile.c \
264 win32/gwinhttpfileinputstream.c \
265 win32/gwinhttpfileoutputstream.c \
269 appinfo_sources += gwin32appinfo.c gwin32appinfo.h
270 platform_libadd += -lshlwapi -lws2_32 -ldnsapi
271 win32_sources = $(win32_actual_sources)
273 giowin32includedir=$(includedir)/gio-win32-2.0/gio
274 giowin32include_HEADERS = \
275 gwin32inputstream.h \
276 gwin32outputstream.h \
283 libgio_2_0_la_SOURCES = \
289 gbufferedinputstream.c \
290 gbufferedoutputstream.c \
293 gcontenttypeprivate.h \
294 gcharsetconverter.c \
296 gconverterinputstream.c \
297 gconverteroutputstream.c \
300 gdataoutputstream.c \
304 gdummyproxyresolver.c \
305 gdummyproxyresolver.h \
312 gfileattribute-priv.h \
319 gfilenamecompleter.c \
320 gfileoutputstream.c \
322 gfilterinputstream.c \
323 gfilteroutputstream.c \
326 ginetsocketaddress.c \
337 gmemoryinputstream.c \
338 gmemoryoutputstream.c \
340 gnativevolumemonitor.c \
341 gnativevolumemonitor.h \
343 gnetworkingprivate.h \
352 gsimpleasyncresult.c \
353 gsimplepermission.c \
356 gsocketaddressenumerator.c \
358 gsocketconnectable.c \
359 gsocketconnection.c \
360 gsocketcontrolmessage.c \
361 gsocketinputstream.c \
362 gsocketinputstream.h \
364 gsocketoutputstream.c \
365 gsocketoutputstream.h \
368 gproxyaddressenumerator.c \
374 gthreadedsocketservice.c\
376 gthreadedresolver.c \
377 gthreadedresolver.h \
378 gunionvolumemonitor.c \
379 gunionvolumemonitor.h \
384 gzlibdecompressor.c \
391 $(application_sources) \
392 $(settings_sources) \
398 EXTRA_DIST += gnullapplication.c gdbusapplication.c strinfo.c
400 $(libgio_2_0_la_OBJECTS): $(marshal_sources)
402 libgio_2_0_la_LIBADD = \
403 $(top_builddir)/glib/libglib-2.0.la \
404 $(top_builddir)/gobject/libgobject-2.0.la \
405 $(top_builddir)/gmodule/libgmodule-2.0.la \
414 no_undefined = -no-undefined
417 if OS_WIN32_AND_DLL_COMPILATION
418 export_symbols = -export-symbols gio.def
421 gio_win32_res = gio-win32-res.o
422 gio_win32_res_ldflag = -Wl,$(gio_win32_res)
425 $(INSTALL) gio.def $(DESTDIR)$(libdir)/gio-2.0.def
428 -rm $(DESTDIR)$(libdir)/gio-2.0.def
433 export_symbols = -export-symbols-regex '^g_.*'
436 install-data-local: install-ms-lib install-def-file
437 $(mkinstalldirs) $(DESTDIR)$(GIO_MODULE_DIR)
439 uninstall-local: uninstall-ms-lib uninstall-def-file
441 libgio_2_0_la_LDFLAGS = $(GLIB_LINK_FLAGS) \
442 $(gio_win32_res_ldflag) \
443 -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
444 -export-dynamic $(no_undefined) $(export_symbols)
446 libgio_2_0_la_DEPENDENCIES = $(gio_win32_res) $(gio_def) $(platform_deps)
448 gio-win32-res.o: gio.rc
455 gbufferedinputstream.h \
456 gbufferedoutputstream.h \
459 gcharsetconverter.h \
461 gconverterinputstream.h \
462 gconverteroutputstream.h \
464 gdataoutputstream.h \
475 gfilenamecompleter.h \
476 gfileoutputstream.h \
478 gfilterinputstream.h \
479 gfilteroutputstream.h \
482 ginetsocketaddress.h \
494 gmemoryinputstream.h \
495 gmemoryoutputstream.h \
497 gnativevolumemonitor.h \
504 gproxyaddressenumerator.h \
508 gsimpleasyncresult.h \
509 gsimplepermission.h \
512 gsocketaddressenumerator.h \
514 gsocketconnectable.h \
515 gsocketconnection.h \
516 gsocketcontrolmessage.h \
521 gthreadedsocketservice.h\
527 gzlibdecompressor.h \
528 $(application_headers) \
529 $(settings_headers) \
533 gioincludedir=$(includedir)/glib-2.0/gio/
534 gioinclude_HEADERS = \
538 # these sources (also mentioned above) are generated.
549 gioenumtypes.h.template \
550 gioenumtypes.c.template \
564 gioenumtypes.h: $(gio_headers) gioenumtypes.h.template
565 $(AM_V_GEN) ( top_builddir=`cd $(top_builddir) && pwd`; \
566 cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.h.template $(gio_headers) ) > \
567 gioenumtypes.h.tmp && mv gioenumtypes.h.tmp gioenumtypes.h
569 gioenumtypes.c: $(gio_headers) gioenumtypes.c.template
570 $(AM_V_GEN) ( top_builddir=`cd $(top_builddir) && pwd`; \
571 cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.c.template $(gio_headers) ) > \
572 gioenumtypes.c.tmp && mv gioenumtypes.c.tmp gioenumtypes.c
574 gio-2.0.lib: libgio-2.0.la gio.def
575 lib -machine:@LIB_EXE_MACHINE_FLAG@ -name:libgio-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:gio.def -out:$@
577 bin_PROGRAMS = gio-querymodules glib-compile-schemas gsettings
579 gio_querymodules_SOURCES = gio-querymodules.c
580 gio_querymodules_LDADD = \
581 $(top_builddir)/glib/libglib-2.0.la \
582 $(top_builddir)/gobject/libgobject-2.0.la \
583 $(top_builddir)/gmodule/libgmodule-2.0.la \
587 glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
588 glib_compile_schemas_SOURCES = \
590 gvdb/gvdb-builder.h \
591 gvdb/gvdb-builder.c \
592 glib-compile-schemas.c
595 $(top_builddir)/glib/libglib-2.0.la \
596 $(top_builddir)/gobject/libgobject-2.0.la \
598 gsettings_SOURCES = gsettings-tool.c
600 schemadir = $(datadir)/glib-2.0/schemas
601 dist_schema_DATA = gschema.dtd
603 # ------------------------------------------------------------------------
606 bin_PROGRAMS += gdbus
607 gdbus_SOURCES = gdbus-tool.c
608 gdbus_LDADD = libgio-2.0.la \
609 $(top_builddir)/glib/libglib-2.0.la \
610 $(top_builddir)/gobject/libgobject-2.0.la
612 completiondir = $(sysconfdir)/bash_completion.d
613 completion_SCRIPTS = \
614 gdbus-bash-completion.sh \
615 gsettings-bash-completion.sh
616 EXTRA_DIST += $(completion_SCRIPTS)
618 # ------------------------------------------------------------------------
620 dist-hook: $(BUILT_EXTRA_DIST) ../build/win32/vs9/gio.vcproj
621 files='$(BUILT_EXTRA_DIST)'; \
622 for f in $$files; do \
623 if test -f $$f; then d=.; else d=$(srcdir); fi; \
624 cp $$d/$$f $(distdir) || exit 1; done
626 ../build/win32/vs9/gio.vcproj: $(top_srcdir)/build/win32/vs9/gio.vcprojin
627 for F in `echo $(libgio_2_0_la_SOURCES) $(win32_actual_sources) $(win32_actual_more_sources_for_vcproj) | tr '/' '\\'`; do \
629 gunix*.c|gdesktopappinfo.c) ;; \
630 *.c) echo ' <File RelativePath="..\..\..\gio\'$$F'" />' \
633 done | sort -u >libgio.sourcefiles
634 $(CPP) -P - <$(top_srcdir)/build/win32/vs9/gio.vcprojin >$@
635 rm libgio.sourcefiles
637 if HAVE_GLIB_RUNTIME_LIBDIR
639 mkdir -p $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
640 mv $(DESTDIR)$(libdir)/libgio-2.0.so.0 $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
641 mv $(DESTDIR)$(libdir)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
642 rm -f $(DESTDIR)$(libdir)/libgio-2.0.so
643 ln -s $(GLIB_RUNTIME_LIBDIR)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/libgio-2.0.so