summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wendler <polynomial-c@gentoo.org>2017-05-03 11:28:11 +0200
committerLars Wendler <polynomial-c@gentoo.org>2017-05-03 11:28:26 +0200
commita363f5ee4c6ba40e2c0b28f62d8963d43fce6b41 (patch)
treedfa8d7b4ea916b55b00a31f15099793f584e136d /media-libs/harfbuzz
parentdev-python/flake8: Clean old versions up (diff)
downloadgentoo-a363f5ee4c6ba40e2c0b28f62d8963d43fce6b41.tar.gz
gentoo-a363f5ee4c6ba40e2c0b28f62d8963d43fce6b41.tar.bz2
gentoo-a363f5ee4c6ba40e2c0b28f62d8963d43fce6b41.zip
media-libs/harfbuzz: Added "debug" USE flag (bug #616816).
Package-Manager: Portage-2.3.5, Repoman-2.3.2
Diffstat (limited to 'media-libs/harfbuzz')
-rw-r--r--media-libs/harfbuzz/harfbuzz-1.4.6-r1.ebuild105
-rw-r--r--media-libs/harfbuzz/harfbuzz-9999.ebuild10
2 files changed, 112 insertions, 3 deletions
diff --git a/media-libs/harfbuzz/harfbuzz-1.4.6-r1.ebuild b/media-libs/harfbuzz/harfbuzz-1.4.6-r1.ebuild
new file mode 100644
index 000000000000..2df1f9d8211a
--- /dev/null
+++ b/media-libs/harfbuzz/harfbuzz-1.4.6-r1.ebuild
@@ -0,0 +1,105 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+EGIT_REPO_URI="git://anongit.freedesktop.org/harfbuzz"
+[[ ${PV} == 9999 ]] && inherit git-r3 autotools
+
+PYTHON_COMPAT=( python2_7 )
+
+inherit eutils flag-o-matic libtool multilib-minimal python-any-r1 xdg-utils
+
+DESCRIPTION="An OpenType text shaping engine"
+HOMEPAGE="https://www.freedesktop.org/wiki/Software/HarfBuzz"
+[[ ${PV} == 9999 ]] || SRC_URI="https://www.freedesktop.org/software/${PN}/release/${P}.tar.bz2"
+
+LICENSE="Old-MIT ISC icu"
+SLOT="0/0.9.18" # 0.9.18 introduced the harfbuzz-icu split; bug #472416
+[[ ${PV} == 9999 ]] || \
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~x64-macos ~x86-macos ~x64-solaris"
+
+IUSE="+cairo debug fontconfig +glib +graphite icu +introspection static-libs test +truetype"
+REQUIRED_USE="introspection? ( glib )"
+
+RDEPEND="
+ cairo? ( x11-libs/cairo:= )
+ fontconfig? ( media-libs/fontconfig:1.0[${MULTILIB_USEDEP}] )
+ glib? ( >=dev-libs/glib-2.38:2[${MULTILIB_USEDEP}] )
+ graphite? ( >=media-gfx/graphite2-1.2.1:=[${MULTILIB_USEDEP}] )
+ icu? ( >=dev-libs/icu-51.2-r1:=[${MULTILIB_USEDEP}] )
+ introspection? ( >=dev-libs/gobject-introspection-1.34:= )
+ truetype? ( >=media-libs/freetype-2.5.0.1:2=[${MULTILIB_USEDEP}] )
+"
+DEPEND="${RDEPEND}
+ dev-util/gtk-doc-am
+ virtual/pkgconfig
+ test? ( ${PYTHON_DEPS} )
+"
+# eautoreconf requires gobject-introspection-common
+# ragel needed if regenerating *.hh files from *.rl
+[[ ${PV} = 9999 ]] && DEPEND="${DEPEND}
+ >=dev-libs/gobject-introspection-common-1.34
+ dev-util/ragel
+"
+
+pkg_setup() {
+ use test && python-any-r1_pkg_setup
+ if ! use debug ; then
+ append-cppflags -DNDEBUG
+ append-cppflags -DHB_NDEBUG
+ fi
+}
+
+src_prepare() {
+ default
+
+ xdg_environment_reset
+
+ if [[ ${CHOST} == *-darwin* || ${CHOST} == *-solaris* ]] ; then
+ # on Darwin/Solaris we need to link with g++, like automake defaults
+ # to, but overridden by upstream because on Linux this is not
+ # necessary, bug #449126
+ sed -i \
+ -e 's/\<LINK\>/CXXLINK/' \
+ src/Makefile.am || die
+ sed -i \
+ -e '/libharfbuzz_la_LINK = /s/\<LINK\>/CXXLINK/' \
+ src/Makefile.in || die
+ sed -i \
+ -e '/AM_V_CCLD/s/\<LINK\>/CXXLINK/' \
+ test/api/Makefile.in || die
+ fi
+
+ [[ ${PV} == 9999 ]] && eautoreconf
+ elibtoolize # for Solaris
+
+ # failing test, https://bugs.freedesktop.org/show_bug.cgi?id=89190
+ sed -e 's#tests/arabic-fallback-shaping.tests##' -i test/shaping/Makefile.in || die "sed failed"
+}
+
+multilib_src_configure() {
+ ECONF_SOURCE="${S}" \
+ # harfbuzz-gobject only used for instrospection, bug #535852
+ econf \
+ --without-coretext \
+ --without-uniscribe \
+ $(use_enable static-libs static) \
+ $(multilib_native_use_with cairo) \
+ $(use_with fontconfig) \
+ $(use_with glib) \
+ $(use_with introspection gobject) \
+ $(use_with graphite graphite2) \
+ $(use_with icu) \
+ $(multilib_native_use_enable introspection) \
+ $(use_with truetype freetype)
+
+ if multilib_is_native_abi; then
+ ln -s "${S}"/docs/html docs/html || die
+ fi
+}
+
+multilib_src_install_all() {
+ einstalldocs
+ prune_libtool_files --modules
+}
diff --git a/media-libs/harfbuzz/harfbuzz-9999.ebuild b/media-libs/harfbuzz/harfbuzz-9999.ebuild
index 6227e71e7bdb..260fc8ecd14c 100644
--- a/media-libs/harfbuzz/harfbuzz-9999.ebuild
+++ b/media-libs/harfbuzz/harfbuzz-9999.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
@@ -8,7 +8,7 @@ EGIT_REPO_URI="git://anongit.freedesktop.org/harfbuzz"
PYTHON_COMPAT=( python2_7 )
-inherit eutils libtool multilib-minimal python-any-r1 xdg-utils
+inherit eutils flag-o-matic libtool multilib-minimal python-any-r1 xdg-utils
DESCRIPTION="An OpenType text shaping engine"
HOMEPAGE="https://www.freedesktop.org/wiki/Software/HarfBuzz"
@@ -19,7 +19,7 @@ SLOT="0/0.9.18" # 0.9.18 introduced the harfbuzz-icu split; bug #472416
[[ ${PV} == 9999 ]] || \
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~x64-macos ~x86-macos ~x64-solaris"
-IUSE="+cairo fontconfig +glib +graphite icu +introspection static-libs test +truetype"
+IUSE="+cairo debug fontconfig +glib +graphite icu +introspection static-libs test +truetype"
REQUIRED_USE="introspection? ( glib )"
RDEPEND="
@@ -45,6 +45,10 @@ DEPEND="${RDEPEND}
pkg_setup() {
use test && python-any-r1_pkg_setup
+ if ! use debug ; then
+ append-cppflags -DNDEBUG
+ append-cppflags -DHB_NDEBUG
+ fi
}
src_prepare() {