Commit 99a7271e authored by Mike Gabriel's avatar Mike Gabriel

roll-tarball.sh: Make sure symlinked files are included in tarballs.

As the system a tarball gets extracted on may potentially be unable to handle symlinks, we ship symlinks as files in the rolled tarball. By transforming symlinks into real files, we also assure that all VERSION files/symlinks get shipped in the tarballs. Fixes ArcticaProject/nx-libs#27
parent 0897c062
...@@ -78,6 +78,20 @@ echo "Created tarball for $CHECKOUT" ...@@ -78,6 +78,20 @@ echo "Created tarball for $CHECKOUT"
cd "${TEMP_DIR}/${PROJECT}-${RELEASE}/" cd "${TEMP_DIR}/${PROJECT}-${RELEASE}/"
set -x
# Replace symlinks by copies of the linked target files
# Note: We don't have symlinked directories!!!
find . -type l | while read link; do
TARGET=$(readlink "$link")
cd $(dirname $link)
if [ -f "$TARGET" ]; then
rm -f $(basename $link)
cp ${TARGET} $(basename $link)
fi
cd - 1>/dev/null
done
set +x
mkdir -p "doc/applied-patches" mkdir -p "doc/applied-patches"
# prepare patches for lite and full tarball # prepare patches for lite and full tarball
...@@ -95,6 +109,7 @@ else ...@@ -95,6 +109,7 @@ else
rm -Rf "etc"* rm -Rf "etc"*
rm -Rf "doc/nx-X11_vs_XOrg69_patches"* rm -Rf "doc/nx-X11_vs_XOrg69_patches"*
rm -f "README.keystrokes" rm -f "README.keystrokes"
rm -f "VERSION.x2goagent"
cat "debian/patches/series" | sort | grep -v '^#' | egrep "([0-9]+(_|-).*\.full\+lite\.patch)" | while read file cat "debian/patches/series" | sort | grep -v '^#' | egrep "([0-9]+(_|-).*\.full\+lite\.patch)" | while read file
do do
cp -v "debian/patches/$file" "doc/applied-patches/" cp -v "debian/patches/$file" "doc/applied-patches/"
...@@ -114,9 +129,6 @@ rm -Rf ".pc/" ...@@ -114,9 +129,6 @@ rm -Rf ".pc/"
rm -Rf "debian/" rm -Rf "debian/"
rm -Rf "nx-libs.spec" rm -Rf "nx-libs.spec"
# some file renamings
mv README.md README.NX-Development
# very old release did not add any README # very old release did not add any README
for f in $(ls README* 2>/dev/null); do for f in $(ls README* 2>/dev/null); do
mv -v "$f" "doc/"; mv -v "$f" "doc/";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment