Ticket #20838: Portfile_final.diff

File Portfile_final.diff, 2.4 KB (added by howarth@…, 15 years ago)

add remaining patches, use --disable-multilib-libjava and re-enable multilib on ppc

  • Portfile

    old new  
    33PortSystem 1.0
    44
    55name                    gcc44
    6 epoch                   1
     6epoch                   2
    77version                 4.4.1
    88platforms               darwin
    99categories              lang
     
    4242
    4343set major               4.4
    4444
     45patchfiles              gcc44-config.guess.diff \
     46                        gcc44-PR41180.diff \
     47                        gcc44-disable-libjava.diff
    4548worksrcdir              build
    46 
    47 # the generated compiler doesn't accept -arch
    48 if {[info exists build_arch] && ${os.platform} == "darwin"} {
    49     if {(${os.arch} == "i386" && $build_arch == "i386") || (${os.arch} == "powerpc" && $build_arch == "ppc")} {
    50         configure.env-append CFLAGS_FOR_TARGET="-m32 ${configure.cflags}"
    51     } elseif {(${os.arch} == "i386" && $build_arch == "x86_64") || (${os.arch} == "powerpc" && $build_arch == "ppc64")} {
    52         configure.env-append CFLAGS_FOR_TARGET="-m64 ${configure.cflags}"
    53     } else {
    54         pre-fetch {
    55             return -code error "Cannot build $name for $build_arch"
    56         }
    57     }
    58     configure.env-append CFLAGS_FOR_BUILD="${configure.cc_archflags} ${configure.cflags}"
    59     configure.cc_archflags
    60     configure.cxx_archflags
    61     configure.objc_archflags
     49pre-patch {
     50        file mkdir ${worksrcpath}
    6251}
     52patch.dir               ${workpath}/gcc-${version}
     53
     54configure.env-append CFLAGS_FOR_BUILD="${configure.cflags}"
     55configure.cc_archflags
     56configure.cxx_archflags
     57configure.objc_archflags
    6358
    6459pre-configure {
    6560        file mkdir ${worksrcpath}
     
    7772                --program-suffix=-mp-${major} \
    7873                --with-gxx-include-dir=${prefix}/include/${name}/c++/ \
    7974                --with-gmp=${prefix} \
    80                 --with-mpfr=${prefix}
     75                --with-mpfr=${prefix} \
     76                --disable-libjava-multilib
    8177# do NOT use MacPorts binutils -- they do not work
    8278configure.env-append    AR_FOR_TARGET=/usr/bin/ar \
    8379                        AS_FOR_TARGET=/usr/bin/as \
     
    104100        xinstall -m 444 ${filespath}/mp-gcc44 ${destroot}${prefix}/etc/select/gcc/
    105101}
    106102
    107 #platform darwin 7 {
    108 #       configure.cflags-append -force_cpusubtype_ALL
    109 #       confgiure.env   BOOT_CFLAGS="-g -O2 -force_cpusubtype_ALL"
    110 #       build.args-append       XCFLAGS=-force_cpusubtype_ALL
    111 #}
    112 
    113 platform powerpc {
    114         configure.args-append --disable-multilib
    115 }
    116 
    117103# odcctools currently do not compile for x64 - move to variant for the time being
    118104variant odcctools \
    119105        description "Use the odcctools instead of the system provided ones - does not work for x64 currently!" {