Annotation of /trunk/deprecated/gcc-v34/gcc-v34-3.4.6-r1.smage2
Parent Directory | Revision Log
Revision 868 -
(hide annotations)
(download)
Sat Dec 27 18:46:28 2008 UTC (15 years, 9 months ago) by niro
File size: 2200 byte(s)
Sat Dec 27 18:46:28 2008 UTC (15 years, 9 months ago) by niro
File size: 2200 byte(s)
-moved to 'deprecated'
1 | niro | 2 | # $Header: /magellan-cvs/smage/gcc-v34/gcc-v34-3.4.6-r1.smage2,v 1.4 2007-11-10 14:07:48 niro Exp $ |
2 | |||
3 | PNAME="gcc-v34" | ||
4 | PVER="3.4.6" | ||
5 | PBUILD="r1" | ||
6 | |||
7 | PCATEGORIE="sys-dev" | ||
8 | STATE="stable" | ||
9 | |||
10 | DESCRIPTION="Compat C/C++ v${PVER} compiler written by the GNU people." | ||
11 | HOMEPAGE="http://www.gnu.org/software/gcc/gcc.html" | ||
12 | |||
13 | DEPEND=">= virtual/glibc" | ||
14 | SDEPEND=">= sys-dev/binutils-2.4" | ||
15 | |||
16 | SRCFILE="gcc-${PVER}.tar.bz2" | ||
17 | SRCDIR="${BUILDDIR}/gcc-${PVER}" | ||
18 | |||
19 | # languages to build into gcc | ||
20 | MyLanguages=c,c++ | ||
21 | |||
22 | SRC_URI=( | ||
23 | mirror://gcc/${SRCFILE} | ||
24 | mirror://gcc/gcc-3.4.4-no_fixincludes-1.patch | ||
25 | mirror://gcc/gcc-3.4.4-linkonce-1.patch | ||
26 | mirror://gcc/gcc-3.4.4-fix_configure_for_target_native-1.patch | ||
27 | mirror://gcc/gcc-3.4.6-magellan-version.patch | ||
28 | ) | ||
29 | |||
30 | # gcc don't like strong CFLAGS | ||
31 | export CFLAGS="${CFLAGS//-O?} -O2" | ||
32 | export CXXFLAGS="${CFLAGS}" | ||
33 | |||
34 | # check for crosscompile or export default CHOST | ||
35 | if [[ -z ${CCHOST} ]] | ||
36 | then | ||
37 | # no crosscompile defined | ||
38 | export CCHOST=${CHOST} | ||
39 | else | ||
40 | # use crosscompile host | ||
41 | export CCHOST=${CCHOST} | ||
42 | fi | ||
43 | |||
44 | src_prepare() { | ||
45 | munpack ${SRCFILE} || die | ||
46 | cd ${SRCDIR} | ||
47 | |||
48 | mpatch -Np1 gcc-3.4.4-no_fixincludes-1.patch || die | ||
49 | mpatch -Np1 gcc-3.4.4-linkonce-1.patch || die | ||
50 | mpatch -Np1 gcc-3.4.4-fix_configure_for_target_native-1.patch || die | ||
51 | mpatch -Np0 gcc-3.4.6-magellan-version.patch || die | ||
52 | |||
53 | # suppress installation of libiberty, as we will be | ||
54 | # using the one from binutils | ||
55 | sed -i 's/install_to_$(INSTALL_DEST) //' libiberty/Makefile.in || die | ||
56 | |||
57 | install -d ${SRCDIR}/build || die | ||
58 | cd ${SRCDIR}/build | ||
59 | } | ||
60 | |||
61 | src_compile() { | ||
62 | cd ${SRCDIR}/build | ||
63 | |||
64 | # you better off when not using distcc to compile | ||
65 | # your new compiler :) maybe not all are the same | ||
66 | export SMAGE_USE_DISTCC=false | ||
67 | |||
68 | # install this thing to /opt/gcc-${PVER} | ||
69 | ../configure \ | ||
70 | --host=${CHOST} \ | ||
71 | --target=${CCHOST} \ | ||
72 | --prefix=/opt/gcc-${PVER} \ | ||
73 | --enable-shared \ | ||
74 | --enable-threads=posix \ | ||
75 | --enable-__cxa_atexit \ | ||
76 | --enable-clocale=gnu \ | ||
77 | --disable-checking \ | ||
78 | --disable-libunwind-exceptions \ | ||
79 | --with-system-zlib \ | ||
80 | --enable-long-long \ | ||
81 | --enable-cstdio=stdio \ | ||
82 | --enable-languages=${MyLanguages} \ | ||
83 | || die | ||
84 | |||
85 | # smaller boostrap | ||
86 | mmake bootstrap-lean || die | ||
87 | } | ||
88 | |||
89 | src_install() { | ||
90 | cd ${SRCDIR}/build | ||
91 | make DESTDIR=${BINDIR} install || die | ||
92 | } |
Properties
Name | Value |
---|---|
svn:keywords | Id |