Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2017-06-29 11:44:29 +0200
committerErich Eckner <git@eckner.net>2017-06-29 11:44:29 +0200
commitd39cea2a852127db12fe09f821e4581fd052cd2c (patch)
treeabdb3875cb22ab8c74f27535c638f95b3aad2874 /bin
parentee4e197d6fe0ccb11b6ce03de92ab44af531957a (diff)
bin/common-functions: *.needs now contains build- and runtime dependencies
Diffstat (limited to 'bin')
-rwxr-xr-xbin/common-functions21
1 files changed, 9 insertions, 12 deletions
diff --git a/bin/common-functions b/bin/common-functions
index edec2fe..2e55d5b 100755
--- a/bin/common-functions
+++ b/bin/common-functions
@@ -159,18 +159,6 @@ generate_package_metadata() {
sort -u > \
"${file_prefix}.packages"
- # extract "needs" = depends \setminus "builds"
- (
- grep "$(printf '^\tdepends = ')" "${file_prefix}.SRCINFO" | \
- cut -d= -f2 | \
- sed 's|^\s\+||; s|[<>]$||' | \
- sort -u
- sed 'p' "${file_prefix}.builds"
- ) | \
- sort | \
- uniq -u > \
- "${file_prefix}.needs"
-
# extract "depends" = makedepends \cup checkdepends \cup depends
(
sed -n "$(printf '/^pkgname = /q;/^\tdepends = /p')" "${file_prefix}.SRCINFO"
@@ -181,6 +169,15 @@ generate_package_metadata() {
sort -u > \
"${file_prefix}.depends"
+ # extract "needs" = "depends" \setminus "builds"
+ (
+ cat "${file_prefix}.depends"
+ sed 'p' "${file_prefix}.builds"
+ ) | \
+ sort | \
+ uniq -u > \
+ "${file_prefix}.needs"
+
rm "${file_prefix}.SRCINFO"
}