Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndres P <aepd87@gmail.com>2010-05-23 09:02:57 -0430
committerAllan McRae <allan@archlinux.org>2010-06-17 14:34:57 +1000
commitc71fe7db42cd733e85965b11b887762cfd99a981 (patch)
tree0597f46e1db4d441d4a03dd6739e2a341192877b
parent0e96532096a1ce44801474798909527b522c05cd (diff)
makepkg: use printf when writing pkginfo
Signed-off-by: Andres P <aepd87@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
-rw-r--r--scripts/makepkg.sh.in34
1 files changed, 9 insertions, 25 deletions
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
index 42b9cf83..6763b6e0 100644
--- a/scripts/makepkg.sh.in
+++ b/scripts/makepkg.sh.in
@@ -920,31 +920,15 @@ write_pkginfo() {
echo "force = true"
fi
- local it
- for it in "${license[@]}"; do
- echo "license = $it"
- done
- for it in "${replaces[@]}"; do
- echo "replaces = $it"
- done
- for it in "${groups[@]}"; do
- echo "group = $it"
- done
- for it in "${depends[@]}"; do
- echo "depend = $it"
- done
- for it in "${optdepends[@]}"; do
- echo "optdepend = $it"
- done
- for it in "${conflicts[@]}"; do
- echo "conflict = $it"
- done
- for it in "${provides[@]}"; do
- echo "provides = $it"
- done
- for it in "${backup[@]}"; do
- echo "backup = $it"
- done
+ [[ $license ]] && printf "license = %s\n" "${license[@]}"
+ [[ $replaces ]] && printf "replaces = %s\n" "${replaces[@]}"
+ [[ $groups ]] && printf "group = %s\n" "${groups[@]}"
+ [[ $depends ]] && printf "depend = %s\n" "${depends[@]}"
+ [[ $optdepend ]] && printf "optdepend = %s\n" "${optdepends[@]}"
+ [[ $conflict ]] && printf "conflict = %s\n" "${conflicts[@]}"
+ [[ $provides ]] && printf "provides = %s\n" "${provides[@]}"
+ [[ $backup ]] && printf "backup = %s\n" "${backup[@]}"
+
for it in "${packaging_options[@]}"; do
local ret="$(check_option $it)"
if [[ $ret != "?" ]]; then