diff options
author | Tudor Florea <tudor.florea@enea.com> | 2015-10-09 22:59:03 +0200 |
---|---|---|
committer | Tudor Florea <tudor.florea@enea.com> | 2015-10-09 22:59:03 +0200 |
commit | 972dcfcdbfe75dcfeb777150c136576cf1a71e99 (patch) | |
tree | 97a61cd7e293d7ae9d56ef7ed0f81253365bb026 /meta/recipes-graphics/pango/pango.inc | |
download | poky-972dcfcdbfe75dcfeb777150c136576cf1a71e99.tar.gz |
initial commit for Enea Linux 5.0 arm
Signed-off-by: Tudor Florea <tudor.florea@enea.com>
Diffstat (limited to 'meta/recipes-graphics/pango/pango.inc')
-rw-r--r-- | meta/recipes-graphics/pango/pango.inc | 97 |
1 files changed, 97 insertions, 0 deletions
diff --git a/meta/recipes-graphics/pango/pango.inc b/meta/recipes-graphics/pango/pango.inc new file mode 100644 index 0000000000..b59d33d14f --- /dev/null +++ b/meta/recipes-graphics/pango/pango.inc | |||
@@ -0,0 +1,97 @@ | |||
1 | SUMMARY = "Framework for layout and rendering of internationalized text" | ||
2 | DESCRIPTION = "Pango is a library for laying out and rendering of text, \ | ||
3 | with an emphasis on internationalization. Pango can be used anywhere \ | ||
4 | that text layout is needed, though most of the work on Pango so far has \ | ||
5 | been done in the context of the GTK+ widget toolkit. Pango forms the \ | ||
6 | core of text and font handling for GTK+-2.x." | ||
7 | HOMEPAGE = "http://www.pango.org/" | ||
8 | BUGTRACKER = "http://bugzilla.gnome.org" | ||
9 | SECTION = "libs" | ||
10 | LICENSE = "LGPLv2.0+" | ||
11 | |||
12 | X11DEPENDS = "virtual/libx11 libxft" | ||
13 | DEPENDS = "glib-2.0 fontconfig freetype zlib virtual/libiconv cairo harfbuzz qemu-native" | ||
14 | |||
15 | PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)} \ | ||
16 | ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'ptest', '', d)}" | ||
17 | |||
18 | PACKAGECONFIG[x11] = "--with-xft,--without-xft,${X11DEPENDS}" | ||
19 | PACKAGECONFIG[ptest] = "--enable-installed-tests,--disable-installed-tests,glib-2.0-native" | ||
20 | |||
21 | BBCLASSEXTEND = "native" | ||
22 | DEPENDS_class-native = "glib-2.0-native cairo-native harfbuzz-native" | ||
23 | |||
24 | PACKAGES_DYNAMIC += "^pango-module-.*" | ||
25 | |||
26 | RRECOMMENDS_${PN} = "pango-module-basic-fc" | ||
27 | |||
28 | inherit gnomebase gtk-doc qemu ptest | ||
29 | |||
30 | # Create a pango-modules package | ||
31 | ALLOW_EMPTY_${BPN}-modules = "1" | ||
32 | PACKAGES += "${BPN}-modules" | ||
33 | RRECOMMENDS_${BPN}-modules = "${@" ".join([p for p in d.getVar('PACKAGES', True).split() if p.find("pango-module") != -1])}" | ||
34 | |||
35 | |||
36 | EXTRA_AUTORECONF = "" | ||
37 | |||
38 | # seems to go wrong with default cflags | ||
39 | FULL_OPTIMIZATION_arm = "-O2" | ||
40 | |||
41 | EXTRA_OECONF = "--disable-introspection \ | ||
42 | --enable-explicit-deps=no \ | ||
43 | --disable-debug \ | ||
44 | --with-mlprefix=${MLPREFIX}" | ||
45 | |||
46 | LEAD_SONAME = "libpango-1.0*" | ||
47 | LIBV = "1.8.0" | ||
48 | |||
49 | postinst_prologue() { | ||
50 | if ! [ -e $D${sysconfdir}/pango ] ; then | ||
51 | mkdir -p $D${sysconfdir}/pango | ||
52 | fi | ||
53 | |||
54 | if [ "x$D" != "x" ]; then | ||
55 | ${@qemu_run_binary(d, '$D','${bindir}/${MLPREFIX}pango-querymodules')} \ | ||
56 | $D${libdir}/pango/${LIBV}/modules/*.so \ | ||
57 | > $D${sysconfdir}/pango/${MLPREFIX}pango.modules 2>/dev/null | ||
58 | |||
59 | [ $? -ne 0 ] && exit 1 | ||
60 | |||
61 | sed -i -e "s:$D::" $D${sysconfdir}/pango/${MLPREFIX}pango.modules | ||
62 | |||
63 | exit 0 | ||
64 | fi | ||
65 | } | ||
66 | |||
67 | # This binary needs to be compiled for the host architecture. This isn't pretty! | ||
68 | do_compile_prepend () { | ||
69 | if ${@base_contains('DISTRO_FEATURES', 'ptest', 'true', 'false', d)}; then | ||
70 | make CC="${BUILD_CC}" CFLAGS="" AM_CPPFLAGS="$(pkg-config-native --cflags glib-2.0)" gen_all_unicode_LDADD="$(pkg-config-native --libs glib-2.0)" -C ${B}/tests gen-all-unicode | ||
71 | fi | ||
72 | } | ||
73 | |||
74 | do_install_append () { | ||
75 | if [ "${MLPREFIX}" != "" ]; then | ||
76 | mv ${D}/${bindir}/pango-querymodules ${D}/${bindir}/${MLPREFIX}pango-querymodules | ||
77 | fi | ||
78 | } | ||
79 | |||
80 | |||
81 | python populate_packages_prepend () { | ||
82 | prologue = d.getVar("postinst_prologue", True) | ||
83 | |||
84 | modules_root = d.expand('${libdir}/pango/${LIBV}/modules') | ||
85 | |||
86 | do_split_packages(d, modules_root, '^pango-(.*)\.so$', 'pango-module-%s', 'Pango module %s', prologue + '${bindir}/${MLPREFIX}pango-querymodules > /etc/pango/${MLPREFIX}pango.modules') | ||
87 | } | ||
88 | |||
89 | FILES_${PN} = "${sysconfdir}/pango/* ${bindir}/* ${libdir}/libpango*${SOLIBS}" | ||
90 | FILES_${PN}-dbg += "${libdir}/pango/${LIBV}/modules/.debug" | ||
91 | FILES_${PN}-dev += "${libdir}/pango/${LIBV}/modules/*.la" | ||
92 | |||
93 | FILES_${PN}-ptest += "${libexecdir}/installed-tests/* \ | ||
94 | ${datadir}/installed-tests/pango" | ||
95 | FILES_${PN}-dbg += "${libexecdir}/installed-tests/.debug" | ||
96 | |||
97 | RDEPENDS_${PN}-ptest += "gnome-desktop-testing liberation-fonts" | ||