# Because some files are needed by plugins
# in the buildir like .plugin files this
# copies them to the builddir if they don't
# exist so that make distcheck works.
all-local:
	@test -z "$(noinst_PLUGIN)" || \
	 for plugin in $(noinst_PLUGIN) ; do \
	   if test -e $(srcdir)/$$plugin ; then \
	     if ! test -e $(builddir)/$$plugin ; then \
	       cp -p $(srcdir)/$$plugin $(builddir)/ ; \
	     fi ; \
	   fi ; \
	 done

clean-local:
	@rm -f gschemas.compiled ; \
	 test -z "$(noinst_PLUGIN)" || \
	 test $(srcdir) = $(builddir) || \
	 for plugin in $(noinst_PLUGIN) ; do \
	   if test -e $(builddir)/$$plugin ; then \
	     rm -f $(builddir)/$$plugin ; \
	   fi ; \
	 done
