http://cpp.gantep.edu.tr
C++ resources. Faculty of Engineering, University of Gaziantep
 MAIN  -  Tutorials  -  Howtos  -  nmPrimer  -  Misc  -  Links  -  Contacts
Last modified: Wed, 28 Oct 2009 17:15:41 +0200

Complete: ##------------------ (10%)

Misc: migrating your source code from gcc 3.4 to gcc 4.3

In 2009 the GNU project released gcc 4.3. This release supports new standards and may require source code that works under gcc 3.4 to be modified to work under gcc 4.3. For example if your code compiles ok under gcc 3.4 but compiles with errors under gcc 4.3 then you probably need to add a missing header.
Often this can be fixed with adding

#include <cstdlib>
for more details see porting to gcc-4.3 and The GNU C++ Library Documentation.

Some specific examples are:

  • To use INT_MIN, INT_MAX, RAND_MAX you should include the climits header.
  • To use rand() you should include the cstdlib header.
please send us you comments/questions/corrections