Contents of /trunk/core/libstdc++/libstdc++-4.3.3-r1.smage2
Parent Directory | Revision Log
Revision 1079 -
(show annotations)
(download)
Mon Apr 20 16:47:13 2009 UTC (15 years, 5 months ago) by niro
File size: 3300 byte(s)
Mon Apr 20 16:47:13 2009 UTC (15 years, 5 months ago) by niro
File size: 3300 byte(s)
-ver bump to 4.3.3-r1
1 | # $Id$ |
2 | |
3 | PNAME="libstdc++" |
4 | PVER="4.3.3" |
5 | PBUILD="r1" |
6 | |
7 | PCATEGORIE="sys-libs" |
8 | STATE="unstable" |
9 | |
10 | DESCRIPTION="Standard GNU C and C++ libraries." |
11 | HOMEPAGE="http://www.gnu.org/software/gcc/gcc.html" |
12 | |
13 | # needed to prevent compat issues with gcc-3.4.x and gcc-4.0.x |
14 | DEPEND=">= sys-libs/libstdc++-v3-3.3.3 |
15 | >= sys-apps/base-files-0.1" |
16 | |
17 | SDEPEND=">= sys-dev/binutils-2.19 |
18 | >= dev-libs/gmp-4.2.4 |
19 | >= dev-libs/mpfr-2.3.2 |
20 | >= virtual/kernel-headers" |
21 | |
22 | SRCFILE="gcc-${PVER}.tar.bz2" |
23 | SRCDIR="${BUILDDIR}/gcc-${PVER}" |
24 | |
25 | # languages to build into gcc |
26 | MyLanguages=c,c++ |
27 | |
28 | sminclude cleanutils libtool |
29 | |
30 | SRC_URI=( |
31 | gnu://gcc/gcc-${PVER}/${SRCFILE} |
32 | mirror://gcc/${SRCFILE} |
33 | mirror://gcc/gcc-4.3.2-no-fixincludes.patch |
34 | ) |
35 | |
36 | UP2DATE="updatecmd \"http://ftp.gnu.org/gnu/gcc/?C=M;O=A\" | sed -n 's/.*gcc-\(.*\)\//\1/;$ p'" |
37 | |
38 | # gcc don't like strong CFLAGS |
39 | export CFLAGS="${CFLAGS//-O?} -O2" |
40 | export CXXFLAGS="${CFLAGS}" |
41 | |
42 | # check for crosscompile or export default CHOST |
43 | if [[ -z ${CCHOST} ]] |
44 | then |
45 | # no crosscompile defined |
46 | export CCHOST=${CHOST} |
47 | else |
48 | # use crosscompile host |
49 | export CCHOST=${CCHOST} |
50 | fi |
51 | |
52 | src_prepare() |
53 | { |
54 | munpack ${SRCFILE} || die |
55 | cd ${SRCDIR} |
56 | |
57 | # generic fixes |
58 | mpatch gcc-4.3.2-no-fixincludes.patch || die |
59 | |
60 | # suppress installation of libiberty, as we will be |
61 | # using the one from binutils |
62 | sed -i 's/install_to_$(INSTALL_DEST) //' libiberty/Makefile.in || die |
63 | |
64 | install -d ${SRCDIR}/build || die |
65 | cd ${SRCDIR}/build |
66 | } |
67 | |
68 | src_compile() |
69 | { |
70 | cd ${SRCDIR}/build |
71 | |
72 | local myconf |
73 | |
74 | # you better off when not using distcc to compile |
75 | # your new compiler :) maybe not all are the same |
76 | export SMAGE_USE_DISTCC=false |
77 | |
78 | # Straight from the GCC install doc: |
79 | # "GCC has code to correctly determine the correct value for target |
80 | # for nearly all native systems. Therefore, we highly recommend you |
81 | # not provide a configure target when configuring a native compiler." |
82 | if [[ ${CHOST} != ${CCHOST} ]] |
83 | then |
84 | myconf+=" --target=${CCHOST}" |
85 | fi |
86 | |
87 | # gcc >= 4.3 has now configure flags for uri and version - yeah! |
88 | AR=ar \ |
89 | ../configure \ |
90 | --with-bugurl="http://bugs.magellan-linux.de/" \ |
91 | --with-pkgversion="Magellan-Linux" \ |
92 | --build=${CHOST} \ |
93 | --host=${CHOST} \ |
94 | --prefix=/usr \ |
95 | --mandir=/usr/share/man \ |
96 | --infodir=/usr/share/info \ |
97 | --libdir=/usr/$(mlibdir) \ |
98 | --libexecdir=/usr/$(mlibdir) \ |
99 | --enable-shared \ |
100 | --enable-threads=posix \ |
101 | --enable-__cxa_atexit \ |
102 | --enable-clocale=gnu \ |
103 | --disable-checking \ |
104 | --disable-libunwind-exceptions \ |
105 | --with-system-zlib \ |
106 | --enable-long-long \ |
107 | --enable-cstdio=stdio \ |
108 | --enable-languages=${MyLanguages} \ |
109 | --disable-libstdcxx-pch \ |
110 | ${myconf} \ |
111 | || die |
112 | |
113 | # parallel builds seems to break sometimes on x86_64 |
114 | local myopts |
115 | [[ ${ARCH} = x86_64 ]] && myopts=-j1 |
116 | |
117 | mmake ${myopts} bootstrap-lean || die |
118 | } |
119 | |
120 | src_install() |
121 | { |
122 | cd ${SRCDIR}/build |
123 | install -d ${BINDIR}/$(mlibdir) || die |
124 | |
125 | make DESTDIR=${BINDIR} install || die |
126 | |
127 | # deletes everything excluding libgcc_s and libstdc++ |
128 | zapmost ${BINDIR}/usr/$(mlibdir) libgcc_s*.* libstdc++*.* || die |
129 | |
130 | # other not needed |
131 | rm -rf ${BINDIR}/$(mlibdir) || die |
132 | rm -rf ${BINDIR}/usr/{bin,include,share} || die |
133 | rm -rf ${BINDIR}/usr/libexec || die |
134 | |
135 | # fix all .la files |
136 | # the contain invalid libpathes and they are not needed |
137 | local la |
138 | for la in $(find ${BINDIR} -name \*.la) |
139 | do |
140 | fix_la_file ${la} || die ${la} |
141 | done |
142 | } |
Properties
Name | Value |
---|---|
svn:keywords | Id |