examples: automatically copy all examples in dist and install it to docdir
diff --git a/openbsc/doc/examples/Makefile.am b/openbsc/doc/examples/Makefile.am
new file mode 100644
index 0000000..b7eda49
--- /dev/null
+++ b/openbsc/doc/examples/Makefile.am
@@ -0,0 +1,16 @@
+
+CFG_FILES = find $(srcdir) -name '*.cfg*' | sed -e 's,^$(srcdir),,'
+
+dist-hook:
+	for f in $$($(CFG_FILES)); do \
+		j="$(distdir)/$$f" && \
+		mkdir -p "$$(dirname $$j)" && \
+		$(INSTALL_DATA) $(srcdir)/$$f $$j; \
+	done
+
+install-data-hook:
+	for f in $$($(CFG_FILES)); do \
+		j="$(DESTDIR)$(docdir)/examples/$$f" && \
+		mkdir -p "$$(dirname $$j)" && \
+		$(INSTALL_DATA) $(srcdir)/$$f $$j; \
+	done