summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--makechrootpkg.in5
1 files changed, 5 insertions, 0 deletions
diff --git a/makechrootpkg.in b/makechrootpkg.in
index 7589737..83eb787 100644
--- a/makechrootpkg.in
+++ b/makechrootpkg.in
@@ -356,6 +356,11 @@ move_products() {
for s in "$copydir"/srcpkgdest/*; do
chown "$src_owner" "$s"
mv "$s" "$SRCPKGDEST"
+
+ # Fix broken symlink because of temporary chroot SRCPKGDEST /srcpkgdest
+ if [[ "$PWD" != "$SRCPKGDEST" && -L "$PWD/${s##*/}" ]]; then
+ ln -sf "$SRCPKGDEST/${s##*/}"
+ fi
done
}
# }}}