diff options
author | Jasmine Hassan <[email protected]> | 2012-10-27 08:54:18 +0200 |
---|---|---|
committer | Jasmine Hassan <[email protected]> | 2012-11-16 09:45:49 +0200 |
commit | ce96467ba24b0dc13262fb5cb7ae8eb674c2099e (patch) | |
tree | d775e761c4b2004158eddb24dcca911cb664a422 /libcaja-private/Makefile.am | |
parent | 628b15b81b856d42bf00339d317cdcdc3200bbc4 (diff) | |
download | caja-ce96467ba24b0dc13262fb5cb7ae8eb674c2099e.tar.bz2 caja-ce96467ba24b0dc13262fb5cb7ae8eb674c2099e.tar.xz |
[lc-p] autogenerate marshallers
http://git.gnome.org/browse/nautilus/commit/?id=6509c91b48f52c72c868f2ca7a9b47c46b9e0bc6
Diffstat (limited to 'libcaja-private/Makefile.am')
-rw-r--r-- | libcaja-private/Makefile.am | 40 |
1 files changed, 27 insertions, 13 deletions
diff --git a/libcaja-private/Makefile.am b/libcaja-private/Makefile.am index 5db9c6e1..cbf91983 100644 --- a/libcaja-private/Makefile.am +++ b/libcaja-private/Makefile.am @@ -18,6 +18,11 @@ INCLUDES = \ $(UNIQUE_CFLAGS) \ $(NULL) +BUILT_SOURCES = \ + caja-marshal.c \ + caja-marshal.h \ + $(NULL) + dependency_static_libs = \ $(top_builddir)/cut-n-paste-code/libegg/libegg.la \ $(NULL) @@ -36,11 +41,6 @@ libcaja_private_la_LIBADD = \ $(CORE_LIBS) \ $(NULL) -marshal_sources = \ - caja-marshal.h \ - caja-marshal-guts.c \ - $(NULL) - libcaja_private_la_SOURCES = \ caja-autorun.c \ caja-autorun.h \ @@ -125,8 +125,6 @@ libcaja_private_la_SOURCES = \ caja-lib-self-check-functions.h \ caja-link.c \ caja-link.h \ - caja-marshal.c \ - caja-marshal.h \ caja-merged-directory.c \ caja-merged-directory.h \ caja-metadata.h \ @@ -195,14 +193,29 @@ libcaja_private_la_SOURCES = \ caja-undostack-manager.h \ $(NULL) +nodist_libcaja_private_la_SOURCES =\ + $(BUILT_SOURCES) \ + $(NULL) + $(lib_LTLIBRARIES): $(dependency_static_libs) -caja-marshal.h: caja-marshal.list $(GLIB_GENMARSHAL) - $(AM_V_GEN)$(GLIB_GENMARSHAL) $< --header --prefix=caja_marshal > $@ -caja-marshal-guts.c: caja-marshal.list $(GLIB_GENMARSHAL) - $(AM_V_GEN)$(GLIB_GENMARSHAL) $< --body --prefix=caja_marshal > $@ +caja-marshal.list: $(libcaja_private_la_SOURCES) Makefile.am + $(AM_V_GEN)( cd $(srcdir) && \ + sed -n -e 's/.*caja_marshal_\([[:upper:][:digit:]]*__[[:upper:][:digit:]_]*\).*/\1/p' \ + $(libcaja_private_la_SOURCES) ) \ + | sed -e 's/__/:/' -e 'y/_/,/' | sort -u > [email protected] + @if cmp -s [email protected] $@; then \ + rm [email protected]; \ + else \ + mv [email protected] $@; \ + fi + +%-marshal.h: %-marshal.list Makefile + $(AM_V_GEN)$(GLIB_GENMARSHAL) --header --prefix=$(subst -,_,$*)_marshal $< > $*-marshal.h -$(libcaja_private_la_OBJECTS): $(marshal_sources) +%-marshal.c: %-marshal.list Makefile + $(AM_V_GEN)echo "#include \"caja-marshal.h\"" > $@ && \ + $(GLIB_GENMARSHAL) --body --prefix=$(subst -,_,$*)_marshal $< >> $*-marshal.c gsettingsschema_in_files = org.mate.caja.gschema.xml.in org.mate.media-handling.gschema.xml.in gsettings_SCHEMAS = $(gsettingsschema_in_files:.xml.in=.xml) @@ -220,9 +233,10 @@ EXTRA_DIST = \ $(NULL) CLEANFILES = \ - $(marshal_sources) \ + $(BUILT_SOURCES) \ $(schema_DATA) \ $(gsettings_SCHEMAS) \ + caja-marshal.list \ $(NULL) dist-hook: |