From e006e076c17b41ee1b8903ecdf6e0169e25cc1ce Mon Sep 17 00:00:00 2001 From: Allan McRae Date: Wed, 9 Jun 2010 13:45:22 +1000 Subject: [PATCH] Fix creation of source packages Source packages were getting created with only links to local source files. Also, fix error when install and changelog files are in the source array. Signed-off-by: Allan McRae --- scripts/makepkg.sh.in | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index 8d6d1f6..86984db 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -1096,7 +1096,7 @@ create_srcpackage() { for file in "${source[@]}"; do if [[ -f $file ]]; then msg2 "$(gettext "Adding %s...")" "$file" - ln -s "$file" "$srclinks/$pkgbase" + ln -s "${startdir}/$file" "$srclinks/$pkgbase" elif (( SOURCEONLY == 2 )); then local absfile=$(get_filepath "$file") || missing_source_file "$file" msg2 "$(gettext "Adding %s...")" "${absfile##*/}" @@ -1110,9 +1110,9 @@ create_srcpackage() { local file for file in ${!i}; do # evaluate any bash variables used - eval file='${srclinks}/${pkgbase}/'${file} - if [[ ! -f $file ]]; then - msg2 "$(gettext "Adding %s file (%s)...")" "$i" "${file##*/}" + eval file=${file} + if [[ ! -f "${srclinks}/${pkgbase}/$file" ]]; then + msg2 "$(gettext "Adding %s file (%s)...")" "$i" "${file}" ln -s "${startdir}/$file" "${srclinks}/${pkgbase}/" fi done -- 1.7.1