summaryrefslogtreecommitdiffstats
path: root/Makefile.am
diff options
context:
space:
mode:
authorNiels de Vos <ndevos@redhat.com>2015-06-17 23:33:25 +0200
committerNiels de Vos <ndevos@redhat.com>2015-06-28 07:46:52 -0700
commit5f76ff1beaaf1fd1c85c43a166c289f9094a379b (patch)
tree6165b2b195f1b6b7dff1e10d3859e625ed46bad2 /Makefile.am
parentfb2f25cfbc26cd61370742d2453db63185194982 (diff)
build: always include the VERSION file in 'make dist'
Building a 'make dist' tarball from a non-git directory fails to include the VERSION file. This subsequently fails to set the version in the installation directories (for the xlators) and the RPM packaging can not find the correct files. This change makes sure to include a VERSION file in the 'make dist' tarball, no matter from where 'make dist' is run. It mainly addresses this use case: $ git clone ... && cd glusterfs $ ./autogen.sh $ mkdir /tmp/workdir $ cd /tmp/workdir $ $OLDPWD/configure $ make dist Change-Id: I3e87b5e16118b68d065fe99790d4b17e0cef9189 BUG: 1198849 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/11297 Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org>
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am7
1 files changed, 4 insertions, 3 deletions
diff --git a/Makefile.am b/Makefile.am
index 4dcf08c..900b5fe 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -52,7 +52,8 @@ gen-ChangeLog:
(cd $(srcdir) && git diff && echo ===== git log ==== && git log) > $(distdir)/ChangeLog
gen-VERSION:
- if test -d .git; then \
- $(top_srcdir)/build-aux/pkg-version --full \
- > $(distdir)/VERSION; \
+ if test -d $(top_srcdir)/.git; then \
+ cd $(top_srcdir); \
+ ./build-aux/pkg-version --full \
+ > $(abs_top_builddir)/$(distdir)/VERSION; \
fi