Forums
New posts
Articles
Product Reviews
Policies
FAQ
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Menu
Log in
Register
Install the app
Install
Forums
macOS & iOS Developer Playground
macOS - Development and Darwin
How to compile (without building) a .c/.cpp file with Xcode?
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="smallmountain" data-source="post: 1531464" data-attributes="member: 308920"><p>Could this be correct? XCode will not let you simply compile a .cpp file to its object file without building the entire project? Visual Studio lets you do this. It is very helpful when you are changing a header file, say with templates in it, that is widely included in your project, but only one or two source files use the template class or function that you are trying to get right. I like to compile the .cpp file to make sure I don't have a stupid error, and then once the .cpp file compiles, then I fire up a build that might take 10 minutes. Maybe I have link errors after the build, so I repeat the cycle, but at least I am not waiting 10 minutes to find out I have a simple error.</p></blockquote><p></p>
[QUOTE="smallmountain, post: 1531464, member: 308920"] Could this be correct? XCode will not let you simply compile a .cpp file to its object file without building the entire project? Visual Studio lets you do this. It is very helpful when you are changing a header file, say with templates in it, that is widely included in your project, but only one or two source files use the template class or function that you are trying to get right. I like to compile the .cpp file to make sure I don't have a stupid error, and then once the .cpp file compiles, then I fire up a build that might take 10 minutes. Maybe I have link errors after the build, so I repeat the cycle, but at least I am not waiting 10 minutes to find out I have a simple error. [/QUOTE]
Verification
Post reply
Forums
macOS & iOS Developer Playground
macOS - Development and Darwin
How to compile (without building) a .c/.cpp file with Xcode?
Top