Become a fan of Slashdot on Facebook

 



Forgot your password?
typodupeerror
×
OS X Businesses Operating Systems Programming Apple IT Technology

GCC 3.3 Update for Mac OS X Available 67

snowtigger writes "The August 2003 GCC updater includes the new GCC 3.3 compiler in addition to other updates that will allow development of G5 optimized code with the December 2002 Mac OS X Developer Tools. This update is available to all ADC members from the Download Software area of the ADC web site (free registration required). It will be interesting to see what Steve Jobs will present in Paris tomorrow; is XCode ready?"
This discussion has been archived. No new comments can be posted.

GCC 3.3 Update for Mac OS X Available

Comments Filter:
  • by so1omon ( 577498 ) <[jedidiahfoster] [at] [earthlink.net]> on Tuesday September 16, 2003 @01:09AM (#6972267) Homepage
    The keynote starts at 1 AM Pacific time...
  • I take it that GCC for Mac OS X has the same binary compatibility problems that it does for Intel architectures. What competing compilers are out there at the moment? How do they stack up against GCC speed-wise? Does any ensure binary compatibility?
    • by Lally Singh ( 3427 ) on Tuesday September 16, 2003 @01:40AM (#6972443) Journal
      The ABI is Mach-O or CFM. They both work on OS X. GCC uses it, Codewarrior uses it, the IBM XL compilers use it. Codewarrior also beats gcc in speed & quality of code like an abusive sibling*. Donno about the IBM compilers, but I assume they provide an even more severe beating.

      * That was going to be a much more offensive analogy...
      • by BlackFingolfin ( 517139 ) on Tuesday September 16, 2003 @11:39AM (#6975814)
        Sorry to say but you are talking complete nonsense.

        First off, this was about the C++ ABI used by GCC, which indeed changed (again!) between GCC 3.1 and 3.3, meaning that C++ code is incompatbile between those versions.

        Next, Mach-O and CFM are binary executable formats, which is a whole other story. Besides, you make it sound as if they were the same, when in fact they are not. They are two very different formats. CFM is the one used traditonally, the only one supported by classic MacOS. Max OS X also supports it, and in fact if you want your Carbon programs to run both on OS 9 and OS X, you have to supply them in CFM. However, GCC is *not* able of outputting CFM. The only C/C++ compiler running on OS X which support this is (AFAIK) MetroWerks CodeWarrior.

        Mach-O is the binary format of choice for anything else which only runs on OS X, and it's the only format GCC and the IBM XL compiler support (on OS X, that is).

        • It's not complete nonsense :-P

          The ABI that matters is for C on OS X. Carbon uses it. Even Objective-C & Cocoa use it (the calls are mapped to a C call).

          As for C++ ABI... I'm asking someone who knows :-) bbl.
        • CFM & Mach-O are the OS 9 & OS X binary executable formats. They can be as different as they want internally, but they're serving the same purpose. I think we're in agreement here.

          My point was that the C ABI is standard atop of these, and that that's the ABI that's most important. I'll post when I get the right info on the C++ ABI compatibility...
  • CHUD (Score:5, Informative)

    by Pathwalker ( 103 ) * <hotgrits@yourpants.net> on Tuesday September 16, 2003 @01:22AM (#6972334) Homepage Journal
    The GCC update has been out for a while, but it looks like last week Apple updated CHUD [apple.com] (the Computer Hardware Understanding Development toolkit) to version 3.0.

    It lets you tweak configuration registers in almost all parts of the system, gather and graph lots of profile information (instruction mix, cache stalls, etc...) from programs, and lots of other cool things.
  • Fink (Score:5, Informative)

    by therevolution ( 525890 ) on Tuesday September 16, 2003 @02:15AM (#6972620)
    Fink users: see this annoucement [sourceforge.net] from the Fink developers regarding GCC 3.3 . It is probably a good idea to hold off on installing 3.3 until they add support for it.
    • Too late. How do I uninstall gcc 3.3, without uninstalling the entire Developer Tools?

      Btw, it's been out for about a week.

      • Beats me. That announcement I linked to says to run "sudo gcc_select 3" before running Fink as a workaround... but they still don't promise everything will work. I don't know, it's a fairly old announcement now... maybe things have changed since? I don't know... try it and see what happens, I guess.
      • Re:Fink (Score:5, Informative)

        by jweatherley ( 457715 ) <james@nosPam.weatherley.net> on Tuesday September 16, 2003 @03:01AM (#6972782) Homepage
        The old compilers are still there. Take a look in /usr/bin and you will see them:

        bash-2.05a$ ls /usr/bin/gc*
        /usr/bin/gcc /usr/bin/gcc2 /usr/bin/gcc-3.3
        /usr/bin/gcc3

        gcc is a symlink to whatever compliler you are currently using - so to go back to v3.1 just point it to gcc3. Similar stuff applies for g++.

        Also Project Builder doesn't know about gcc3.3 without changing some of the compile options and will default to gcc2.95 so it is important to RTFM before updating!
        • Re:Fink (Score:5, Informative)

          by transient ( 232842 ) on Tuesday September 16, 2003 @04:17AM (#6973064)
          Don't go messing with those symlinks unless you know what you're doing. Apple provides a tool called gcc_select for this purpose. If you run "gcc_select -n 2" it will show you what commands it runs to select GCC 2, and there are 60 of them. Not something you want to do by hand.

          There's no man page for gcc_select (not on my Mac anyway) but "gcc_select -h" will get you some brief help.

    • They may have fixed this by now -- I did a CVS update over the weekend, and got a new gcc-3.3 tree in my CVS repository:

      % ls /sw/fink/10.*
      /sw/fink/10.2:
      CVS
      local
      stable
      unstable

      /sw/fink/10.2-gcc3.3:
      CVS
      stable
      unstable

      /sw/fink/10.3:
      CVS
      IDEAS

      If you installed the GCC3.3 update before learning about the warning, try doing a CVS update for Fink with `sudo fink -y selfupdate` (or maybe `sudo fink -y selfupdate-cvs`, depending on options you may have selected in the past). This may force you to star

    • One thing about Fink. It is very sensitive to changes in development tools. I upgraded Perl from 5.6 to 5.8 and have had no end of troubles ever since. I finally got Fink Commander working (after a few months) but last week I tried to run update-all and one package is screwed up because of confusion over Perl versions. I halfway suspect that they are holding off on a lot of things until Panther is out, given how that will usher in a lot of changes/unifications with how general Unix stuff is installed.
      • Part of the reason I plan to do a fresh-install once I go Panther. Unless of course I get a job and can buy a new PowerBook with Panther on it.
  • by MalleusEBHC ( 597600 ) on Tuesday September 16, 2003 @02:34AM (#6972697)
    I doubt Apple will release XCode separate from Panther. However, I would not be surprised in the least to hear that Panther is released in but a few short hours. At the very worst, I expect Steve to finally announce a specific date for Panther's release.

    On the other hand, the question of what we will hear (if anything) about the Powerbooks is beyond my ability to prognosticate. On one hand, I think that they *must* finally be coming out. I mean, it's the year of the laptop and we haven't seen anything since January. However, reportedly the holdup has been because of Motorola's inability to produce the 7457 in quantity, in which case you can never be sure how long they will drag their feet.
    • It still needs some polishing, as far as I can tell.

      I think it's very likely though that Jobs will announce a definite release date.
    • I just ordered a 15" powerbook. I asked two questions:
      1. Is it worth waiting for new PowerBooks (i.e. are there going to be new ones released at Paris)?
      2. Is it worth waiting for Panther?

      The answer to the first question was `We never comment on products until they have been anounced. If, hypothetically speaking, new ones were to be announced by Steve in his keynote next week [this was last week] then we would automatically upgrade your order to the new model'.

      The answer to question two was `Don't expect t

  • IBM Compilers (Score:5, Interesting)

    by Anonymous Coward on Tuesday September 16, 2003 @02:59AM (#6972776)
    IBM has also released their own cc compiler's for use with the g5 which are supposed to be faster than gcc. They even give instructions as to how to incorporate into project builder and Xcode if I remember. Anyone tried this?
  • I'm an experienced Mac User and I'm comfortable in *nix. Nontheless, I still don't understand why, as a user of applications, I would want the GCC. I feel like this is a question lots of people want the answer to. Anyone want to take a crack?
    • Re:Silly question: (Score:3, Informative)

      by noselasd ( 594905 )
      You won't need gcc, what made you think that ?
    • Re:Silly question: (Score:3, Informative)

      by babbage ( 61057 )

      GCC is for compiling software from raw source code. If you're downloading open source software, you generally need a compiler to install it, because the software frequently isn't distributed in an executable form. Even if an executable form is available, most open source projects don't have the resources to provide version for every esoteric configuration people might be using (like, say, OSX -- most of this stuff is written for Linux after all, so OSX is a bit "exotic" from the average Linux developer's po

    • Imaging end-user software that is able to call a compiler- the software could compile some arrangement/setup/instructions from the user into an extremely fast executing part and load it using dload and execute it. Everything would be invisible to the user but the result could be very fast execution of stuff (with an annoying start-up delay, admittedly). For instance imagine Photoshop where your custom brushes or filters are actually compiled code somehow.

      This could be the killer app, actually!

      In addition
      • Don't think you're the first person to think of this.

        In fact, Oracle does this now, with lots of its products.

        What does it mean? Well, every time the compiler is updated, their software install breaks. Every time the libraries change, their software install breaks. Every time you blink, their software install breaks.

        Why not recommend that software makers ship their software with a big hammer. That way I can just hit myself over the head repeatedly, thus causing the same anguish, while at least lettin
      • No exactly what you're talking about, but don't a lot of dynamic languages allow you to do this sort of thing already?

        I thought one of the Big Win features of Common Lisp was the ability to dynamically generate & run code on the fly, which is basically what you're talking about.

        Likewise, Perl & Python let you do similar things with the eval amd lambda functions -- build up a data structure or code block, store it in a variable then eval{...} it as you go.

        Granted, there's no compilation in the C/C

  • by Domini ( 103836 ) on Tuesday September 16, 2003 @04:58AM (#6973221) Journal
    From the Fink site:


    2003-06-26: Developer Tools Update.

    Quick Summary: DO NOT INSTALL THIS UPDATE.

    Apple has released a patch to the December 2002 Developer Tools which includes gcc 3.3, their new compiler.

    Fink does not yet support compiling with gcc 3.3. In addition, it is important not to "mix and match" between compilers: all C++ code in fink packages needs to be compiled with the same compiler.

    For this reason, the Fink team recommends that if you update your Developer Tools with the new patch, you should be careful to run sudo gcc_select 3 prior to any "fink build" or "fink install" commands.
  • OK, does anyone have any real information on this supposed 3.3 version? The *last* time the released a so-called "3.3" version of GCC (April/June), I discovered after WEEKS of frustration that it was really just some 3.2 CVS snapshot from last February, and was no better really than the 3.2 version

    I am grateful that a free compiler is available for my Mac but that was annoying.

    So is this REALLY gcc 3.3? Can someone who has installed it please run "gcc-3.3 -v" and post the output?

    Thanks!

    reed
    • bash-2.05a$ gcc -v
      Reading specs from /usr/libexec/gcc/darwin/ppc/3.3/specs
      Thread model: posix
      gcc version 3.3 20030304 (Apple Computer, Inc. build 1435)
      bash-2.05a$
    • [Minerva:~] eman% gcc --version
      gcc (GCC) 3.3 20030304 (Apple Computer, Inc. build 1435)
      Copyright (C) 2002 Free Software Foundation, Inc.
      This is free software; see the source for copying conditions. There is NO
      warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    • by Anonymous Coward
      The Dec2002gccUpdater.pkg update:

      % gcc -v
      Reading specs from /usr/libexec/gcc/darwin/ppc/3.3/specs
      Thread model: posix
      gcc version 3.3 20030304 (Apple Computer, Inc. build 1435)

      The NEW August2003gccUpdater.pkg update:

      % gcc -v
      Reading specs from /usr/libexec/gcc/darwin/ppc/3.3/specs
      Thread model: posix
      gcc version 3.3 20030304 (Apple Computer, Inc. build 1493)

  • I just bought my first Mac off of ebay (G4/450/256M/10G/DVD/ZIP/keyboard/stupid puck mouse/17" monitor). I've been programming under Linux and Windows forever, and plan to start programming for OSX now too. I am really looking forward to OSX 10.3 and the final Xcode. Any veteran Mac programmers want to help me learn this stuff :)
    • What? You asking for Father "Randy" Pudge to supervise you? Seriously, if you need a starting place for technical info, surf to the Apple Developer Connection [apple.com] and sign up. The basic membership is free, and gives you access to the downloads and all documentation. There are plenty of tutorials to get you going.
      • I already signed up for that, but I can only put some much effort into learning how to use and program for OSX, since 90%+ of my sales will definately still be the windows version. I see it more as myself doing a favor for the Mac community by even trying to create a Mac version of my software.
    • Re:I want xcode! (Score:4, Informative)

      by Maserati ( 8679 ) on Tuesday September 16, 2003 @05:14PM (#6979510) Homepage Journal
      O'Reilly's MacDev center [macdevcenter.com]

      CocoaDev.com [cocoadevcentral.com]

      Both have entry-level ProjectBuilder tutorials, including the famous one-line web browser (CocoaDev) and text editor (O'Reilly) tutorials.
    • Seriously, it's well worth the money to get yourself a processor upgrade card given the machine you've just bought. I'm pretty sure you can upgrade to 800Mhz or 1GHz for a reasonable price. This is what has kept prices for these machines and Cubes so high. It'll more than double your performance considering the added cache, and that'll make a big difference if you're compiling. Also max out your RAM, it's cheap.

      Rather than complain about the puck, dual-button+scrollwheel optical USB mice are super-cheap, g

      • If I wanted a G5, I would have just bought it. I want a slow G4 so that I know if my program runs reasonably well on this, it should be even faster on better Macs. I may buy a 4th Intellimouse, I love those things, and its USB so whatever, it should work, but right now I'm just VNCing to it from my win2000 box anyway.
        What I really need to find is some easy way to manage a program that compiles and runs well on OSX and Windows. Sure I could use GTK, but I know GTK apps look like ass on windows, so I probabl
        • Reportedly Borland is coming out with a crossplatform version of their C++ Builder. It'll definitely have a Linux version but I've heard rumors of mixed things on the Mac version. Borland's always been rather lukewarm towards the Mac and their main strategy at the moment seems "survival by embracing Microsoft." (i.e. their .net strategy) So who knows if Mac support will actually make it.

          One hopes it will since C++ Builder is, in certain ways, easier than learning Obj-C and trying to use Interface Buil

        • I suggest using wxWindows.

          I started out with wxWindows to write version 2 of PhotoFlair (www.truview.com). I am now developing on my personal time a port for Cocoa known simply as wxCocoa. It is Mac OS X only.

          In the meantime, there is a Mac Classic and Carbon port known as wxMac. Current CVS is dropping straight Classic support in favor of Carbon only. It will require Mac OS 9.1 or better.

          Developing on a Mac is a great experience, though a nice fast Dual G4 or G5 is really a better system for that.

  • by Brad Lucier ( 547713 ) on Tuesday September 16, 2003 @03:24PM (#6978366)
    Anyone know what these options mean? They are mentioned as being turned on by the new -fast option, but they seem to be Apple-specific and don't appear in the documentation file://Developer/Documentation/DeveloperTools/gcc- 3.3/gcc/index.html

    -frelax-aliasing
    -fgcse-mem-alias
    -floop-transpose
    -floop-to-memset
    -fload-after-store
    -fgcse-loop-depth
    -fdisable-typechecking-for-spec

    That last one sounds like a good one ;-), but I'm wondering if it can screw up my programs that might rely on stricter semantics, so I'd like to know what it does.

    • it all adds up to:

      -fwork-dammit
    • Mike Stump at Apple helped me find the answers. There is little real documentation, the documentation is in the CVS sources for the compilers, and you have to download more than one source tree to be able to figure out what's going on.

      First, you need to find the versions of the compiler that Apple shipped. Second, there are two different versions depending on whether the -fast option is given or not: 1493 and 1610.

      Then if you download the current sources (see file:///Developer/Documentation/DeveloperTo

      • So, for those of us who are incredibly lazy, what do all those compiler options do? You gotten me curious now (but not curious enough to go through the trouble of setting up CVS myself).

"If it ain't broke, don't fix it." - Bert Lantz

Working...