From 36413aa856a7cace1851679c1398403b30417e80 Mon Sep 17 00:00:00 2001 From: Allan McRae Date: Sun, 8 Jan 2012 21:48:04 +1000 Subject: makepkg: simplify source archive generation Simplify the source tarball generation by unifying the handling of local and remote files. This also allows local files to be found in $SRCDEST (FS#26580) and makepkg will abort on missing local source files (only possible to trigger in combination with --skipinteg). Signed-off-by: Allan McRae Signed-off-by: Dan McGee --- scripts/makepkg.sh.in | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index 7cf4844d..d25582f3 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -1334,11 +1334,9 @@ create_srcpackage() { local file for file in "${source[@]}"; do - if [[ -f $file ]]; then - msg2 "$(gettext "Adding %s...")" "$file" - ln -s "${startdir}/$file" "$srclinks/$pkgbase" - elif (( SOURCEONLY == 2 )); then - local absfile=$(get_filepath "$file") || missing_source_file "$file" + if [[ "$file" == $(get_filename "$file") ]] || (( SOURCEONLY == 2 )); then + local absfile + absfile=$(get_filepath "$file") || missing_source_file "$file" msg2 "$(gettext "Adding %s...")" "${absfile##*/}" ln -s "$absfile" "$srclinks/$pkgbase" fi -- cgit v1.2.3-24-g4f1b