source: trunk/dports/lang/gcc43/Portfile @ 35418

Last change on this file since 35418 was 35418, checked in by mww@…, 12 years ago

java doesn't build on 10.4/i386 either (disable it)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.7 KB
Line 
1# $Id: Portfile 35418 2008-03-27 21:32:11Z mww@macports.org $
2
3PortSystem 1.0
4
5name                    gcc43
6version                 4.3.0
7revision                1
8platforms               darwin
9categories              lang
10maintainers             mww
11description             The GNU compiler collection
12long_description        The GNU compiler collection, including front ends for \
13                        C, C++, Objective-C, Objective-C++, Java and Fortran95.
14
15homepage                http://gcc.gnu.org/
16master_sites            ftp://ftp.funet.fi/pub/mirrors/sources.redhat.com/pub/gcc/releases/gcc-${version}/ \
17                        ftp://ftp.gwdg.de/pub/linux/gcc/releases/gcc-${version}/ \
18                        ftp://gcc.ftp.nluug.nl/mirror/languages/gcc/releases/gcc-${version}/ \
19                        ftp://gcc.gnu.org/pub/gcc/releases/gcc-${version}/ \
20                        gnu:/gcc/gcc-${version}
21
22set dcore               gcc-core-${version}.tar.bz2
23set dfort               gcc-fortran-${version}.tar.bz2
24set dcxx                gcc-g++-${version}.tar.bz2
25set djava               gcc-java-${version}.tar.bz2
26set dobjc               gcc-objc-${version}.tar.bz2
27distfiles               ${dcore} ${dfort} ${dcxx} ${djava} ${dobjc}
28
29checksums               ${dcore} sha1 2fcea9d777933517a266175f96bc781675d476b3 \
30                        ${dfort} sha1 2314783efdf65f0fdc281978916119c6602067a0 \
31                        ${dcxx} sha1 00f415849605629c1c5a3193edee20eac036ff56 \
32                        ${djava} sha1 3bcaa722b9c25fb7ec08949ad07bbd7a6d4f855c \
33                        ${dobjc} sha1 12ed333935647a80d4e27fc29d015adf840ee6d7
34
35use_bzip2               yes
36
37depends_lib             port:gmp port:mpfr port:libiconv
38
39set major               4.3
40
41worksrcdir              build
42
43pre-configure {
44        file mkdir ${worksrcpath}
45}
46
47configure.cmd   ../gcc-${version}/configure
48configure.args  --enable-languages=c,c++,objc,obj-c++,java,fortran \
49                --libdir=${prefix}/lib/${name} \
50                --includedir=${prefix}/include/${name} \
51                --infodir=${prefix}/share/info \
52                --mandir=${prefix}/share/man \
53                --with-local-prefix=${prefix} \
54                --with-system-zlib \
55                --disable-nls \
56                --program-suffix=-mp-${major} \
57                --with-gxx-include-dir=${prefix}/include/${name}/c++/ \
58                --with-gmp=${prefix} \
59                --with-mpfr=${prefix}
60# do NOT use MacPorts binutils -- they do not work
61configure.env-append    AR_FOR_TARGET=/usr/bin/ar \
62                        AS_FOR_TARGET=/usr/bin/as \
63                        LD_FOR_TARGET=/usr/bin/ld \
64                        NM_FOR_TARGET=/usr/bin/nm \
65                        OBJDUMP_FOR_TARGET=/usr/bin/objdump \
66                        RANLIB_FOR_TARGET=/usr/bin/ranlib \
67                        STRIP_FOR_TARGET=/usr/bin/strip
68
69use_parallel_build      yes
70
71destroot.target install install-info-host
72# install-info # errors on objc-info files
73
74post-destroot {
75        file delete -force ${destroot}${prefix}/share/man/man7 \
76                ${destroot}${prefix}/share/info
77        # install/copy ffitarget.h only if we have it
78        if {![catch {set ffitarget.h [glob ${destroot}${prefix}/lib/${name}/gcc/*/${version}/include/ffitarget.h]} result]} {
79                file copy ${ffitarget.h} ${destroot}${prefix}/include/${name}/
80        }
81
82        # install select file for gcc_select
83        xinstall -m 755 -d ${destroot}${prefix}/etc/select/gcc
84        xinstall -m 444 ${filespath}/mp-gcc43 ${destroot}${prefix}/etc/select/gcc/
85}
86
87#platform darwin 7 {
88#       configure.cflags-append -force_cpusubtype_ALL
89#       confgiure.env   BOOT_CFLAGS="-g -O2 -force_cpusubtype_ALL"
90#       build.args-append       XCFLAGS=-force_cpusubtype_ALL
91#}
92
93platform powerpc {
94        configure.args-append --disable-multilib
95}
96
97# Java support does not compile on 10.4
98platform darwin 8 {
99        configure.args-delete --enable-languages=c,c++,objc,obj-c++,java,fortran
100        configure.args-append   --enable-languages=c,c++,objc,obj-c++,fortran
101}
102# odcctools currently do not compile for x64 - move to variant for the time being
103#variant odcctools \
104#       description "Use the odcctools instead of the system provided ones - does not work for x64 currently!" {
105#       depends_lib-append      port:odcctools
106#       patch {
107#               reinplace "s|/usr/bin/libtool|${prefix}/bin/odlibtool|g" \
108#                       ${workpath}/gcc-${version}/gcc/config/darwin.h
109#       }
110#       configure.args-append   --with-as=${prefix}/bin/odas \
111#                               --with-ld=${prefix}/bin/odld \
112#                               --with-ar=${prefix}/bin/odar
113#}
114
115livecheck.check regex
116livecheck.url   http://gcc.gnu.org/gcc-4.3/
117livecheck.regex GCC (4\\.3\\.\[0-9\])
118
Note: See TracBrowser for help on using the repository browser.