summaryrefslogtreecommitdiff
path: root/openvpn/Makefile.am
diff options
context:
space:
mode:
authorArne Schwabe <arne@rfc2549.org>2012-06-02 15:45:11 +0200
committerArne Schwabe <arne@rfc2549.org>2012-06-02 15:45:11 +0200
commitec2008e9e53b99ba1725d8398e21b9cb04f6b8ca (patch)
tree8498bf1722b27ae47a5cec27c7f6cf5ecb868bb3 /openvpn/Makefile.am
parentb84e3939a015b42c316af0b63297932e6fcf8ba4 (diff)
bring openvpn in sync with openvpn git master and patches submitted to mailing list
Diffstat (limited to 'openvpn/Makefile.am')
-rw-r--r--openvpn/Makefile.am24
1 files changed, 24 insertions, 0 deletions
diff --git a/openvpn/Makefile.am b/openvpn/Makefile.am
index ab3e3d2e..c5805797 100644
--- a/openvpn/Makefile.am
+++ b/openvpn/Makefile.am
@@ -40,19 +40,33 @@ MAINTAINERCLEANFILES = \
$(srcdir)/depcomp $(srcdir)/aclocal.m4 \
$(srcdir)/config.guess $(srcdir)/config.sub
+CLEANFILES = \
+ config-version.h
+
EXTRA_DIST = \
contrib \
debug
+.PHONY: config-version.h
+
+if GIT_CHECKOUT
+BUILT_SOURCES = \
+ config-version.h
+endif
+
SUBDIRS = build distro include src sample doc tests
dist_doc_DATA = \
+ README \
+ README.IPv6 \
+ README.polarssl \
COPYRIGHT.GPL \
COPYING
dist_noinst_DATA = \
.gitignore \
.gitattributes \
+ config-version.h.in \
PORTS \
README.IPv6 TODO.IPv6 \
README.polarssl \
@@ -75,3 +89,13 @@ if WIN32
rootdir=$(prefix)
root_DATA = version.sh
endif
+
+config-version.h:
+ @CONFIGURE_GIT_REVISION="`GIT_DIR=\"$(top_srcdir)/.git\" $(GIT) rev-parse --symbolic-full-name HEAD`/`GIT_DIR=\"$(top_srcdir)/.git\" $(GIT) rev-parse --short=16 HEAD`"; \
+ $(SED) "s#@CONFIGURE_GIT_REVISION[@]#$${CONFIGURE_GIT_REVISION}#g" "$(srcdir)/config-version.h.in" > config-version.h.tmp
+ @if ! [ -f config-version.h ] || ! cmp -s config-version.h.tmp config-version.h; then \
+ echo "replacing config-version.h"; \
+ mv config-version.h.tmp config-version.h; \
+ else \
+ rm -f config-version.h.tmp; \
+ fi