generic-poky/meta/recipes-graphics/xorg-font
Gratian Crisan d2259ac280 encodings: Add dependency to mkfontdir-native
Currently adding a font recipe to an image doesn't have enough
dependencies to cause mkfontdir-native to be included in the native
sysroot. This creates problems with the postinstall scripts for fonts
which call mkfontdir to create font index files: font.dir. The end
result is missing font.dir files in the built image and a malfunctioning
font system.

Dependencies for the relevant recipes currently look like this:

  * <font.bb>   [D ] -> font-util-native
                [R ] -> encodings, font-util
                [RN] -> font-util-native

  * font-util   [D ] -> encodings
                [R ] -> mkfontdir, mkfontscale, encodings
                [RN] -> mkfontdir-native, mkfontscale-native

  * encodings   [D ] -> mkfontscale-native, font-util-native

  * mkfontdir   [R ] -> mkfontscale
                [RN] -> mkfontscale-native

  * mkfontscale [D ] -> libfontenc

  * libfontenc  [D ] -> font-util

Where:
  * D = DEPENDS
  * R = RDEPENDS
  * RN = RDEPENDS_class-native
  * <font.bb> e.g. font-adobe-100dpi*.bb
Some details where omitted for clarity e.g. dependencies on util-macros.

I believe the intent behind the RDEPENDS_class-native chain:
  * <font.bb> -> font-util-native -> mkfontdir-native
was to provide the necessary dependency on mkfontdir. However because
the native sysroot is not built from packages this RDEPENDS_class-native
chain doesn't have the desire effect (i.e. it doesn't pull in
mkfontdir-native).

Changing the RDEPENDS_class-native chain into a DEPENDS_class-native
chain is a non-starter because of the build time dependency loop it
creates:
  * font-util-native -> mkfontscale-native -> libfontenc-native -> font-util-native

Having upstream remove the build time dependency of libfontenc on
font-util is also a non-starter[1] even though it does create problems
in other distributions, for example on Debian see [2], [3].

Instead add a DEPENDS on mkfontdir-native in the encodings recipe in
addition to the mkfontscale-native dependency it already contains. This
solves the missing mkfontdir in the native sysroot problem without
introducing a build dependency loop.

[1] https://bugs.freedesktop.org/show_bug.cgi?id=97631
[2] https://wiki.debian.org/CircularBuildDependencies
[3] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=717843

(From OE-Core rev: aa8a7b2962f9a77bdd347843c41f86dc291b783e)

Signed-off-by: Gratian Crisan <gratian.crisan@ni.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-09-23 14:56:39 +01:00
..
encodings Patch Upstream Status Updates 2011-12-15 14:36:26 +00:00
font-alias-1.0.3 Patch Upstream Status Updates 2011-12-15 14:36:26 +00:00
xorg-minimal-fonts/misc xorg-minimal-fonts: depend on font-alias instead of shipping fonts.alias 2013-01-28 12:29:30 +00:00
encodings_1.0.4.bb encodings: Add dependency to mkfontdir-native 2016-09-23 14:56:39 +01:00
font-alias_1.0.3.bb Replace one-line DESCRIPTION with SUMMARY 2014-01-02 12:50:18 +00:00
font-util_1.3.1.bb font-util: Remove ${datadir}/fonts from SYSROOT_DIRS_BLACKLIST 2016-05-13 13:41:28 +01:00
xorg-font-common.inc recipes-graphics: add x11 to REQUIRED_DISTRO_FEATURES 2015-05-14 11:43:58 +01:00
xorg-minimal-fonts.bb recipes-graphics: add x11 to REQUIRED_DISTRO_FEATURES 2015-05-14 11:43:58 +01:00