Skip to content

Commit ded7077

Browse files
committed
Fix 'make dist' so it handles the submodule correctly
Also ensures that loose files aren't included from subdirectories, since we were using tar without --no-recurse before.
1 parent 9a343c7 commit ded7077

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

Makefile

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -138,9 +138,12 @@ dist-common: clean
138138
@if [ -n "`git ls-files --exclude-standard --others`" ]; then echo >&2 "WARNING: git working tree has unstaged files which were IGNORED!"; fi
139139
@echo $(GITHASH) > .distgitrev
140140
@git name-rev --tags --name-only `cat .distgitrev` > .distgittag
141-
@git ls-tree -r -t --full-tree HEAD --name-only |\
142-
tar cjf "${distdir}.tar.bz2" --transform="s|^|${distdir}/|" -T - \
143-
.distgitrev .distgittag
141+
@(git ls-tree -r -t --full-tree HEAD --name-only \
142+
&& cd pglogical_dump\
143+
&& git ls-tree -r -t --full-tree HEAD --name-only | sed 's/^/pglogical_dump\//'\
144+
) |\
145+
tar cjf "${distdir}.tar.bz2" --transform="s|^|${distdir}/|" --no-recursion \
146+
-T - .distgitrev .distgittag
144147
@echo >&2 "Prepared ${distdir}.tar.bz2 for rev=`cat .distgitrev`, tag=`cat .distgittag`"
145148
@rm -f .distgitrev .distgittag
146149
@md5sum "${distdir}.tar.bz2" > "${distdir}.tar.bz2.md5"

0 commit comments

Comments
 (0)