# Copyright 1999-2004 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # $Header: $ IUSE="nls" MY_P=${P/avr-/} S=${WORKDIR}/${MY_P} DESCRIPTION="The GNU C compiler for the AVR microcontroller architecture" HOMEPAGE="http://sources.redhat.com/binutils" SRC_URI="http://ftp.gnu.org/gnu/gcc/${MY_P}.tar.bz2" SLOT="0" LICENSE="GPL-2" KEYWORDS="x86" DEPEND="virtual/glibc >=dev-embedded/avr-binutils-2.14.90.0.8" src_compile() { # Build in a separate build tree mkdir -p ${WORKDIR}/build cd ${WORKDIR}/build einfo "Configuring GCC..." addwrite "/dev/zero" ${S}/configure \ --prefix=/usr \ --target=avr \ --enable-languages=c \ `use_enable nls` || die emake || die } src_install() { cd ${WORKDIR}/build einstall || die rm -rf ${D}/usr/share ${D}/include }