1
# Rules for generating marshal files using glib-genmarshal
4
# glib_marshal_list = marshal list file
5
# glib_marshal_prefix = prefix for marshal functions
7
# before including Makefile.am.marshal. You will also need to have
8
# the following targets already defined:
15
# Author: Emmanuele Bassi <ebassi@linux.intel.com>
18
$(if $(GLIB_GENMARSHAL),,$(error Need to define GLIB_GENMARSHAL))
20
$(if $(or $(glib_marshal_list), \
21
$(glib_marshal_prefix)),, \
22
$(error Need to define glib_marshal_list and glib_marshal_prefix))
24
marshal_h = $(glib_marshal_list:.list=.h)
25
marshal_c = $(glib_marshal_list:.list=.c)
26
marshal_list = $(addprefix $(srcdir)/, $(glib_marshal_list))
28
CLEANFILES += stamp-marshal
29
DISTCLEANFILES += $(marshal_h) $(marshal_c)
30
BUILT_SOURCES += $(marshal_h) $(marshal_c)
31
EXTRA_DIST += $(marshal_list)
33
stamp-marshal: $(marshal_list)
34
$(AM_V_GEN)$(GLIB_GENMARSHAL) \
35
--prefix=$(glib_marshal_prefix) \
37
--valist-marshallers \
38
$(marshal_list) > xgen-mh \
39
&& (cmp -s xgen-mh $(marshal_h) || cp -f xgen-mh $(marshal_h)) \
41
&& echo timestamp > $(@F)
43
$(marshal_h): stamp-marshal
46
$(marshal_c): $(marshal_h)
47
$(AM_V_GEN)$(GLIB_GENMARSHAL) \
48
--prefix=$(glib_marshal_prefix) \
50
--valist-marshallers \
52
$(marshal_list) > xgen-mc \
53
&& (cmp -s xgen-mc $(marshal_c) || cp -f xgen-mc $(marshal_c)) \