Today We'll Talk Generally About C++ Development (Plus A Few Platform Specifics)
Today We'll Talk Generally About C++ Development (Plus A Few Platform Specifics)
1 source file
=
1 compilation unit
C++ source files
(ASCII text) .cpp
Also: .C .cxx .cc
Programmer
(you)
Also: .H .hxx .hpp
C++ header files
(ASCII text) .h
readme
(ASCII text)
public:
Simple (int i); int usage (char * program_name);
void print_i ();
private: struct Point2D {
int i_; double x_;
}; double y_;
};
#include <iostream>
using namespace std;
int main (int argc, char * argv[])
{
for (int i = 0; i < argc; ++i)
{
cout << argv[i] << endl;
}
return 0;
}
compile
(binary) .lib .a .dll .so Eclipse
link
C++ Visual Studio
Programmer source code
(you) debugger
precompiler
gcc, etc. link
compiler linker executable
compiler program
object code
(binary, one per compilation unit) .o