xref: /OK3568_Linux_fs/yocto/poky/meta/recipes-graphics/fontconfig/fontconfig_2.13.1.bb (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593SmuzhiyunSUMMARY = "Generic font configuration library"
2*4882a593SmuzhiyunDESCRIPTION = "Fontconfig is a font configuration and customization library, which \
3*4882a593Smuzhiyundoes not depend on the X Window System. It is designed to locate \
4*4882a593Smuzhiyunfonts within the system and select them according to requirements \
5*4882a593Smuzhiyunspecified by applications. \
6*4882a593SmuzhiyunFontconfig is not a rasterization library, nor does it impose a \
7*4882a593Smuzhiyunparticular rasterization library on the application. The X-specific \
8*4882a593Smuzhiyunlibrary 'Xft' uses fontconfig along with freetype to specify and \
9*4882a593Smuzhiyunrasterize fonts."
10*4882a593Smuzhiyun
11*4882a593SmuzhiyunHOMEPAGE = "http://www.fontconfig.org"
12*4882a593SmuzhiyunBUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=fontconfig"
13*4882a593Smuzhiyun
14*4882a593SmuzhiyunLICENSE = "MIT & MIT & PD"
15*4882a593SmuzhiyunLIC_FILES_CHKSUM = "file://COPYING;md5=7a0449e9bc5370402a94c00204beca3d \
16*4882a593Smuzhiyun                    file://src/fcfreetype.c;endline=45;md5=5d9513e3196a1fbfdfa94051c09dfc84 \
17*4882a593Smuzhiyun                    file://src/fccache.c;beginline=1671;endline=1686;md5=0326cfeb4a7333dd4dd25fbbc4b9f27f"
18*4882a593Smuzhiyun
19*4882a593SmuzhiyunSECTION = "libs"
20*4882a593Smuzhiyun
21*4882a593SmuzhiyunDEPENDS = "expat freetype zlib gperf-native util-linux"
22*4882a593Smuzhiyun
23*4882a593SmuzhiyunSRC_URI = "http://fontconfig.org/release/fontconfig-${PV}.tar.gz \
24*4882a593Smuzhiyun           file://revert-static-pkgconfig.patch \
25*4882a593Smuzhiyun           "
26*4882a593Smuzhiyun
27*4882a593SmuzhiyunSRC_URI[md5sum] = "690c6cb840a92fa8908cdf462d19ec66"
28*4882a593SmuzhiyunSRC_URI[sha256sum] = "9f0d852b39d75fc655f9f53850eb32555394f36104a044bb2b2fc9e66dbbfa7f"
29*4882a593Smuzhiyun
30*4882a593SmuzhiyunUPSTREAM_CHECK_REGEX = "fontconfig-(?P<pver>\d+\.\d+\.(?!9\d+)\d+)"
31*4882a593Smuzhiyun
32*4882a593Smuzhiyundo_configure:prepend() {
33*4882a593Smuzhiyun    # work around https://bugs.freedesktop.org/show_bug.cgi?id=101280
34*4882a593Smuzhiyun    rm -f ${S}/src/fcobjshash.h ${S}/src/fcobjshash.gperf
35*4882a593Smuzhiyun}
36*4882a593Smuzhiyun
37*4882a593Smuzhiyundo_install:append:class-target() {
38*4882a593Smuzhiyun    # duplicate fc-cache for postinstall script
39*4882a593Smuzhiyun    mkdir -p ${D}${libexecdir}
40*4882a593Smuzhiyun    ln ${D}${bindir}/fc-cache ${D}${libexecdir}/${MLPREFIX}fc-cache
41*4882a593Smuzhiyun}
42*4882a593Smuzhiyun
43*4882a593Smuzhiyundo_install:append:class-nativesdk() {
44*4882a593Smuzhiyun    # duplicate fc-cache for postinstall script
45*4882a593Smuzhiyun    mkdir -p ${D}${libexecdir}
46*4882a593Smuzhiyun    ln ${D}${bindir}/fc-cache ${D}${libexecdir}/${MLPREFIX}fc-cache
47*4882a593Smuzhiyun}
48*4882a593Smuzhiyun
49*4882a593SmuzhiyunPACKAGES =+ "fontconfig-utils"
50*4882a593SmuzhiyunFILES:${PN} =+ "${datadir}/xml/*"
51*4882a593SmuzhiyunFILES:${PN}-dev += "${datadir}/gettext/*"
52*4882a593SmuzhiyunFILES:fontconfig-utils = "${bindir}/* ${libexecdir}/*"
53*4882a593Smuzhiyun
54*4882a593Smuzhiyun# Work around past breakage in debian.bbclass
55*4882a593SmuzhiyunRPROVIDES:fontconfig-utils = "libfontconfig-utils"
56*4882a593SmuzhiyunRREPLACES:fontconfig-utils = "libfontconfig-utils"
57*4882a593SmuzhiyunRCONFLICTS:fontconfig-utils = "libfontconfig-utils"
58*4882a593SmuzhiyunDEBIAN_NOAUTONAME:fontconfig-utils = "1"
59*4882a593Smuzhiyun
60*4882a593Smuzhiyuninherit autotools pkgconfig relative_symlinks gettext
61*4882a593Smuzhiyun
62*4882a593SmuzhiyunFONTCONFIG_CACHE_DIR ?= "${localstatedir}/cache/fontconfig"
63*4882a593Smuzhiyun
64*4882a593Smuzhiyun# comma separated list of additional directories
65*4882a593Smuzhiyun# /usr/share/fonts is already included by default (you can change it with --with-default-fonts)
66*4882a593SmuzhiyunFONTCONFIG_FONT_DIRS ?= "no"
67*4882a593Smuzhiyun
68*4882a593SmuzhiyunEXTRA_OECONF = " --disable-docs --with-default-fonts=${datadir}/fonts --with-cache-dir=${FONTCONFIG_CACHE_DIR} --with-add-fonts=${FONTCONFIG_FONT_DIRS}"
69*4882a593Smuzhiyun
70*4882a593SmuzhiyunBBCLASSEXTEND = "native nativesdk"
71