blob: cdbebcf788baf10728f3f00f6caad945bc1ed706 [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001HOMEPAGE = "http://www.x.org"
2BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=xorg"
3
4SECTION = "x11/fonts"
5LICENSE = "MIT-X"
6
Brad Bishop6e60e8b2018-02-01 10:27:11 -05007DEPENDS = " encodings font-alias font-util-native"
Patrick Williamsc124f4f2015-09-15 14:41:29 -05008RDEPENDS_${PN} = "encodings font-util font-alias"
9
10XORG_PN = "${BPN}"
11INC_PR = "r2"
12
13
14SRC_URI = "${XORG_MIRROR}/individual/font/${XORG_PN}-${PV}.tar.bz2"
15S = "${WORKDIR}/${XORG_PN}-${PV}"
16
17inherit autotools pkgconfig distro_features_check
18
19# The mkfontscale-native requires x11 in DISTRO_FEATURES
20REQUIRED_DISTRO_FEATURES = "x11"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050021
22EXTRA_OEMAKE += "FCCACHE=/bin/true UTIL_DIR=${STAGING_DIR_TARGET}\$\(MAPFILES_PATH\)"
23
24do_install_append() {
25 find ${D}${libdir}/X11/fonts -type f -name fonts.dir | xargs rm -f
26 find ${D}${libdir}/X11/fonts -type f -name fonts.scale | xargs rm -f
27 find ${D}${datadir}/fonts/X11 -type f -name fonts.dir | xargs rm -f
28 find ${D}${datadir}/fonts/X11 -type f -name fonts.scale | xargs rm -f
29}
30
31FILES_${PN} += " ${libdir}/X11/fonts ${datadir}"
32
Brad Bishop6e60e8b2018-02-01 10:27:11 -050033PACKAGE_WRITE_DEPS += "mkfontdir-native mkfontscale-native"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050034pkg_postinst_${PN} () {
35 for fontdir in `find $D/usr/lib/X11/fonts -type d`; do
36 mkfontdir $fontdir
37 mkfontscale $fontdir
38 done
39 for fontdir in `find $D/usr/share/fonts/X11 -type d`; do
40 mkfontdir $fontdir
41 mkfontscale $fontdir
42 done
43}