mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-01-23 15:36:59 +00:00
Remove all GCC 4.6 support; new minimum is GCC 5.4.
This commit is contained in:
parent
8c87f123a0
commit
d0a6212fd4
@ -9,15 +9,14 @@ matrix:
|
|||||||
sources:
|
sources:
|
||||||
- ubuntu-toolchain-r-test
|
- ubuntu-toolchain-r-test
|
||||||
packages:
|
packages:
|
||||||
- gcc-4.6
|
- gcc-5
|
||||||
- g++-4.6
|
- g++-5
|
||||||
env: >-
|
env: >-
|
||||||
TRAVIS_OS_NAME=linux
|
TRAVIS_OS_NAME=linux
|
||||||
TRAVIS_BUILD_SYSTEM=Makefile
|
TRAVIS_BUILD_SYSTEM=Makefile
|
||||||
HYPERROGUE_CXX=g++-4.6
|
HYPERROGUE_CXX=g++-5
|
||||||
HYPERROGUE_USE_GLEW=1
|
HYPERROGUE_USE_GLEW=1
|
||||||
HYPERROGUE_USE_PNG=1
|
HYPERROGUE_USE_PNG=1
|
||||||
EXTRA_CXXFLAGS=-DGCC46
|
|
||||||
- os: linux
|
- os: linux
|
||||||
compiler: gcc
|
compiler: gcc
|
||||||
env: >-
|
env: >-
|
||||||
|
@ -32,13 +32,9 @@ else
|
|||||||
TOOLCHAIN_VERSION_S := $(shell $(CXX) --version)
|
TOOLCHAIN_VERSION_S := $(shell $(CXX) --version)
|
||||||
ifneq (,$(findstring clang,$(TOOLCHAIN_VERSION_S)))
|
ifneq (,$(findstring clang,$(TOOLCHAIN_VERSION_S)))
|
||||||
TOOLCHAIN := clang
|
TOOLCHAIN := clang
|
||||||
else
|
|
||||||
ifneq (,$(findstring 4.6.,$(TOOLCHAIN_VERSION_S)))
|
|
||||||
TOOLCHAIN := gcc46
|
|
||||||
else
|
else
|
||||||
TOOLCHAIN := gcc
|
TOOLCHAIN := gcc
|
||||||
endif
|
endif
|
||||||
endif
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
||||||
@ -95,12 +91,6 @@ ifeq (${TOOLCHAIN},gcc)
|
|||||||
CXXFLAGS_EARLY += -Wno-unknown-warning-option -Wno-maybe-uninitialized -Wno-missing-field-initializers -Wno-unused-parameter -Wno-implicit-fallthrough -Wno-maybe-uninitialized
|
CXXFLAGS_EARLY += -Wno-unknown-warning-option -Wno-maybe-uninitialized -Wno-missing-field-initializers -Wno-unused-parameter -Wno-implicit-fallthrough -Wno-maybe-uninitialized
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq (${TOOLCHAIN},gcc46)
|
|
||||||
CXXFLAGS_EARLY += -std=c++0x
|
|
||||||
CXXFLAGS_EARLY += -W -Wall -Wextra -Werror
|
|
||||||
CXXFLAGS_EARLY += -Wno-unknown-warning-option -Wno-missing-field-initializers -Wno-unused-parameter -Wno-implicit-fallthrough -Wno-maybe-uninitialized
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq (${TOOLCHAIN},mingw)
|
ifeq (${TOOLCHAIN},mingw)
|
||||||
CXXFLAGS_EARLY += -std=c++11 -march=native
|
CXXFLAGS_EARLY += -std=c++11 -march=native
|
||||||
CXXFLAGS_EARLY += -W -Wall -Wextra -Werror
|
CXXFLAGS_EARLY += -W -Wall -Wextra -Werror
|
||||||
|
@ -47,21 +47,11 @@ eVariation variation;
|
|||||||
struct hyperpoint : array<ld, MAXMDIM> {
|
struct hyperpoint : array<ld, MAXMDIM> {
|
||||||
hyperpoint() {}
|
hyperpoint() {}
|
||||||
|
|
||||||
#if ISGCC46
|
|
||||||
#if MAXMDIM == 4
|
|
||||||
// aaa
|
|
||||||
constexpr hyperpoint(ld x, ld y, ld z, ld w) : array<ld, MAXMDIM> { (array<ld, MAXMDIM>) {{x, y, z, w}}} {}
|
|
||||||
#else
|
|
||||||
constexpr hyperpoint(ld x, ld y, ld z, ld w) : array<ld, MAXMDIM> { (array<ld, MAXMDIM>) {{x, y, z}}} {}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#else
|
|
||||||
#if MAXMDIM == 4
|
#if MAXMDIM == 4
|
||||||
constexpr hyperpoint(ld x, ld y, ld z, ld w) : array<ld, MAXMDIM> {{x,y,z,w}} {}
|
constexpr hyperpoint(ld x, ld y, ld z, ld w) : array<ld, MAXMDIM> {{x,y,z,w}} {}
|
||||||
#else
|
#else
|
||||||
constexpr hyperpoint(ld x, ld y, ld z, ld w) : array<ld, MAXMDIM> {{x,y,z}} {}
|
constexpr hyperpoint(ld x, ld y, ld z, ld w) : array<ld, MAXMDIM> {{x,y,z}} {}
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
|
|
||||||
inline hyperpoint& operator *= (ld d) {
|
inline hyperpoint& operator *= (ld d) {
|
||||||
for(int i=0; i<MDIM; i++) self[i] *= d;
|
for(int i=0; i<MDIM; i++) self[i] *= d;
|
||||||
|
@ -216,7 +216,7 @@ EX void apply_memory_reserve() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch(std::bad_alloc&) {}
|
catch(std::bad_alloc&) {}
|
||||||
#if (ISGCC46 || ISWINDOWS)
|
#if ISWINDOWS
|
||||||
// no get_new_handler on this compiler...
|
// no get_new_handler on this compiler...
|
||||||
default_handler = [] { throw std::bad_alloc(); };
|
default_handler = [] { throw std::bad_alloc(); };
|
||||||
#else
|
#else
|
||||||
|
@ -48,13 +48,6 @@
|
|||||||
#define ISSTEAM 0
|
#define ISSTEAM 0
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if GCC46
|
|
||||||
#define override
|
|
||||||
#define ISGCC46 1
|
|
||||||
#else
|
|
||||||
#define ISGCC46 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef ISWEB
|
#ifndef ISWEB
|
||||||
#define ISWEB 0
|
#define ISWEB 0
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user