Skip to content

Commit

Permalink
Dropped GCC 4.6 support.
Browse files Browse the repository at this point in the history
  • Loading branch information
mosra committed May 24, 2014
1 parent fcde0b6 commit a9a5ead
Show file tree
Hide file tree
Showing 79 changed files with 42 additions and 758 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Expand Up @@ -108,8 +108,8 @@ if(BUILD_TESTS)
endif()

# Check compiler compatibility
if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU" AND "${CMAKE_CXX_COMPILER_VERSION}" VERSION_LESS "4.6.0")
message(FATAL_ERROR "Compatibility branch of Magnum is needed for use with GCC < 4.6. See the documentation for more information.")
if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU" AND "${CMAKE_CXX_COMPILER_VERSION}" VERSION_LESS "4.7.0")
message(FATAL_ERROR "Compatibility branch of Magnum is needed for use with GCC < 4.7. See the documentation for more information.")
elseif(MSVC)
message(FATAL_ERROR "Compatibility branch of Magnum is needed for use with MSVC. See the documentation for more information.")
endif()
Expand Down
6 changes: 3 additions & 3 deletions README.md
Expand Up @@ -84,9 +84,9 @@ Minimal dependencies
--------------------

* C++ compiler with good C++11 support. Currently there are two compilers
which are tested to have everything needed: **GCC** >= 4.6 and **Clang**
>= 3.1. On Windows you can use **MinGW**. GCC 4.5, 4.4 and **MSVC** 2013
support involves some ugly workarounds and thus is available only in
which are tested to have everything needed: **GCC** >= 4.7 and **Clang**
>= 3.1. On Windows you can use **MinGW**. GCC 4.6, 4.5, 4.4 and **MSVC**
2013 support involves some ugly workarounds and thus is available only in
`compatibility` branch.
* **CMake** >= 2.8.8
* **Corrade** - Plugin management and utility library. You can get it at
Expand Down
8 changes: 4 additions & 4 deletions doc/building.dox
Expand Up @@ -33,9 +33,9 @@ namespace Magnum {
Minimal set of tools and libraries required for building is:

- C++ compiler with good C++11 support. Currently there are two compilers
which are tested to have everything needed: **GCC** >= 4.6 and **Clang**
>= 3.1. On Windows you can use **MinGW**. GCC 4.5, 4.4 and **MSVC** 2013
support involves some ugly workarounds and thus is available only in
which are tested to have everything needed: **GCC** >= 4.7 and **Clang**
>= 3.1. On Windows you can use **MinGW**. GCC 4.6, 4.5, 4.4 and **MSVC**
2013 support involves some ugly workarounds and thus is available only in
`compatibility` branch.
- **CMake** >= 2.8.8
- **Corrade** - Plugin management and utility library. See
Expand Down Expand Up @@ -493,7 +493,7 @@ or `update-job`).

Build is done using **Ninja** build system and everything possible is enabled,
thus you need also **SDL2**, **GLUT** and **OpenAL** libraries. It expects that
**GCC** >=4.8.2, 4.7, 4.6 and **Clang** are installed and there are **OpenGL**,
**GCC** >=4.8.2, 4.7 and **Clang** are installed and there are **OpenGL**,
**OpenGL ES 2.0** and **OpenGL ES 3.0** librares as it tries to compile the
library with every combination of them. You can add/remove the axes in
`axes/hudson.matrix.TextAxis` or via the web interface later.
Expand Down
2 changes: 1 addition & 1 deletion doc/portability.dox
Expand Up @@ -70,7 +70,7 @@ for more information.

Each feature is marked accordingly if it is not available on some compilers,
see @ref SceneGraph::DrawableGroup3D for an example. It is up to you (or your
platform) which compiler your code will support, code written for e.g. GCC 4.6
platform) which compiler your code will support, code written for e.g. GCC 4.7
will work also on Magnum compiled with support for newer compilers, although
newer compilers may catch errors that weren't spotted by earlier versions.

Expand Down
56 changes: 0 additions & 56 deletions package/archlinux/PKGBUILD-gcc46

This file was deleted.

1 change: 0 additions & 1 deletion package/ci/jenkins-gltests.xml
Expand Up @@ -52,7 +52,6 @@
<values>
<string>g++</string>
<string>g++-4.7</string>
<string>g++-4.6</string>
<string>clang++</string>
<string>clang++-libc++</string>
</values>
Expand Down
1 change: 0 additions & 1 deletion package/ci/jenkins.xml
Expand Up @@ -54,7 +54,6 @@
<values>
<string>g++</string>
<string>g++-4.7</string>
<string>g++-4.6</string>
<string>clang++</string>
<string>clang++-libc++</string>
</values>
Expand Down
7 changes: 0 additions & 7 deletions src/CMakeLists.txt
Expand Up @@ -23,13 +23,6 @@
# DEALINGS IN THE SOFTWARE.
#

# Disable `-pedantic` for GCC 4.6, as the compiler doesn't like
# list-initialization of array of classes (RectangularMatrix constructors). It
# is perfectly legal C++11 and both GCC 4.7 and Clang accept it without notice.
if(CORRADE_GCC46_COMPATIBILITY)
string(REPLACE "-pedantic" "" CORRADE_CXX_FLAGS "${CORRADE_CXX_FLAGS}")
endif()

