IT Community - Software Programming, Web Development and Technical Support

How to C++ compilation works?

This is a discussion on How to C++ compilation works? within the C and C++ Programming forums, part of the Software Development category; Compiling a C++ program involves a number of steps (most of which are transparent to the user): First the C++ ...


Go Back   IT Community - Software Programming, Web Development and Technical Support > Software Development > C and C++ Programming

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 07-16-2007, 09:23 PM
ragavraj ragavraj is offline
D-Web Programmer
 
Join Date: Feb 2007
Posts: 92
ragavraj is on a distinguished road
Default How to C++ compilation works?

Compiling a C++ program involves a number of steps (most of which are transparent to the user):

First the C++ preprocessor goes over the program text and carries out the instructions specified by the preprocessor directives (e.g #includes). The result is a modified program text which no longer contains any directives

Then the C++ Compiler translates the program code. The compiler may be a true C++ compiler which generates native (assembly or machine) code or just a translator which translates the code into c. In the latter case the resulting c code is then passed through a c compiler to produce native object code. In either case the outcome may be incomplete due to the program referring to library routines which are not defined as a part of the program.


Finally the linker completes the object code by linking it with the object code of any library modules that the program may have referred to. The final result is an executable file

Thanks
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
What shopping cart program works best? LennyP eCommerce 4 12-03-2008 11:23 PM
Frame works in php venkatbi PHP Programming 10 12-05-2007 04:00 AM
Spamming works? nhoj Promotion Techniques 6 10-04-2007 10:35 AM
compilation unit anbuchezhians Java Programming 1 07-30-2007 12:02 AM
Frame works in ajax varghese HTML, CSS and Javascript Coding Techniques 1 07-17-2007 05:18 AM


All times are GMT -7. The time now is 07:31 PM.


Copyright ©2004 - 2007, DiscussWeb. All Rights Reserved.

SEO by vBSEO 3.0.0