Monday, August 4, 2014

Project – C++11 Standard

Part of learning to use C++ more effectively should include the latest C++ standard, which at the moment is C++11.  Support for C++11 is being or has been implemented in compilers.  This project uses GCC (The GNU Compiler Collection), which is standard on Linux systems and can be installed on Windows systems (the MinGW program is the one recommended).  Sorry MAC OS-X users, I do not have access to MAC system to figure what is needed to build and run this project on OS-X even though OS-X is Linux like and shouldn't be much different than Linux.

Even though many of the recent GCC versions support various features of C++11 (which was previously known as C++0X before the standard was finalized) starting with GCC 4.3, all the C++11 features highlighted in the  The C++ Programming Language (Fourth Edition) by Bjarne Stroustrup require and more recent version of GCC, specifically GCC 4.8 or later.  Fortunately, this version is available both on Linux (the current Mint/Ubuntu LTS or Long-Term-Support versions) and MinGW (Windows).

The current version of GCC on Mint 13 LTS (Ubuntu 12.04 LTS) is only GCC 4.6.3.  Fortunately there is a way to update to GCC 4.8.1 by adding the tool chains repository.  On Mint 17 LTS (Ubuntu 14.04 LTS) GCC 4.8.2 is available.  The latest version installed with MinGW is also GCC 4.8.1.  However, since Qt is also required, it is easier to install Qt that includes MinGW, which happens to have GCC 4.8.2  GCC 4.8 should be sufficient for using the major C++11 features.  Details for upgrading and installing the necessary versions and tools will be provided in subsequent posts.

No comments:

Post a Comment

All comments and feedback welcomed, whether positive or negative.
(Anonymous comments are allowed, but comments with URL links or unrelated comments will be removed.)