1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-11-01 03:46:16 +00:00

Add GCC 4.6 to the TravisCI build.

With `-march=native`, we see assembler error messages like those described
in https://github.com/uzh-rpg/rpg_svo/issues/7 .
This commit is contained in:
Arthur O'Dwyer 2019-02-09 10:30:07 -05:00
parent 6e94dbf674
commit 5e8d03e90d
2 changed files with 27 additions and 2 deletions

View File

@ -3,6 +3,20 @@ services:
- docker - docker
matrix: matrix:
include: include:
- os: linux
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-4.6
- g++-4.6
env: >-
TRAVIS_OS_NAME=linux
TRAVIS_BUILD_SYSTEM=Makefile
HYPERROGUE_CXX=g++-4.6
HYPERROGUE_USE_GLEW=1
HYPERROGUE_USE_PNG=1
- os: linux - os: linux
compiler: gcc compiler: gcc
env: >- env: >-
@ -126,7 +140,7 @@ script:
./configure CXXFLAGS="-Wall -Werror" ./configure CXXFLAGS="-Wall -Werror"
make make
elif [[ "$TRAVIS_BUILD_SYSTEM" == "Makefile" ]]; then elif [[ "$TRAVIS_BUILD_SYSTEM" == "Makefile" ]]; then
make -f Makefile.simple make -f Makefile.simple CXX="${HYPERROGUE_CXX-g++}"
elif [[ "$TRAVIS_BUILD_SYSTEM" == "emscripten" ]]; then elif [[ "$TRAVIS_BUILD_SYSTEM" == "emscripten" ]]; then
docker run --rm -v $(pwd):/src trzeci/emscripten make -f Makefile.simple emscripten docker run --rm -v $(pwd):/src trzeci/emscripten make -f Makefile.simple emscripten
else else

View File

@ -32,10 +32,14 @@ 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
## We have now finished inspecting the environment via $(shell). ## We have now finished inspecting the environment via $(shell).
@ -91,6 +95,13 @@ ifeq (${TOOLCHAIN},gcc)
CXXFLAGS_EARLY += -Wno-maybe-uninitialized -Wno-missing-field-initializers -Wno-unused-parameter CXXFLAGS_EARLY += -Wno-maybe-uninitialized -Wno-missing-field-initializers -Wno-unused-parameter
endif endif
ifeq (${TOOLCHAIN},gcc46)
CXXFLAGS_EARLY += -std=c++0x
CXXFLAGS_EARLY += -W -Wall -Wextra -Werror
CXXFLAGS_EARLY += -Wno-missing-field-initializers -Wno-unused-parameter
CXXFLAGS_EARLY += -DUSE_STDFUNCTION=1
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