OSDN Git Service

[fix] : Fixed pkgbuild dependency resolution
authorhayao <hayao@fascode.net>
Sun, 8 Aug 2021 12:27:38 +0000 (21:27 +0900)
committerhayao <hayao@fascode.net>
Sun, 8 Aug 2021 12:27:38 +0000 (21:27 +0900)
system/pkgbuild.sh

index 9f4ce73..a68947b 100755 (executable)
@@ -99,8 +99,8 @@ readarray -t pkgbuild_dirs < <(ls "${pkgbuild_dir}" 2> /dev/null)
 if (( "${#pkgbuild_dirs[@]}" != 0 )); then
     for _dir in "${pkgbuild_dirs[@]}"; do
         cd "${_dir}"
-        readarray depends < <(source "${pkgbuild_dir}/${_dir}/PKGBUILD"; echo "${depends[@]}")
-        readarray makedepends < <(source "${pkgbuild_dir}/${_dir}/PKGBUILD"; echo "${makedepends[@]}")
+        readarray depends < <(source "${pkgbuild_dir}/${_dir}/PKGBUILD"; printf "%s\n" "${depends[@]}")
+        readarray makedepends < <(source "${pkgbuild_dir}/${_dir}/PKGBUILD"; printf "%s\n" "${makedepends[@]}")
         if (( ${#depends[@]} + ${#makedepends[@]} != 0 )); then
             for _pkg in "${depends[@]}" "${makedepends[@]}"; do
                 if pacman -Ssq "${_pkg}" | grep -x "${_pkg}" 1> /dev/null; then