Xcode Command Utility Tool C++ HELP

Discussion in 'Mac Programming' started by mrezzy, Mar 11, 2008.

  1. macrumors newbie

    Mar 11, 2008

    I need help compiling in the command utility tool for Xcode. When I compile my source file, everything works fine, but when I go and make changes to the CPP source file, the compile won't compile the changes. It instead, compiles the original source file [without all the changes]. Can anybody help me?

    This is the process I use to compile:

    1. select command utility tool C++
    2. New Project
    3. Open main.cpp
    4. paste source code
    5. compile

    My laptop:
    Macbook with Tiger
    Xcode 2.5

    here is the original source file:

    and here is the updated source code i want to compile:

    any help would be appreciated!


  2. macrumors 6502a

    Dec 4, 2006
    Katy, Texas
    Can you post a picture of your xcodeproj window? Looks like this:

    Attached Files:

  3. macrumors 6502

    Jun 16, 2004
    If you look at XCode's build errors, you can see that:
    In timeinfo you don't have the payroll variable declared (probably want to use it as a parameter to the method) -- and you have 4 <s instead of 2.
    Theres a warning because timeinfo should return an int, but returns nothing.
    And theres a typo in main (paroll should probably be payroll).

    If you look at the bottom right hand corner of XCode after doing a build, it shows how many build errors and warnings you have. You can click on that to show you the problems.

    I took a screenshot (XCode 3) for you: http://home.earthlink.net/~valiantsoul/xcode.png
    If your XCode is < 3, it won't show the actual errors/warnings in the editor, but you will still see the markers and part at the bottom right.

Share This Page