scripted-diff: [build] Ensure source tarball has leading directory name

-BEGIN VERIFY SCRIPT-
sed -i 's|git archive --|git archive --prefix="${DISTNAME}/" --|g'                          $(git grep -l 'git archive' ./contrib)
sed -i 's|tar -xf "\?${\?GIT_ARCHIVE}\?"\?|tar --strip-components=1 -xf "${GIT_ARCHIVE}"|g' $(git grep -l 'tar -xf'     ./contrib)
-END VERIFY SCRIPT-
This commit is contained in:
MarcoFalke
2020-11-05 17:30:05 +01:00
parent 9bb078351b
commit faa2f06f5e
4 changed files with 8 additions and 8 deletions

View File

@@ -158,7 +158,7 @@ GIT_ARCHIVE="${OUTDIR}/src/${DISTNAME}.tar.gz"
# Create the source tarball if not already there
if [ ! -e "$GIT_ARCHIVE" ]; then
mkdir -p "$(dirname "$GIT_ARCHIVE")"
git archive --output="$GIT_ARCHIVE" HEAD
git archive --prefix="${DISTNAME}/" --output="$GIT_ARCHIVE" HEAD
fi
###########################
@@ -193,7 +193,7 @@ export PATH="${BASEPREFIX}/${HOST}/native/bin:${PATH}"
cd "$DISTSRC"
# Extract the source tarball
tar -xf "${GIT_ARCHIVE}"
tar --strip-components=1 -xf "${GIT_ARCHIVE}"
./autogen.sh