1 # GObject - GLib Type, Object, Parameter and Signal Library
2 # Copyright (C) 1997,98,99,2000 Tim Janik and Red Hat, Inc.
4 ## Process this file with automake to produce Makefile.in
7 -DG_LOG_DOMAIN=\"GLib-GObject\" \
12 -DG_DISABLE_DEPRECATED \
13 -DGOBJECT_COMPILATION \
14 -DG_DISABLE_CONST_RETURNS
16 gobject.def: gobject.symbols
17 (echo -e EXPORTS; cpp -P -DINCLUDE_VARIABLES -DINCLUDE_INTERNAL_SYMBOLS -DG_OS_WIN32 $(srcdir)/gobject.symbols | sed -e '/^$$/d' -e 's/^/\t/' | sort) > gobject.def
19 gobjectalias.h: gobject.symbols
20 ./makegobjectalias.pl < $(srcdir)/gobject.symbols > gobjectalias.h
26 libglib = $(top_builddir)/glib/libglib-2.0.la
28 # libraries to compile and install
29 lib_LTLIBRARIES = libgobject-2.0.la
32 noinst_DATA = gobject-2.0.lib
35 $(INSTALL) gobject-2.0.lib $(DESTDIR)$(libdir)
38 -rm $(DESTDIR)$(libdir)/gobject-2.0.lib
45 no_undefined = -no-undefined
49 export_symbols = -export-symbols $(srcdir)/gobject.def
51 install-libtool-import-lib:
52 $(INSTALL) .libs/libgobject-2.0.dll.a $(DESTDIR)$(libdir)
53 $(INSTALL) $(srcdir)/gobject.def $(DESTDIR)$(libdir)/gobject-2.0.def
55 uninstall-libtool-import-lib:
56 -rm $(DESTDIR)$(libdir)/libgobject-2.0.dll.a $(DESTDIR)$(libdir)/gobject-2.0.def
58 install-libtool-import-lib:
59 uninstall-libtool-import-lib:
61 export_symbols = $(LIBTOOL_EXPORT_OPTIONS)
64 # libtool stuff: set version and export symbols for resolving
65 libgobjectincludedir = $(includedir)/glib-2.0/gobject
66 libgobject_2_0_la_LDFLAGS = \
67 -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
68 -export-dynamic $(no_undefined) $(export_symbols)
70 libgobject_2_0_la_LIBADD = $(G_OBJECT_WIN32_RESOURCE) $(libglib)
72 libgobject_2_0_la_DEPENDENCIES = $(G_OBJECT_WIN32_RESOURCE) $(GOBJECT_DEF)
75 # setup source file variables
77 # GObject library header files for public installation
78 gobject_public_h_sources = \
94 gobjectnotifyqueue.c \
97 # GObject library header files that don't get installed
98 gobject_private_h_sources =
99 # GObject library C sources to build the library from
100 gobject_c_sources = \
117 # these sources (also mentioned above) are generated.
118 BUILT_SOURCES = gmarshal.h gmarshal.c gobjectalias.h
120 # non-header sources (headers should be specified in the above variables)
121 # that don't serve as direct make target sources, i.e. they don't have
122 # their own .lo rules and don't get publically installed
123 gobject_extra_sources = \
130 # setup GObject library sources and their dependancies
132 gobject_target_headers = $(gobject_public_h_sources)
133 gobject_target_sources = $(gobject_c_sources)
135 EXTRA_DIST = $(gobject_private_h_sources) $(gobject_extra_sources)
138 # rules to generate built sources
140 # setup autogeneration dependancies
141 gen_sources = xgen-gmh xgen-gmc xgen-gms
142 CLEANFILES = $(gen_sources)
144 # normal autogeneration rules
145 # all autogenerated files need to be generated in the srcdir,
146 # so old versions get remade and are not confused with newer
147 # versions in the build dir. thus a development setup requires
148 # srcdir to be writable, passing --disable-rebuilds to
149 # ../configure will supress all autogeneration rules.
152 glib_genmarshal=$(GLIB_GENMARSHAL)
154 glib_genmarshal=./glib-genmarshal
157 gmarshal.h: stamp-gmarshal.h
159 stamp-gmarshal.h: @REBUILD@ gmarshal.list glib-genmarshal$(EXEEXT)
160 $(MAKE) glib-genmarshal$(EXEEXT)
161 echo "#ifndef __G_MARSHAL_H__" > xgen-gmh \
162 && echo "#define __G_MARSHAL_H__" >> xgen-gmh \
163 && $(glib_genmarshal) --nostdinc --prefix=g_cclosure_marshal $(srcdir)/gmarshal.list --header >> xgen-gmh \
164 && echo "#endif /* __G_MARSHAL_H__ */" >> xgen-gmh \
165 && (cmp -s xgen-gmh gmarshal.h 2>/dev/null || cp xgen-gmh gmarshal.h) \
166 && rm -f xgen-gmh xgen-gmh~ \
167 && echo timestamp > $@
169 gmarshal.c: @REBUILD@ stamp-gmarshal.h
170 $(glib_genmarshal) --nostdinc --prefix=g_cclosure_marshal $(srcdir)/gmarshal.list --body >> xgen-gmc \
171 && cp xgen-gmc gmarshal.c \
172 && rm -f xgen-gmc xgen-gmc~
174 gmarshal.strings: @REBUILD@ $(srcdir)/gmarshal.list
175 grep '^[A-Z]' $(srcdir)/gmarshal.list \
176 | sed -e 's/^/"g_cclosure_marshal_/' -e 's/:/__/' -e 's/,/_/g' -e 's/$$/",/' > xgen-gms \
177 && cp xgen-gms gmarshal.strings \
178 && rm -f xgen-gms xgen-gms~
180 glib-genmarshal.o: gmarshal.strings
181 gsignal.lo: gmarshal.c
185 libgobjectinclude_HEADERS = $(gobject_target_headers)
186 libgobject_2_0_la_SOURCES = $(gobject_target_sources)
189 # programs to compile and install
191 bin_PROGRAMS = gobject-query glib-genmarshal
192 bin_SCRIPTS = glib-mkenums
193 noinst_PROGRAMS = testgobject
195 gobject_query_SOURCES = gobject-query.c
196 glib_genmarshal_SOURCES = glib-genmarshal.c
197 testgobject_SOURCES = testgobject.c
198 # link programs against libgobject
199 progs_LDADD = ./libgobject-2.0.la $(libglib)
200 glib_genmarshal_LDADD = $(libglib)
201 gobject_query_LDADD = $(progs_LDADD)
202 testgobject_LDADD = $(progs_LDADD)
224 $(G_OBJECT_WIN32_RESOURCE): gobject.rc
225 $(top_srcdir)/build/win32/lt-compile-resource gobject.rc $@
228 gobject-2.0.lib: libgobject-2.0.la gobject.def
229 lib -name:libgobject-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:gobject.def -out:$@
231 dist-hook: $(BUILT_EXTRA_DIST)
232 files='$(BUILT_EXTRA_DIST)'; \
233 for f in $$files; do \
234 if test -f $$f; then d=.; else d=$(srcdir); fi; \
235 cp $$d/$$f $(distdir) || exit 1; done
237 install-data-local: install-ms-lib install-libtool-import-lib
239 uninstall-local: uninstall-ms-lib uninstall-libtool-import-lib
242 if test $(srcdir) = .; then :; else \
243 rm -f $(BUILT_EXTRA_DIST); \