diff options
author | Zach van Rijn <me@zv.io> | 2023-04-10 14:46:06 -0700 |
---|---|---|
committer | Zach van Rijn <me@zv.io> | 2023-04-10 14:51:22 -0700 |
commit | 2caf479a2af09f1719eb979ab72eacd9ebaac776 (patch) | |
tree | 628e860623be7da1aa5171e9f8ff044064d78a87 | |
parent | a3466aa28681d976dc9c4aea0fe2ef635807dc94 (diff) | |
download | packages-2caf479a2af09f1719eb979ab72eacd9ebaac776.tar.gz packages-2caf479a2af09f1719eb979ab72eacd9ebaac776.tar.bz2 packages-2caf479a2af09f1719eb979ab72eacd9ebaac776.tar.xz packages-2caf479a2af09f1719eb979ab72eacd9ebaac776.zip |
user/ttf-noto: avoid using 'cp -n'. fixes #990.
The behavior of 'cp -n' (and others) changed in coreutils 9.2;
we bumped to it in 3a2b5420c965d86ea5861036adde8bdcdb8fb471.
See also: https://bugs.gnu.org/62572
Relbump because of the previous non-deterministic glob, whereas
this commit will reliably sort candidate fonts before copying.
-rw-r--r-- | user/ttf-noto/APKBUILD | 35 |
1 files changed, 14 insertions, 21 deletions
diff --git a/user/ttf-noto/APKBUILD b/user/ttf-noto/APKBUILD index 94a87560b..54e7c3e9f 100644 --- a/user/ttf-noto/APKBUILD +++ b/user/ttf-noto/APKBUILD @@ -3,7 +3,7 @@ pkgname=ttf-noto pkgver=20220420 _commit=c8729a9e61b2a54a9d2b4c61a82d4d93213bd6e3 -pkgrel=0 +pkgrel=1 pkgdesc="Noto font family" url="https://www.google.com/get/noto/" arch="noarch" @@ -24,31 +24,24 @@ builddir="$srcdir"/noto-fonts-$_commit package() { mkdir -p "$pkgdir"/usr/share/fonts/$pkgname/ mkdir -p "$pkgdir"/etc/fonts/conf.d/ - # FIXME: no-clobber is a kludge to get past these duplicate-named fonts: + + ## + # FIXME: some fonts have duplicate names; we copy + # new files (and skip ones that may already exist) + # # $ find . -type f -name "*.ttf" | cut -d/ -f3 | sort | uniq -d | while read k; do find . -type f -name "${k}"; done | sort # ./NotoSansTifinagh/NotoSansTifinaghAPT-Regular.ttf # ./NotoSansTifinagh/NotoSansTifinaghAdrar-Regular.ttf - # ./NotoSansTifinagh/NotoSansTifinaghAgrawImazighen-Regular.ttf - # ./NotoSansTifinagh/NotoSansTifinaghAhaggar-Regular.ttf - # ./NotoSansTifinagh/NotoSansTifinaghAir-Regular.ttf - # ./NotoSansTifinagh/NotoSansTifinaghAzawagh-Regular.ttf - # ./NotoSansTifinagh/NotoSansTifinaghGhat-Regular.ttf - # ./NotoSansTifinagh/NotoSansTifinaghHawad-Regular.ttf - # ./NotoSansTifinagh/NotoSansTifinaghRhissaIxa-Regular.ttf - # ./NotoSansTifinagh/NotoSansTifinaghSIL-Regular.ttf - # ./NotoSansTifinagh/NotoSansTifinaghTawellemmet-Regular.ttf - # ./NotoSansTifinaghAPT/NotoSansTifinaghAPT-Regular.ttf - # ./NotoSansTifinaghAdrar/NotoSansTifinaghAdrar-Regular.ttf - # ./NotoSansTifinaghAgrawImazighen/NotoSansTifinaghAgrawImazighen-Regular.ttf - # ./NotoSansTifinaghAhaggar/NotoSansTifinaghAhaggar-Regular.ttf - # ./NotoSansTifinaghAir/NotoSansTifinaghAir-Regular.ttf - # ./NotoSansTifinaghAzawagh/NotoSansTifinaghAzawagh-Regular.ttf - # ./NotoSansTifinaghGhat/NotoSansTifinaghGhat-Regular.ttf - # ./NotoSansTifinaghHawad/NotoSansTifinaghHawad-Regular.ttf - # ./NotoSansTifinaghRhissaIxa/NotoSansTifinaghRhissaIxa-Regular.ttf + # ... # ./NotoSansTifinaghSIL/NotoSansTifinaghSIL-Regular.ttf # ./NotoSansTifinaghTawellemmet/NotoSansTifinaghTawellemmet-Regular.ttf - cp -n "$builddir"/hinted/ttf/*/*.ttf "$pkgdir"/usr/share/fonts/$pkgname/ + # + # Avoid using 'cp -n'. See #990 for more information. + find "$builddir"/hinted/ttf/ -name "*.ttf" | sort | while read k; do + if ! test -f "$pkgdir"/usr/share/fonts/$pkgname/${k##*/}; then + cp -v ${k} "$pkgdir"/usr/share/fonts/$pkgname/; + fi + done cp "$srcdir"/*.conf "$pkgdir"/etc/fonts/conf.d/ } |