diff options
author | Sam James <sam@gentoo.org> | 2021-01-04 05:26:11 +0000 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2021-01-04 05:27:31 +0000 |
commit | 01599c2b2898e2a4ffc73a81e8f353dff5fa31d4 (patch) | |
tree | d37b9fcf92a4c2f0c51fcc3f5a8f8332a3619ccc /app-i18n | |
parent | app-emulation/lxd: fix hardcoded ovmf file path (diff) | |
download | gentoo-01599c2b2898e2a4ffc73a81e8f353dff5fa31d4.tar.gz gentoo-01599c2b2898e2a4ffc73a81e8f353dff5fa31d4.tar.bz2 gentoo-01599c2b2898e2a4ffc73a81e8f353dff5fa31d4.zip |
app-i18n/enca: drop multilib
* Drop multilib as we're the only consumer of
app-text/recode with multilib, blocking
security cleanup.
No consumers of multilib enca seem to exist.
* Modernise the ebuild while here.
Bug: https://bugs.gentoo.org/761873
Package-Manager: Portage-3.0.12, Repoman-3.0.2
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'app-i18n')
-rw-r--r-- | app-i18n/enca/enca-1.19-r3.ebuild | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/app-i18n/enca/enca-1.19-r3.ebuild b/app-i18n/enca/enca-1.19-r3.ebuild new file mode 100644 index 000000000000..093af2ad64d0 --- /dev/null +++ b/app-i18n/enca/enca-1.19-r3.ebuild @@ -0,0 +1,70 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit autotools toolchain-funcs + +DESCRIPTION="Detect and convert encoding of text files" +HOMEPAGE="https://cihar.com/software/enca/" +SRC_URI="https://dl.cihar.com/${PN}/${P}.tar.xz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris" +IUSE="doc +iconv recode static-libs" + +BDEPEND="doc? ( dev-util/gtk-doc )" +RDEPEND=" + iconv? ( virtual/libiconv ) + recode? ( app-text/recode:= ) +" +DEPEND=" + ${RDEPEND} + sys-devel/gettext +" + +pkg_pretend() { + if tc-is-cross-compiler && use iconv; then + die "${PN} can't be cross built with iconv USE enabled. See Gentoo bug 593220." + fi +} + +src_prepare() { + default + + # Disable unconditional documentation build. + sed -i -e '/SUBDIRS/s/ devel-docs//g' Makefile.am || die + + eautoreconf +} + +src_configure() { + local myeconfargs=( + --enable-external + $(use_enable doc gtk-doc) + $(use_enable static-libs static) + $(use_with iconv libiconv-prefix "${EPREFIX}/usr") + $(use_with recode librecode "${EPREFIX}/usr") + ) + + # Workaround automagic virtual/libiconv dependency. + use iconv || export am_cv_func_iconv=no + + econf "${myeconfargs[@]}" +} + +src_compile() { + # Workaround cross compilation issues. See Gentoo bug 424473. + tc-is-cross-compiler && tc-env_build emake -e -C tools + + emake + use doc && emake -C devel-docs docs +} + +src_install() { + emake DESTDIR="${D}" install + use doc && emake -C devel-docs DESTDIR="${D}" install + + find "${ED}" -name '*.la' -delete || die +} |