diff options
author | Thomas Deutschmann <whissi@gentoo.org> | 2017-10-13 22:16:10 +0200 |
---|---|---|
committer | Thomas Deutschmann <whissi@gentoo.org> | 2017-10-13 22:19:23 +0200 |
commit | aa6c077d00c3a21b75ae646421aefadcad527f80 (patch) | |
tree | 5f0f7d63de8594c3e76185b2cef937a751917126 /sys-devel/flex/flex-2.6.4-r1.ebuild | |
parent | profiles/license_groups: Update link to GLEP 23. (diff) | |
download | gentoo-aa6c077d00c3a21b75ae646421aefadcad527f80.tar.gz gentoo-aa6c077d00c3a21b75ae646421aefadcad527f80.tar.bz2 gentoo-aa6c077d00c3a21b75ae646421aefadcad527f80.zip |
sys-devel/flex: Rev bump to fix multiple problems
Closes: https://bugs.gentoo.org/628744
Closes: https://bugs.gentoo.org/625508
See: https://bugs.gentoo.org/632523
Package-Manager: Portage-2.3.10, Repoman-2.3.3
Diffstat (limited to 'sys-devel/flex/flex-2.6.4-r1.ebuild')
-rw-r--r-- | sys-devel/flex/flex-2.6.4-r1.ebuild | 85 |
1 files changed, 85 insertions, 0 deletions
diff --git a/sys-devel/flex/flex-2.6.4-r1.ebuild b/sys-devel/flex/flex-2.6.4-r1.ebuild new file mode 100644 index 000000000000..b221d35914bf --- /dev/null +++ b/sys-devel/flex/flex-2.6.4-r1.ebuild @@ -0,0 +1,85 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="6" + +inherit eutils flag-o-matic libtool multilib-minimal + +DESCRIPTION="The Fast Lexical Analyzer" +HOMEPAGE="https://flex.sourceforge.net/ https://github.com/westes/flex" +SRC_URI="https://github.com/westes/${PN}/releases/download/v${PV}/${P}.tar.gz" + +LICENSE="FLEX" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +IUSE="nls static test" + +# We want bison explicitly and not yacc in general #381273 +RDEPEND="sys-devel/m4" +DEPEND="${RDEPEND} + app-arch/xz-utils + nls? ( sys-devel/gettext ) + test? ( sys-devel/bison )" + +PATCHES=( + "${FILESDIR}"/${PN}-2.6.4-libobjdir.patch + "${FILESDIR}"/${PN}-2.6.4-fix-build-with-glibc2.6+.patch +) + +src_prepare() { + default + + # Disable running in the tests/ subdir as it has a bunch of built sources + # that cannot be made conditional (automake limitation). #568842 + if ! use test ; then + sed -i \ + -e '/^SUBDIRS =/,/^$/{/tests/d}' \ + Makefile.in || die + fi + elibtoolize # Prefix always needs this +} + +src_configure() { + use static && append-ldflags -static + + multilib-minimal_src_configure +} + +multilib_src_configure() { + # Do not install shared libs #503522 + ECONF_SOURCE=${S} \ + econf \ + --disable-shared \ + $(use_enable nls) \ + --docdir='$(datarootdir)/doc/'${PF} +} + +multilib_src_compile() { + if multilib_is_native_abi; then + default + else + cd src || die + emake -f Makefile -f - lib <<< 'lib: $(lib_LTLIBRARIES)' + fi +} + +multilib_src_test() { + multilib_is_native_abi && emake check +} + +multilib_src_install() { + if multilib_is_native_abi; then + default + else + cd src || die + emake DESTDIR="${D}" install-libLTLIBRARIES install-includeHEADERS + fi +} + +multilib_src_install_all() { + einstalldocs + dodoc ONEWS + prune_libtool_files --all + rm "${ED}"/usr/share/doc/${PF}/COPYING || die + dosym flex /usr/bin/lex +} |