Contents of /trunk/extras/gcc-v34/gcc-v34-3.4.6-r2.smage2
Parent Directory | Revision Log
Revision 2 -
(show annotations)
(download)
Fri Oct 10 13:29:42 2008 UTC (15 years, 11 months ago) by niro
File size: 2204 byte(s)
Fri Oct 10 13:29:42 2008 UTC (15 years, 11 months ago) by niro
File size: 2204 byte(s)
import repo
1 | # $Header: /magellan-cvs/smage/gcc-v34/gcc-v34-3.4.6-r1.smage2,v 1.3 2006/08/06 00:10:01 niro Exp $ |
2 | |
3 | PNAME="gcc-v34" |
4 | PVER="3.4.6" |
5 | PBUILD="r2" |
6 | |
7 | PCATEGORIE="sys-dev" |
8 | STATE="unstable" |
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 | gnu://gcc/${SRCFILE} |
24 | mirror://gcc/${SRCFILE} |
25 | mirror://gcc/gcc-3.4.4-no_fixincludes-1.patch |
26 | mirror://gcc/gcc-3.4.4-linkonce-1.patch |
27 | mirror://gcc/gcc-3.4.4-fix_configure_for_target_native-1.patch |
28 | mirror://gcc/gcc-3.4.6-magellan-version.patch |
29 | ) |
30 | |
31 | # gcc don't like strong CFLAGS |
32 | export CFLAGS="${CFLAGS//-O?} -O2" |
33 | export CXXFLAGS="${CFLAGS}" |
34 | |
35 | # check for crosscompile or export default CHOST |
36 | if [[ -z ${CCHOST} ]] |
37 | then |
38 | # no crosscompile defined |
39 | export CCHOST=${CHOST} |
40 | else |
41 | # use crosscompile host |
42 | export CCHOST=${CCHOST} |
43 | fi |
44 | |
45 | src_prepare() |
46 | { |
47 | munpack ${SRCFILE} || die |
48 | cd ${SRCDIR} |
49 | |
50 | mpatch gcc-3.4.4-no_fixincludes-1.patch || die |
51 | mpatch gcc-3.4.4-linkonce-1.patch || die |
52 | mpatch gcc-3.4.4-fix_configure_for_target_native-1.patch || die |
53 | mpatch gcc-3.4.6-magellan-version.patch || die |
54 | |
55 | # suppress installation of libiberty, as we will be |
56 | # using the one from binutils |
57 | sed -i 's/install_to_$(INSTALL_DEST) //' libiberty/Makefile.in || die |
58 | |
59 | install -d ${SRCDIR}/build || die |
60 | cd ${SRCDIR}/build |
61 | } |
62 | |
63 | src_compile() |
64 | { |
65 | cd ${SRCDIR}/build |
66 | |
67 | # you better off when not using distcc to compile |
68 | # your new compiler :) maybe not all are the same |
69 | export SMAGE_USE_DISTCC=false |
70 | |
71 | # install this thing to /opt/gcc-${PVER} |
72 | ../configure \ |
73 | --host=${CHOST} \ |
74 | --target=${CCHOST} \ |
75 | --prefix=/opt/gcc-${PVER} \ |
76 | --enable-shared \ |
77 | --enable-threads=posix \ |
78 | --enable-__cxa_atexit \ |
79 | --enable-clocale=gnu \ |
80 | --disable-checking \ |
81 | --disable-libunwind-exceptions \ |
82 | --with-system-zlib \ |
83 | --enable-long-long \ |
84 | --enable-cstdio=stdio \ |
85 | --enable-languages=${MyLanguages} \ |
86 | || die |
87 | |
88 | # smaller boostrap |
89 | mmake bootstrap-lean || die |
90 | } |
91 | |
92 | src_install() |
93 | { |
94 | cd ${SRCDIR}/build |
95 | make DESTDIR=${BINDIR} install || die |
96 | } |
Properties
Name | Value |
---|---|
svn:keywords | Id |