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 (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
30 gioalias.h: gio.symbols
31 $(PERL) $(srcdir)/makegioalias.pl < $(srcdir)/gio.symbols > gioalias.h.tmp && \
32 mv gioalias.h.tmp gioalias.h
34 gioaliasdef.c: gio.symbols
35 $(PERL) $(srcdir)/makegioalias.pl -def < $(srcdir)/gio.symbols > gioaliasdef.c.tmp && \
36 mv gioaliasdef.c.tmp gioaliasdef.c
39 if HAVE_GNUC_VISIBILITY
40 TESTS = abicheck.sh pltcheck.sh
45 THREAD_FLAGS=-DG_THREADS_MANDATORY
49 -DG_LOG_DOMAIN=\"GLib-GIO\" \
52 -I$(top_srcdir)/glib \
53 -I$(top_srcdir)/gmodule \
56 -DG_DISABLE_DEPRECATED \
58 -DGIO_MODULE_DIR=\"$(GIO_MODULE_DIR)\"
60 lib_LTLIBRARIES = libgio-2.0.la
68 glib_genmarshal=$(GLIB_GENMARSHAL)
70 glib_genmarshal=../gobject/glib-genmarshal
73 gio-marshal.h: gio-marshal.list
74 $(glib_genmarshal) --prefix=_gio_marshal $(srcdir)/gio-marshal.list --header --internal > $@.tmp && \
77 gio-marshal.c: gio-marshal.h gio-marshal.list
78 (echo "#include \"gio-marshal.h\""; \
79 $(glib_genmarshal) --prefix=_gio_marshal $(srcdir)/gio-marshal.list --body --internal) > $@.tmp && \
92 gdbusproxywatching.h \
94 gdbusintrospection.h \
95 gdbusmethodinvocation.h \
100 gdbusutils.h gdbusutils.c \
101 gdbusaddress.h gdbusaddress.c \
102 gdbusauthobserver.h gdbusauthobserver.c \
103 gdbusauth.h gdbusauth.c \
104 gdbusauthmechanism.h gdbusauthmechanism.c \
105 gdbusauthmechanismanon.h gdbusauthmechanismanon.c \
106 gdbusauthmechanismexternal.h gdbusauthmechanismexternal.c \
107 gdbusauthmechanismsha1.h gdbusauthmechanismsha1.c \
108 gdbuserror.h gdbuserror.c \
109 gdbusconnection.h gdbusconnection.c \
110 gdbusmessage.h gdbusmessage.c \
111 gdbusnameowning.h gdbusnameowning.c \
112 gdbusnamewatching.h gdbusnamewatching.c \
113 gdbusproxywatching.h gdbusproxywatching.c \
114 gdbusproxy.h gdbusproxy.c \
115 gdbusprivate.h gdbusprivate.c \
116 gdbusintrospection.h gdbusintrospection.c \
117 gdbusmethodinvocation.h gdbusmethodinvocation.c \
118 gdbusserver.h gdbusserver.c \
129 gdelayedsettingsbackend.h \
130 gdelayedsettingsbackend.c \
131 gkeyfilesettingsbackend.h \
132 gkeyfilesettingsbackend.c \
133 gmemorysettingsbackend.h \
134 gmemorysettingsbackend.c \
135 gnullsettingsbackend.h \
136 gnullsettingsbackend.c \
137 gsettingsbackendinternal.h \
141 gsettings-mapping.h \
142 gsettings-mapping.c \
146 glocaldirectorymonitor.c \
147 glocaldirectorymonitor.h \
150 glocalfileenumerator.c \
151 glocalfileenumerator.h \
154 glocalfileinputstream.c \
155 glocalfileinputstream.h \
156 glocalfilemonitor.c \
157 glocalfilemonitor.h \
158 glocalfileoutputstream.c \
159 glocalfileoutputstream.h \
160 glocalfileiostream.c \
161 glocalfileiostream.h \
172 platform_libadd += inotify/libinotify.la
173 platform_deps += inotify/libinotify.la
177 AM_CPPFLAGS += -DHAVE_FEN
179 platform_libadd += fen/libfen.la
180 platform_deps += fen/libfen.la
185 platform_libadd += win32/libgiowin32.la
186 platform_deps += win32/libgiowin32.la
197 appinfo_sources += gdesktopappinfo.c
198 platform_libadd += libasyncns/libasyncns.la xdgmime/libxdgmime.la
199 platform_deps += libasyncns/libasyncns.la xdgmime/libxdgmime.la
201 gfiledescriptorbased.c \
203 gunixcredentialsmessage.c \
211 gunixsocketaddress.c \
214 gunixvolumemonitor.c \
215 gunixvolumemonitor.h \
217 gunixoutputstream.c \
221 giounixincludedir=$(includedir)/gio-unix-2.0/gio
222 giounixinclude_HEADERS = \
224 gfiledescriptorbased.h \
226 gunixcredentialsmessage.h \
231 gunixoutputstream.h \
232 gunixsocketaddress.h \
237 appinfo_sources += gwin32appinfo.c gwin32appinfo.h
238 platform_libadd += -lshlwapi -lws2_32 -ldnsapi
244 gwin32volumemonitor.c \
245 gwin32volumemonitor.h \
246 gwin32inputstream.c \
247 gwin32outputstream.c \
248 gwin32outputstream.h \
251 win32_more_sources_for_vcproj = \
253 win32/gwin32directorymonitor.c \
254 win32/gwinhttpfile.c \
255 win32/gwinhttpfileinputstream.c \
256 win32/gwinhttpfileoutputstream.c \
259 giowin32includedir=$(includedir)/gio-win32-2.0/gio
260 giowin32include_HEADERS = \
261 gwin32inputstream.h \
262 gwin32outputstream.h \
269 libgio_2_0_la_SOURCES = \
275 gbufferedinputstream.c \
276 gbufferedoutputstream.c \
279 gcontenttypeprivate.h \
280 gcharsetconverter.c \
282 gconverterinputstream.c \
283 gconverteroutputstream.c \
286 gdataoutputstream.c \
296 gfileattribute-priv.h \
303 gfilenamecompleter.c \
304 gfileoutputstream.c \
306 gfilterinputstream.c \
307 gfilteroutputstream.c \
310 ginetsocketaddress.c \
321 gmemoryinputstream.c \
322 gmemoryoutputstream.c \
324 gnativevolumemonitor.c \
325 gnativevolumemonitor.h \
327 gnetworkingprivate.h \
334 gsimpleasyncresult.c \
337 gsocketaddressenumerator.c \
339 gsocketconnectable.c \
340 gsocketconnection.c \
341 gsocketcontrolmessage.c \
342 gsocketinputstream.c \
343 gsocketinputstream.h \
345 gsocketoutputstream.c \
346 gsocketoutputstream.h \
350 gthreadedsocketservice.c\
352 gthreadedresolver.c \
353 gthreadedresolver.h \
354 gunionvolumemonitor.c \
355 gunionvolumemonitor.h \
360 gzlibdecompressor.c \
369 $(settings_sources) \
375 $(libgio_2_0_la_OBJECTS): $(marshal_sources)
377 libgio_2_0_la_LIBADD = \
378 $(top_builddir)/glib/libglib-2.0.la \
379 $(top_builddir)/gobject/libgobject-2.0.la \
380 $(top_builddir)/gmodule/libgmodule-2.0.la \
389 no_undefined = -no-undefined
392 if OS_WIN32_AND_DLL_COMPILATION
393 export_symbols = -export-symbols gio.def
396 gio_win32_res = gio-win32-res.o
397 gio_win32_res_ldflag = -Wl,$(gio_win32_res)
400 $(INSTALL) gio.def $(DESTDIR)$(libdir)/gio-2.0.def
403 -rm $(DESTDIR)$(libdir)/gio-2.0.def
408 export_symbols = -export-symbols-regex '^g_.*'
411 install-data-local: install-ms-lib install-def-file
412 $(mkinstalldirs) $(DESTDIR)$(GIO_MODULE_DIR)
414 uninstall-local: uninstall-ms-lib uninstall-def-file
416 libgio_2_0_la_LDFLAGS = \
417 $(gio_win32_res_ldflag) \
418 -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
419 -export-dynamic $(no_undefined) $(export_symbols)
421 libgio_2_0_la_DEPENDENCIES = $(gio_win32_res) $(gio_def) $(platform_deps)
423 gio-win32-res.o: gio.rc
430 gbufferedinputstream.h \
431 gbufferedoutputstream.h \
434 gcharsetconverter.h \
436 gconverterinputstream.h \
437 gconverteroutputstream.h \
439 gdataoutputstream.h \
450 gfilenamecompleter.h \
451 gfileoutputstream.h \
453 gfilterinputstream.h \
454 gfilteroutputstream.h \
457 ginetsocketaddress.h \
469 gmemoryinputstream.h \
470 gmemoryoutputstream.h \
472 gnativevolumemonitor.h \
478 gsimpleasyncresult.h \
481 gsocketaddressenumerator.h \
483 gsocketconnectable.h \
484 gsocketconnection.h \
485 gsocketcontrolmessage.h \
490 gthreadedsocketservice.h\
496 gzlibdecompressor.h \
497 $(settings_headers) \
501 gioincludedir=$(includedir)/glib-2.0/gio/
502 gioinclude_HEADERS = \
506 # these sources (also mentioned above) are generated.
519 gioenumtypes.h.template \
520 gioenumtypes.c.template \
536 gioenumtypes.h: $(gio_headers) gioenumtypes.h.template
537 ( top_builddir=`cd $(top_builddir) && pwd`; \
538 cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.h.template $(gio_headers) ) > \
539 gioenumtypes.h.tmp && mv gioenumtypes.h.tmp gioenumtypes.h
541 gioenumtypes.c: $(gio_headers) gioenumtypes.c.template
542 ( top_builddir=`cd $(top_builddir) && pwd`; \
543 cd $(srcdir) && $$top_builddir/gobject/glib-mkenums --template gioenumtypes.c.template $(gio_headers) ) > \
544 gioenumtypes.c.tmp && mv gioenumtypes.c.tmp gioenumtypes.c
546 gio-2.0.lib: libgio-2.0.la gio.def
547 lib -machine:@LIB_EXE_MACHINE_FLAG@ -name:libgio-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:gio.def -out:$@
549 dist_bin_SCRIPTS = gsettings-schema-convert
550 bin_PROGRAMS = gio-querymodules glib-compile-schemas gsettings
552 gio_querymodules_SOURCES = gio-querymodules.c
553 gio_querymodules_LDADD = \
554 $(top_builddir)/glib/libglib-2.0.la \
555 $(top_builddir)/gobject/libgobject-2.0.la \
556 $(top_builddir)/gmodule/libgmodule-2.0.la \
560 glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
561 glib_compile_schemas_SOURCES = \
563 gvdb/gvdb-builder.h \
564 gvdb/gvdb-builder.c \
568 $(top_builddir)/glib/libglib-2.0.la \
569 $(top_builddir)/gobject/libgobject-2.0.la \
571 gsettings_SOURCES = gsettings-tool.c
573 schemadir = $(datadir)/glib-2.0/schemas
574 dist_schema_DATA = gschema.dtd
576 # ------------------------------------------------------------------------
579 bin_PROGRAMS += gdbus
580 gdbus_SOURCES = gdbus-tool.c
581 gdbus_LDADD = libgio-2.0.la \
582 $(top_builddir)/glib/libglib-2.0.la \
583 $(top_builddir)/gobject/libgobject-2.0.la
585 completiondir = $(sysconfdir)/bash_completion.d
586 completion_SCRIPTS = gdbus-bash-completion.sh
587 EXTRA_DIST += $(completion_SCRIPTS)
589 # ------------------------------------------------------------------------
591 dist-hook: $(BUILT_EXTRA_DIST) ../build/win32/vs9/gio.vcproj
592 files='$(BUILT_EXTRA_DIST)'; \
593 for f in $$files; do \
594 if test -f $$f; then d=.; else d=$(srcdir); fi; \
595 cp $$d/$$f $(distdir) || exit 1; done
597 ../build/win32/vs9/gio.vcproj: $(top_srcdir)/build/win32/vs9/gio.vcprojin
598 for F in `echo $(libgio_2_0_la_SOURCES) $(win32_sources) $(win32_more_sources_for_vcproj) | tr '/' '\\'`; do \
600 gunix*.c|gdesktopappinfo.c) ;; \
601 *.c) echo ' <File RelativePath="..\..\..\gio\'$$F'" />' \
604 done | sort -u >libgio.sourcefiles
605 $(CPP) -P - <$(top_srcdir)/build/win32/vs9/gio.vcprojin >$@
606 rm libgio.sourcefiles
608 if HAVE_GLIB_RUNTIME_LIBDIR
610 mkdir -p $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
611 mv $(DESTDIR)$(libdir)/libgio-2.0.so.0 $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
612 mv $(DESTDIR)$(libdir)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/$(GLIB_RUNTIME_LIBDIR)
613 rm -f $(DESTDIR)$(libdir)/libgio-2.0.so
614 ln -s $(GLIB_RUNTIME_LIBDIR)/libgio-2.0.so.0.$(LT_CURRENT).$(LT_REVISION) $(DESTDIR)$(libdir)/libgio-2.0.so