summaryrefslogtreecommitdiff
path: root/pin-dependencies.PKGBUILDpatch
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2019-01-04 16:07:39 +0100
committerErich Eckner <git@eckner.net>2019-01-04 16:07:39 +0100
commit344ad656e75fc61525db7e58e692d7a9412a740e (patch)
tree9ac45621c7e5d5be08ea728849993852918ef7de /pin-dependencies.PKGBUILDpatch
parent86fef610b81f830412652835f1cf40ed1f11158c (diff)
downloadarchlinuxewe-344ad656e75fc61525db7e58e692d7a9412a740e.tar.xz
pin-dependencies.PKGBUILDpatch: only run for non-any packages
Diffstat (limited to 'pin-dependencies.PKGBUILDpatch')
-rw-r--r--pin-dependencies.PKGBUILDpatch62
1 files changed, 32 insertions, 30 deletions
diff --git a/pin-dependencies.PKGBUILDpatch b/pin-dependencies.PKGBUILDpatch
index a21ba0592..54553a7d4 100644
--- a/pin-dependencies.PKGBUILDpatch
+++ b/pin-dependencies.PKGBUILDpatch
@@ -1,33 +1,35 @@
-_depends=(
- $(
- {
- printf '%s\n' "${depends[@]}"
- find "${pkgdir}" -type f -exec objdump -x {} \; 2>/dev/null \
+if printf '%s\n' "${arch[@]}" | grep -qvxF any; then
+ _depends=(
+ $(
+ {
+ printf '%s\n' "${depends[@]}"
+ find "${pkgdir}" -type f -exec objdump -x {} \; 2>/dev/null \
+ | sed '
+ s/^\s*NEEDED\s\+\(\S\+\)\s*$/\1/
+ t
+ d
+ ' \
+ | sort -u \
+ | while read -r _lib; do
+ pacman -Qqo "/usr/lib/${_lib}" 2>/dev/null || true
+ done \
+ | sort -u \
+ | xargs -r pacman -Q \
+ | sed '
+ s/ \([^-]\+\)-[^-]\+$/=\1/
+ t
+ w /dev/stderr
+ d
+ '
+ } \
| sed '
- s/^\s*NEEDED\s\+\(\S\+\)\s*$/\1/
- t
- d
+ s/^\([^=[:space:]]\+\)\(=\(\S\+\)\)\?$/\0 \1 \3/
' \
- | sort -u \
- | while read -r _lib; do
- pacman -Qqo "/usr/lib/${_lib}" 2>/dev/null || true
- done \
- | sort -u \
- | xargs -r pacman -Q \
- | sed '
- s/ \([^-]\+\)-[^-]\+$/=\1/
- t
- w /dev/stderr
- d
- '
- } \
- | sed '
- s/^\([^=[:space:]]\+\)\(=\(\S\+\)\)\?$/\0 \1 \3/
- ' \
- | sort -k2,2 -k3Vr,3 \
- | cut -d' ' -f1,2 \
- | uniq -f1 \
- | cut -d' ' -f1
+ | sort -k2,2 -k3Vr,3 \
+ | cut -d' ' -f1,2 \
+ | uniq -f1 \
+ | cut -d' ' -f1
+ )
)
-)
-depends=("${_depends[@]}")
+ depends=("${_depends[@]}")
+fi