gcc43 version 4.3-20080208 for Mac OS X 10.5 Leopard
Friday the 16th of May, 2008

    gcc43  most recent diff


      View the most recent changes for the gcc43 port at: gcc43.darwinports.com/diff
      Scroll down toward the bottom of the page to get installation instructions for gcc43.
      The raw portfile for gcc43 4.3-20080208 is located here:
      http://gcc43.darwinports.com/dports/lang/gcc43/Portfile
      Find related portfiles with the unique DarwinPorts.com search feature.
      Check for any related Fink projects here: pdb.finkproject.org/pdb/package.php/gcc43
      Google
      Web Darwinports.com



      # $Id: Portfile 34035 2008-02-10 22:47:48Z mww macports.org $

      PortSystem 1.0

      Name: gcc43
      Version: 4.3-20080208
      Platform: darwin
      Category: lang
      Maintainers: mww
      Description: The GNU compiler collection, prerelease BETA
      Long Description: The GNU compiler collection, including front ends for C, C++, Objective-C and Objective-C++. This is a prerelease BETA version and does not have all available language front ends enabled.

      Homepage: http://gcc.gnu.org/
      master_sites ftp://ftp.gwdg.de/pub/linux/gcc/snapshots/${version}/ ftp://ftp.funet.fi/pub/mirrors/sources.redhat.com/pub/gcc/snapshots/${version}/ ftp://gcc.gnu.org/pub/gcc/snapshots/${version}/

      set dcore gcc-core-${version}.tar.bz2
      set dfort gcc-fortran-${version}.tar.bz2
      set dcxx gcc-g++-${version}.tar.bz2
      set djava gcc-java-${version}.tar.bz2
      set dobjc gcc-objc-${version}.tar.bz2
      distfiles ${dcore} ${dfort} ${dcxx} ${djava} ${dobjc}

      checksums ${dcore} sha1 a1ac93e24f6c22b34420ba15163470d7c3d53e4e ${dfort} sha1 113022c40547cc90e66022c860231c11d0eec519 ${dcxx} sha1 30013558ea1763bfff25f85968a37facbe151646 ${djava} sha1 610b5048338cf028002364818331f3f36d52ad1c ${dobjc} sha1 329a279b0ec08d90320784acf5b3e25592eed105

      use_bzip2 yes

      depends_lib port:gmp port:mpfr port:libiconv

      set major 4.3

      worksrcdir build

      pre-configure {
      file mkdir ${worksrcpath}
      }

      configure.cmd ../gcc-${version}/configure
      configure.args --enable-languages=c,c++,objc,obj-c++ --libdir=${prefix}/lib/${name} --includedir=${prefix}/include/${name} --infodir=${prefix}/share/info --mandir=${prefix}/share/man --with-local-prefix=${prefix} --with-system-zlib --disable-nls --program-suffix=-mp-${major} --with-gxx-include-dir=${prefix}/include/${name}/c++/ --with-gmp=${prefix} --with-mpfr=${prefix}
      # do NOT use MacPorts binutils -- they do not work
      configure.env-append AR_FOR_TARGET=/usr/bin/ar AS_FOR_TARGET=/usr/bin/as LD_FOR_TARGET=/usr/bin/ld NM_FOR_TARGET=/usr/bin/nm OBJDUMP_FOR_TARGET=/usr/bin/objdump RANLIB_FOR_TARGET=/usr/bin/ranlib STRIP_FOR_TARGET=/usr/bin/strip

      build.target bootstrap
      use_parallel_build yes

      destroot.target install install-info-host
      # install-info # errors on objc-info files

      post-destroot {
      file delete -force ${destroot}${prefix}/share/man/man7 ${destroot}${prefix}/share/info
      # install/copy ffitarget.h only if we have it
      if {![catch {set ffitarget.h [glob ${destroot}${prefix}/lib/${name}/gcc/*/${version}/include/ffitarget.h]} result]} {
      file copy ${ffitarget.h} ${destroot}${prefix}/include/${name}/
      }
      }

      #platform darwin 7 {
      # configure.cflags-append -force_cpusubtype_ALL
      # confgiure.env BOOT_CFLAGS="-g -O2 -force_cpusubtype_ALL"
      # build.args-append XCFLAGS=-force_cpusubtype_ALL
      #}

      platform powerpc {
      configure.args-append --disable-multilib
      }

      # odcctools currently do not compile for x64 - move to variant for the time being
      Variant: odcctools description "Use the odcctools instead of the system provided ones - does not work for x64 currently!" {
      depends_lib-append port:odcctools
      patch {
      reinplace "s|/usr/bin/libtool|${prefix}/bin/odlibtool|g" ${workpath}/gcc-${version}/gcc/config/darwin.h
      }
      configure.args-append --with-as=${prefix}/bin/odas --with-ld=${prefix}/bin/odld --with-ar=${prefix}/bin/odar
      }

      # due to popular request - untested for the BETA; will be removed as soon as other languages than C compile successfuly
      Variant: gfortran description "Enables fortran; this language will be enabled in the final version - this variant is completely untested!" {
      configure.args-delete --enable-languages=c,c++,objc,obj-c++
      configure.args-append --enable-languages=c,c++,objc,obj-c++,fortran
      }

      livecheck.check regex
      livecheck.url ftp://gcc.gnu.org/pub/gcc/snapshots/
      livecheck.regex LATEST-4.3 -> (4.3-\[0-9\]+)


    If you haven't already installed Darwin Ports, you can find easy instructions for doing so at the main Darwin Ports page.

    Once Darwin Ports has been installed, in a terminal window and while online, type the following and hit return:


      %  cd /opt/local/bin/portslocation/dports/gcc43
      % sudo port install gcc43
      Password:
    You will then be prompted for your root password, which you should enter. You may have to wait for a few minutes while the software is retrieved from the network and installed for you. Y ou should see something that looks similar to:

      ---> Fetching gcc43
      ---> Verifying checksum for gcc43
      ---> Extracting gcc43
      ---> Configuring gcc43
      ---> Building gcc43 with target all
      ---> Staging gcc43 into destroot
      ---> Installing gcc43
    - Make sure that you do not close the terminal window while Darwin Ports is working. Once the software has been installed, you can find further information about using gcc43 with these commands:
      %  man gcc43
      % apropos gcc43
      % which gcc43
      % locate gcc43

     Where to find more information:

    Darwin Ports



    image test