void-packages/srcpkgs/noto-fonts-ttf/template

41 lines
1.4 KiB
Bash

# Template file for 'noto-fonts-ttf'
pkgname=noto-fonts-ttf
version=20220810
revision=1
_githash=2725c70baa8b0176c7577093ba1fc6179aa79478
depends="font-util"
short_desc="Google Noto TTF Fonts"
maintainer="classabbyamp <void@placeviolette.net>"
license="OFL-1.1"
homepage="https://www.google.com/get/noto/"
# XXX: change to https://github.com/notofonts/notofonts.github.io/tree/main/fonts when migration is complete
# also see https://github.com/notofonts/noto-fonts/issues/2388
distfiles="https://github.com/notofonts/noto-fonts/archive/${_githash}.tar.gz"
checksum=c1238ca0fc1e954ee2be444cafd53c033b13fa93f8a1e88f7137e9e028e6891e
font_dirs="/usr/share/fonts/noto"
do_install() {
# remove duplicates
rm hinted/ttf/NotoSansTifinagh/NotoSansTifinagh[AGHRST]*.ttf
vmkdir usr/share/fonts/noto
vcopy "hinted/ttf/Noto*/*" usr/share/fonts/noto
vlicense LICENSE
}
noto-fonts-ttf-extra_package() {
depends="${sourcepkg}>=${version}_${revision}"
short_desc+=" - additional variants"
pkg_install() {
vmove "usr/share/fonts/noto/Noto*-*Condensed*.ttf"
vmove "usr/share/fonts/noto/Noto*-*Thin*.ttf"
vmove "usr/share/fonts/noto/Noto*-*Light*.ttf"
# keep *-Regular*
vmove "usr/share/fonts/noto/Noto*-*Medium*.ttf"
vmove "usr/share/fonts/noto/Noto*-*SemiBold*.ttf"
# keep *-Bold*
vmove "usr/share/fonts/noto/Noto*-*ExtraBold*.ttf"
vmove "usr/share/fonts/noto/Noto*-*Black*.ttf"
}
}