/[gentoo-x86]/sys-libs/uclibc++/uclibc++-0.2.2-r1.ebuild
Gentoo

Contents of /sys-libs/uclibc++/uclibc++-0.2.2-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Tue Oct 13 11:14:14 2009 UTC (10 years, 3 months ago) by ssuominen
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +1 -1 lines
FILE REMOVED
Remove uclibc++ as planned.

1 # Copyright 1999-2007 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sys-libs/uclibc++/uclibc++-0.2.2-r1.ebuild,v 1.1 2007/10/01 22:47:12 solar Exp $
4
5 inherit eutils toolchain-funcs
6
7 export CTARGET=${CTARGET:-${CHOST}}
8 if [[ ${CTARGET} == ${CHOST} ]] ; then
9 if [[ ${CATEGORY/cross-} != ${CATEGORY} ]] ; then
10 export CTARGET=${CATEGORY/cross-}
11 fi
12 fi
13
14 DESCRIPTION="embedded C++ library"
15 HOMEPAGE="http://cxx.uclibc.org/"
16 SRC_URI="http://cxx.uclibc.org/src/uClibc++-${PV}.tar.bz2"
17
18 LICENSE="GPL-2"
19 [[ ${CTARGET} != ${CHOST} ]] \
20 && SLOT="${CTARGET}" \
21 || SLOT="0"
22 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ppc ~x86"
23 IUSE="debug static"
24
25 DEPEND=""
26
27 S=${WORKDIR}/uClibc++-${PV}
28
29 set_config() {
30 local val
31 sed -i -e "/$1/d" .config
32 if [[ -n $2 && $2 != "n" ]]; then
33 val="$1=${2:-y}"
34 einfo "Enabling $1"
35 else
36 val="# $1 is not set"
37 einfo "Disabling $1"
38 fi
39 echo "$val" >> .config
40 }
41
42 src_unpack() {
43 unpack ${A}
44 cd "${S}"
45 sed -i -e "s: -Wl,-s$: ${LDFLAGS}:" src/Makefile
46 emake -j1 -s defconfig > /dev/null || die "defconfig failed"
47 set_config UCLIBCXX_RUNTIME_PREFIX "\"/usr/${CTARGET}\""
48 set_config BUILD_STATIC_LIB y
49 if use static; then
50 set_config BUILD_ONLY_STATIC_LIB y
51 fi
52 if use elibc_uclibc; then
53 set_config UCLIBCXX_HAS_TLS n
54 fi
55 emake oldconfig
56 }
57
58 src_compile() {
59 emake \
60 STRIPTOOL="true" \
61 OPTIMIZATION="${CXXFLAGS}" \
62 CROSS=${CTARGET}- \
63 || die "make failed"
64 }
65
66 src_install() {
67 emake install DESTDIR="${D}" || die
68 dodir /usr/bin
69 dosym /usr/${CTARGET}/bin/g++-uc /usr/bin/g++-uc
70 dodoc ChangeLog README TODO
71 }

  ViewVC Help
Powered by ViewVC 1.1.20