C++ Compiler

Discussion in 'General Mac Discussion' started by dnaustin, Sep 28, 2003.

  1. dnaustin macrumors newbie

    Joined:
    Sep 28, 2003
    #1
    I am looking for a good low cost C++ compiler that will run on OS 10. Something similar to the old "Think C++" or "Turbo C++". I need this as a learning tool for a programming class. There used to be several available for the Mac but now I can't find anything. It is frustrating that I can download one for free for the PC (Borland's C++ 5.5) but can't find anything for the Mac except very expensive high end development systems. Any help wll be appreciated.
     
  2. mikeyredk macrumors 65816

    Joined:
    Mar 13, 2003
  3. FattyMembrane macrumors 6502a

    FattyMembrane

    Joined:
    Apr 14, 2002
    Location:
    bat country
    #3
    like mikeyredk said, osx comes with one of the greatest development environments around for free. if osx came with your computer, you probably don't have a dev tools cd, so you'll have to register with the Apple Developer Connection (free at developer.apple.com) and download the disk image of the tools. it includes the basic command-line gcc compiler as well as the project builder IDE.
     
  4. Cubeboy macrumors regular

    Joined:
    Mar 25, 2003
    Location:
    Bridgewater NJ
    #4
    The codewarrior compiler is very nice; fast build speeds, excellent portability, and no problems digesting code whatsoever (in my short experience with it at least). Of course, you have to purchase the entire development studio which is priced at $399 for the OSX only target version.

    So the question is, would this be in your price range?
     
  5. mikeyredk macrumors 65816

    Joined:
    Mar 13, 2003
  6. bousozoku Moderator emeritus

    Joined:
    Jun 25, 2002
    Location:
    Gone but not forgotten.
    #6
    CodeWarrior is okay, but just.

    They have great, wonderful compilers and a so-so development environment and poor application framework.

    I've used it since Developer Release 10 and it hasn't improved much since then. It's kind of like Quark XPress for programmers--they got the majority of the market and sat on it.
     
  7. Pismo macrumors 6502

    Pismo

    Joined:
    Apr 30, 2002
    Location:
    NH
    #7
    I've been using CodeWarrior for a few years now and I really like the interface. I also find the debugger easy to work with. I am currently using CodeWarrior 8 as well as Developer Tools. The only I don't like about CW is that I've had problems running updates released by Metrowerks.

    Xcode will replace my CodeWarrior and my Dev Tools as soon as Panther is released.
     
  8. mikeyredk macrumors 65816

    Joined:
    Mar 13, 2003
    #8
    okay good now that i have rounded up some programers help

    is there a trace through feature in project builder?

    and what about a watch window?
     
  9. robbieduncan Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #9
    Not sure of all of the terminoligy here buy yes it has a full debugger where you can execute the code line by line and see the contents of variables. Is this what you want? If you have experience of gdb (the GNU debugger) then you will be at home as the GUI is simply a nice front end onto gdb.

    Some details and screenshots of XCode (new version of Project Bulder) here: http://www.apple.com/macosx/panther/xcode.html Unfortunatly no shots of the debugger!
     
  10. dnaustin thread starter macrumors newbie

    Joined:
    Sep 28, 2003
    #10
    Per mikeyredk & FattyMembrane's suggestion I installed the Mac Developmet Tools. In addition to being free it looks great. It has several tutorials go get you started and has tons of documentation. I can't find the command line gcc compiler but the IDE includes the C++ environment.
     
  11. mikeyredk macrumors 65816

    Joined:
    Mar 13, 2003
    #11
    a watch window is where you watch a certain variable while your program runs

    i can't seem to be able to use the trace feature meaning going line by line through the program

    i want to be aable to use both of these together
     
  12. robbieduncan Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #12
    Are you using Project Builder (and if so which version with which gcc?) or XCode beta? I think the process is the same for both: set a breakpoint at the start of the code you want to step through. Check the project settings and ensure that you are at the minimum optimisation level and you have debugging symbols turned on. Clean the project (icon looks like a broom). Build and run in debug mode (the icon that looks like a spray can: there should be 2 icons one to build debug and one to build and run debug).
     
  13. mikeyredk macrumors 65816

    Joined:
    Mar 13, 2003
    #13
    i can't get it to stop im am using the xcode beta

    i created the breakpoints
    i cleaned all the targets
    i hit the build and debug spray can and nothing

    [​IMG]
     
  14. caveman_uk Guest

    caveman_uk

    Joined:
    Feb 17, 2003
    Location:
    Hitchin, Herts, UK
    #14
    Is the xcode beta available anywhere except the subscription ADC site? I'm hoping for legal sites but otherwise will do if nothing else:rolleyes:

    I fancy a bit of a play with it :D
     
  15. mikeyredk macrumors 65816

    Joined:
    Mar 13, 2003
  16. caveman_uk Guest

    caveman_uk

    Joined:
    Feb 17, 2003
    Location:
    Hitchin, Herts, UK
    #16
    I wasn't actually questioning the legality of your copy. I was asking if there was anywhere I could get hold if it;)
     
  17. bousozoku Moderator emeritus

    Joined:
    Jun 25, 2002
    Location:
    Gone but not forgotten.
    #17
    If this is an example of what's not working, you should put the breakpoints on statements, not comments.

    By the way, there is no public beta for xcode. Besides, you shouldn't expect things in beta to work perfectly. That's why it's a beta test.
     
  18. mikeyredk macrumors 65816

    Joined:
    Mar 13, 2003
    #18
    i did it did the same thing
    i also tried this on project builder

    here is another shot
    [​IMG]
     
  19. robbieduncan Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #19
    Your debugger might well be hosed: note the debugger has exited due to sigtrap message.
     
  20. robbieduncan Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #20
    Here is the debugger working on the basic C++ template in XCode on Panther (for me: iBook 800, 640Mb) (50% due to max file size limit):
     

    Attached Files:

  21. mikeyredk macrumors 65816

    Joined:
    Mar 13, 2003
    #21
    okay thx for the help but i get the same error under jag also with project builder
     

Share This Page