# -*- Mode: Python -*- vi:si:et:sw=4:sts=4:ts=4:syntax=python from cerbero.tools.libtool import LibtoolLibrary class Recipe(recipe.Recipe): name = 'pango' version = '1.50.11' stype = SourceType.TARBALL btype = BuildType.MESON url = 'gnome://' tarball_checksum = '8800f812d89ee61388188703203f3a7878963c22f8695aaf1fa0a1a1428d17ae' licenses = [License.LGPLv2Plus] deps = ['cairo', 'fontconfig', 'freetype', 'fribidi', 'harfbuzz'] meson_options = {'introspection': 'disabled'} patches = [ # TODO: propose upstream for merging 'pango/0001-meson-fix-freetype-lookup-with-MSVC-using-pkg-config.patch', # TODO: propose upstream for merging 'pango/0001-pango-layout-fix-build-with-Android-s-bionic-libc.patch', ] files_libs = ['libpangocairo-1.0', 'libpango-1.0', 'libpangoft2-1.0'] files_bins = ['pango-view'] files_devel = ['include/pango-1.0', 'lib/pkgconfig/pangoft2.pc', 'lib/pkgconfig/pango.pc', 'lib/pkgconfig/pangocairo.pc'] platform_files_libs = { Platform.WINDOWS: ['libpangowin32-1.0'], } platform_files_devel = { Platform.WINDOWS: ['lib/pkgconfig/pangowin32.pc'], Platform.LINUX: ['lib/pkgconfig/pango.pc'], } files_typelibs = [ 'Pango-1.0', 'PangoCairo-1.0', 'PangoFT2-1.0' ] def post_install(self): LibtoolLibrary('pango-1.0', None, None, None, self.config.libdir, self.config.target_platform, deps=['gobject-2.0', 'fribidi', 'harfbuzz', 'fontconfig', 'expat', 'freetype', 'bz2', 'png16']).save() LibtoolLibrary('pangoft2-1.0', None, None, None, self.config.libdir, self.config.target_platform, deps=['pango-1.0', 'harfbuzz', 'fontconfig', 'expat', 'freetype', 'bz2', 'png16']).save() LibtoolLibrary('pangocairo-1.0', None, None, None, self.config.libdir, self.config.target_platform, deps=['pango-1.0', 'cairo', 'pixman-1', 'pangoft2-1.0']).save() if self.config.target_platform == Platform.WINDOWS: LibtoolLibrary('pangowin32-1.0', None, None, None, self.config.libdir, self.config.target_platform, deps=['pango-1.0', 'cairo']).save() super().post_install()