# On 4.8.2 strict aliasing causes failure of DebugToolsCylinderRendererTest
# without any warning, only in release build, any attempt to add debug print
# results in issue disappearing. Not an issue on Clang or GCC < 4.8.
Expand Down
6 changes: 0 additions & 6 deletions src/Magnum/Array.h
Expand Up @@ -73,13 +73,7 @@ template<UnsignedInt dimensions, class T> class Array {
#ifdef DOXYGEN_GENERATING_OUTPUT
constexpr /*implicit*/ Array(T value);
#else
#ifndef CORRADE_GCC46_COMPATIBILITY
template<class U, class V = typename std::enable_if<std::is_same<T, U>::value && dimensions != 1, T>::type> constexpr /*implicit*/ Array(U value): Array(typename Math::Implementation::GenerateSequence<dimensions>::Type(), value) {}
#else
template<class U, class V = typename std::enable_if<std::is_same<T, U>::value && dimensions != 1, T>::type> /*implicit*/ Array(U value) {
*this = Array(typename Math::Implementation::GenerateSequence<dimensions>::Type(), value);
}
#endif
#endif

/** @brief Equality */
Expand Down
4 changes: 0 additions & 4 deletions src/Magnum/Context.cpp
Expand Up @@ -424,11 +424,7 @@ Context::Context() {
std::unordered_map<std::string, Extension> futureExtensions;
for(std::size_t i = future; i != versions.size(); ++i)
for(const Extension& extension: Extension::extensions(versions[i]))
#ifndef CORRADE_GCC46_COMPATIBILITY
futureExtensions.emplace(extension._string, extension);
#else
futureExtensions.insert({extension._string, extension});
#endif

/* Check for presence of future and vendor extensions */
const std::vector<std::string> extensions = extensionStrings();
Expand Down
9 changes: 0 additions & 9 deletions src/Magnum/DebugTools/ForceRenderer.cpp
Expand Up @@ -41,23 +41,14 @@ template<UnsignedInt dimensions> ResourceKey shaderKey();
template<> inline ResourceKey shaderKey<2>() { return ResourceKey("FlatShader2D"); }
template<> inline ResourceKey shaderKey<3>() { return ResourceKey("FlatShader3D"); }

/** @bug Why this is not constexpr under GCC 4.6? */
#ifndef CORRADE_GCC46_COMPATIBILITY
constexpr std::array<Vector2, 4> positions{{
#else
const std::array<Vector2, 4> positions{{
#endif
{0.0f, 0.0f},
{1.0f, 0.0f},
{0.9f, 0.1f},
{0.9f, -0.1f}
}};

#ifndef CORRADE_GCC46_COMPATIBILITY
constexpr std::array<UnsignedByte, 6> indices{{
#else
const std::array<UnsignedByte, 6> indices{{
#endif
0, 1,
1, 2,
1, 3
Expand Down
2 changes: 0 additions & 2 deletions src/Magnum/DebugTools/Implementation/AxisAlignedBoxRenderer.h
Expand Up @@ -25,8 +25,6 @@
DEALINGS IN THE SOFTWARE.
*/

#include <Corrade/compatibility.h>

#include "Magnum/Shapes/Shapes.h"

#include "AbstractBoxRenderer.h"
Expand Down
2 changes: 0 additions & 2 deletions src/Magnum/DebugTools/Implementation/BoxRenderer.h
Expand Up @@ -25,8 +25,6 @@
DEALINGS IN THE SOFTWARE.
*/

#include <Corrade/compatibility.h>

#include "Magnum/Shapes/Shapes.h"

#include "AbstractBoxRenderer.h"
Expand Down
2 changes: 0 additions & 2 deletions src/Magnum/DebugTools/Implementation/CapsuleRenderer.h
Expand Up @@ -25,8 +25,6 @@
DEALINGS IN THE SOFTWARE.
*/

#include <Corrade/compatibility.h>

#include "Magnum/Shapes/Shapes.h"

#include "AbstractShapeRenderer.h"
Expand Down
2 changes: 0 additions & 2 deletions src/Magnum/DebugTools/Implementation/CylinderRenderer.h
Expand Up @@ -25,8 +25,6 @@
DEALINGS IN THE SOFTWARE.
*/

#include <Corrade/compatibility.h>

#include "Magnum/Shapes/Shapes.h"

#include "AbstractShapeRenderer.h"
Expand Down
2 changes: 0 additions & 2 deletions src/Magnum/DebugTools/Implementation/LineSegmentRenderer.h
Expand Up @@ -25,8 +25,6 @@
DEALINGS IN THE SOFTWARE.
*/

#include <Corrade/compatibility.h>

#include "Magnum/Shapes/Shapes.h"

#include "AbstractShapeRenderer.h"
Expand Down
2 changes: 0 additions & 2 deletions src/Magnum/DebugTools/Implementation/PointRenderer.h
Expand Up @@ -25,8 +25,6 @@
DEALINGS IN THE SOFTWARE.
*/

#include <Corrade/compatibility.h>

#include "Magnum/Shapes/Shapes.h"

#include "AbstractShapeRenderer.h"
Expand Down
2 changes: 0 additions & 2 deletions src/Magnum/DebugTools/Implementation/SphereRenderer.h
Expand Up @@ -25,8 +25,6 @@
DEALINGS IN THE SOFTWARE.
*/

#include <Corrade/compatibility.h>

#include "Magnum/Shapes/Shapes.h"

#include "AbstractShapeRenderer.h"
Expand Down

0 comments on commit a9a5ead

Please sign in to comment.