diff options
author | Mike Frysinger <vapier@gentoo.org> | 2011-02-12 23:49:27 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2011-02-12 23:49:27 +0000 |
commit | fae0410857c36f78bf156a84977488cf9acaf2df (patch) | |
tree | 18a8108865e04c63ea713ce98ae79191b5251e68 /sys-libs/newlib | |
parent | Do not allow newlib to install alongside glibc. (diff) | |
download | gentoo-2-fae0410857c36f78bf156a84977488cf9acaf2df.tar.gz gentoo-2-fae0410857c36f78bf156a84977488cf9acaf2df.tar.bz2 gentoo-2-fae0410857c36f78bf156a84977488cf9acaf2df.zip |
Version bump.
(Portage version: 2.2.0_alpha20/cvs/Linux x86_64)
Diffstat (limited to 'sys-libs/newlib')
-rw-r--r-- | sys-libs/newlib/ChangeLog | 7 | ||||
-rw-r--r-- | sys-libs/newlib/newlib-1.19.0.ebuild | 76 |
2 files changed, 82 insertions, 1 deletions
diff --git a/sys-libs/newlib/ChangeLog b/sys-libs/newlib/ChangeLog index 00c2560b8849..88e6950f19ed 100644 --- a/sys-libs/newlib/ChangeLog +++ b/sys-libs/newlib/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for sys-libs/newlib # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-libs/newlib/ChangeLog,v 1.14 2011/02/12 23:49:01 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-libs/newlib/ChangeLog,v 1.15 2011/02/12 23:49:27 vapier Exp $ + +*newlib-1.19.0 (12 Feb 2011) + + 12 Feb 2011; Mike Frysinger <vapier@gentoo.org> +newlib-1.19.0.ebuild: + Version bump. 12 Feb 2011; Mike Frysinger <vapier@gentoo.org> newlib-1.18.0.ebuild: Do not allow newlib to install alongside glibc. diff --git a/sys-libs/newlib/newlib-1.19.0.ebuild b/sys-libs/newlib/newlib-1.19.0.ebuild new file mode 100644 index 000000000000..559b1baf72d0 --- /dev/null +++ b/sys-libs/newlib/newlib-1.19.0.ebuild @@ -0,0 +1,76 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-libs/newlib/newlib-1.19.0.ebuild,v 1.1 2011/02/12 23:49:27 vapier Exp $ + +inherit eutils flag-o-matic toolchain-funcs + +export CBUILD=${CBUILD:-${CHOST}} +export CTARGET=${CTARGET:-${CHOST}} +if [[ ${CTARGET} == ${CHOST} ]] ; then + if [[ ${CATEGORY/cross-} != ${CATEGORY} ]] ; then + export CTARGET=${CATEGORY/cross-} + fi +fi + +DESCRIPTION="Newlib is a C library intended for use on embedded systems" +HOMEPAGE="http://sourceware.org/newlib/" +SRC_URI="ftp://sources.redhat.com/pub/newlib/${P}.tar.gz" + +LICENSE="NEWLIB LIBGLOSS GPL-2" +[[ ${CTARGET} != ${CHOST} ]] \ + && SLOT="${CTARGET}" \ + || SLOT="0" +KEYWORDS="-* ~arm ~hppa ~m68k ~mips ~ppc ~ppc64 ~sh ~sparc ~x86" +IUSE="nls threads unicode crosscompile_opts_headers-only" +RESTRICT="strip" + +NEWLIBBUILD="${WORKDIR}/build" + +pkg_setup() { + # Reject newlib-on-glibc type installs + if [[ ${CTARGET} == ${CHOST} ]] ; then + case ${CHOST} in + *-newlib|*-elf) ;; + *) die "Use sys-devel/crossdev to build a newlib toolchain" ;; + esac + fi +} + +src_unpack() { + unpack ${A} + mkdir -p "${NEWLIBBUILD}" +} + +src_compile() { + # we should fix this ... + unset LDFLAGS + CHOST=${CTARGET} strip-unsupported-flags + + local myconf="" + # hardwired to avoid breakages + [[ $(tc-is-softfloat) != "no" ]] \ + && myconf="--disable-newlib-hw-fp" \ + || myconf="--enable-newlib-hw-fp" + [[ ${CTARGET} == "spu" ]] \ + && myconf="${myconf} --disable-newlib-multithread" \ + || myconf="${myconf} $(use_enable threads newlib-multithread)" + + cd "${NEWLIBBUILD}" + + ECONF_SOURCE=${S} \ + econf \ + $(use_enable unicode newlib-mb) \ + $(use_enable nls) \ + ${myconf} \ + || die "econf failed" + emake || die "emake failed" +} + +src_install() { + cd "${NEWLIBBUILD}" + emake -j1 DESTDIR="${D}" install || die +# env -uRESTRICT CHOST=${CTARGET} prepallstrip + # minor hack to keep things clean + rm -fR "${D}"/usr/share/info + rm -fR "${D}"/usr/info +} |