summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2006-03-01 04:36:16 +0000
committerMike Frysinger <vapier@gentoo.org>2006-03-01 04:36:16 +0000
commit4e890e3415770ce6d4ed0805eb5fb4598f4eba75 (patch)
tree973df5827c35aad36ea3b3cb76c3ca50971075b7 /sys-libs/uclibc++/uclibc++-0.2.0.ebuild
parentRemove mono-1.1.13* from package.mask (yay) (diff)
downloadgentoo-2-4e890e3415770ce6d4ed0805eb5fb4598f4eba75.tar.gz
gentoo-2-4e890e3415770ce6d4ed0805eb5fb4598f4eba75.tar.bz2
gentoo-2-4e890e3415770ce6d4ed0805eb5fb4598f4eba75.zip
Version bump.
(Portage version: 2.1_pre5-r1)
Diffstat (limited to 'sys-libs/uclibc++/uclibc++-0.2.0.ebuild')
-rw-r--r--sys-libs/uclibc++/uclibc++-0.2.0.ebuild77
1 files changed, 77 insertions, 0 deletions
diff --git a/sys-libs/uclibc++/uclibc++-0.2.0.ebuild b/sys-libs/uclibc++/uclibc++-0.2.0.ebuild
new file mode 100644
index 000000000000..fdb4bf04aabf
--- /dev/null
+++ b/sys-libs/uclibc++/uclibc++-0.2.0.ebuild
@@ -0,0 +1,77 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-libs/uclibc++/uclibc++-0.2.0.ebuild,v 1.1 2006/03/01 04:36:16 vapier Exp $
+
+inherit eutils toolchain-funcs
+
+export CTARGET=${CTARGET:-${CHOST}}
+if [[ ${CTARGET} == ${CHOST} ]] ; then
+ if [[ ${CATEGORY/cross-} != ${CATEGORY} ]] ; then
+ export CTARGET=${CATEGORY/cross-}
+ fi
+fi
+
+DESCRIPTION="embedded C++ library"
+HOMEPAGE="http://cxx.uclibc.org/"
+SRC_URI="http://cxx.uclibc.org/src/uClibc++-${PV}.tbz"
+
+LICENSE="GPL-2"
+[[ ${CTARGET} != ${CHOST} ]] \
+ && SLOT="${CTARGET}" \
+ || SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ppc ~x86"
+IUSE="debug static"
+
+DEPEND=""
+
+S=${WORKDIR}/uClibc++
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ make defconfig || die "defconfig failed"
+
+ local target
+ case $(tc-arch ${CTARGET}) in
+ alpha) target="alpha";;
+ amd64) target="x86_64";;
+ arm) target="arm";;
+ hppa) target="hppa";;
+ mips) target="mips";;
+ ppc) target="powerpc";;
+ x86) target="i386";;
+ *) die "$(tc-arch ${CTARGET}) lists no defaults :/";;
+ esac
+
+ sed -i \
+ -e '/^UCLIBCXX_RUNTIME_PREFIX=/d' \
+ -e '/^TARGET_'${target}'/d' \
+ .config
+
+ echo "UCLIBCXX_RUNTIME_PREFIX=\"/usr/${CTARGET}\"" >> .config
+ echo "TARGET_${target}=y" >> .config
+ use debug && echo "CONFIG_DODEBUG=y" >> .config
+
+ yes "" | make oldconfig || die "oldconfig failed"
+
+ # has to come after make oldconfig, else it will be disabled
+ echo "BUILD_STATIC_LIB=y" >> .config
+ if use static ; then
+ echo "BUILD_ONLY_STATIC_LIB=y" >> .config
+ fi
+}
+
+src_compile() {
+ emake -j1 ARCH_CFLAGS="${CFLAGS}" CROSS=${CTARGET}- || die "make failed"
+}
+
+src_test() {
+ make test || die "test failed"
+}
+
+src_install() {
+ make install PREFIX="${D}" || die
+ dodir /usr/bin
+ dosym /usr/${CTARGET}/bin/g++-uc /usr/bin/g++-uc
+ dodoc ChangeLog README TODO
+}