-SUBDIRS = ragel aapl doc test contrib
+SUBDIRS = ragel doc
+DIST_SUBDIRS = $(SUBDIRS) aapl contrib examples test
-dist_doc_DATA = ChangeLog
-
-sed_script = 's/build_parsers=yes/build_parsers=no/;s/build_manual=yes/build_manual=no/;'
-
-configure = $(top_distdir)/configure
+dist_doc_DATA = CREDITS ChangeLog
+EXTRA_DIST = ragel.vim
+# This file is checked for by the configure script and its existence causes the
+# parsers and the manual to not be built when the distribution is built.
dist-hook:
- cp -p $(configure) $(configure).tmp
- cp -p $(configure).in $(configure).in.tmp
- sed $(sed_script) $(configure).tmp > $(configure)
- sed $(sed_script) $(cfgscripcfgscript).in.tmp > $(configure).in
- touch -r $(configure).tmp $(configure)
- touch -r $(configure).in.tmp $(configure)
- rm $(configure).tmp $(configure).in.tmp
+ ( \
+ echo "#!/bin/sh"; \
+ echo ""; \
+ echo "# Change to yes to enable building of parsers or manual. Reconfigure"; \
+ echo "# afterwards."; \
+ echo "build_parsers=no;"; \
+ echo "build_manual=no;"; \
+ ) > $(distdir)/DIST
+