Thread: VC++ 2005 /FC apparently not working

  1. #1
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446

    VC++ 2005 /FC apparently not working

    I'm playing with the predefined macros __FILE__ and __LINE__ and the preprocessor directive #line.

    Apparently, whether I set /FS (full path of source code) on the compiler options or not, it doesn't matter. It's always displaying the full path of source code files.

    Am I doing anything wrong?
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  2. #2
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    Ok... maybe I'm not phrasing this well enough. Although I don't think any code is needed, here goes...

    Code:
    #ifndef NDEBUG
    #line 12 "main.cpp"
        std::cerr << __FILE__ << std::endl;
        std::cerr << "Compiled: " << __DATE__ << " " << __TIME__ << std::endl;
    #endif
    Now, Visual C++ 2005 users out there, the above outputs __FILE__ as a fully qualified path name. The compiler option /FS defines this to be so.

    However, if I go to Project Properties -> Configuration Properties -> C/C++ -> Advanced and set Use Full Paths to No, it removes /FS and, according to the documentation, outputs just the file name without any path.

    But it's not working. File names keep showing with their full path. I'm wondering why. Some other compiler option affecting it? I can't find on the support site any known issue, so it must be me...
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  3. #3
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    Ok. Found the answer to this on the MSDN suppot forums.

    Edit & Continue (/ZI) also forces fully qualified path names.
    Solved
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Task list in VC 2005
    By VirtualAce in forum Tech Board
    Replies: 0
    Last Post: 05-13-2008, 08:59 PM
  2. Replies: 8
    Last Post: 01-18-2008, 04:06 AM
  3. If you must port to .NET 2005, read this thread.
    By VirtualAce in forum A Brief History of Cprogramming.com
    Replies: 3
    Last Post: 10-22-2007, 06:51 AM
  4. memcpy working strangely in msvc 2005
    By *DEAD* in forum C++ Programming
    Replies: 1
    Last Post: 06-15-2007, 09:50 AM
  5. Visual C++ 2005 Express Edition: Breakpoints not working
    By Bird Killer in forum C++ Programming
    Replies: 7
    Last Post: 03-31-2006, 10:38 AM