travis: enable strict C++11 compilation
This commit is contained in:
parent
93326f2a6e
commit
56ce328268
2 changed files with 2 additions and 19 deletions
|
@ -40,6 +40,7 @@ before_install:
|
|||
|
||||
- if [ "$BUILD" = 3 ]; then export ALTERNATE_CONFIGURATION=true; fi
|
||||
- if [ "$BUILD" = 4 ]; then export CXX11=true; fi
|
||||
- if [ "$BUILD" = 4 ]; then export EXTRA_FLAGS_RELEASE="-O0 -Wno-literal-suffix -Wno-deprecated-declarations"
|
||||
- if [ "$BUILD" = 4 ]; then export CPP_TESTS=false; fi
|
||||
- if [ "$BUILD" = 5 ]; then export NLS=true; fi
|
||||
- if [ "$BUILD" = 5 ]; then export TARGETS="translations"; fi
|
||||
|
@ -53,7 +54,7 @@ before_install:
|
|||
- if [ "$CXX" = "g++" ]; then export WML_TESTS=false; fi
|
||||
- if [ "$CXX" = "g++" ]; then export PLAY_TEST=false; fi
|
||||
- if [ "$CXX" = "g++" ]; then export CHECK_UTF8=false; fi
|
||||
- if [ "$CXX11" = true ]; then export STRICT_COMPILATION=false; fi
|
||||
# - if [ "$CXX11" = true ]; then export STRICT_COMPILATION=false; fi
|
||||
|
||||
install:
|
||||
- sudo add-apt-repository -y "deb http://archive.ubuntu.com/ubuntu/ saucy main universe"
|
||||
|
|
|
@ -5,26 +5,8 @@
|
|||
* http://www.libpng.org/pub/png/src/libpng-LICENSE.txt
|
||||
*/
|
||||
#include <SDL.h>
|
||||
|
||||
#ifdef __GNUC__
|
||||
#if __GNUC__ > 4 || __GNUC__== 4 && __GNUC_MINOR__ >= 9
|
||||
#define HAVE_GCC_4_9
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_GCC_4_9
|
||||
#pragma GCC diagnostic push
|
||||
#ifndef __clang__
|
||||
#pragma GCC diagnostic ignored "-Wliteral-suffix" //GCC 4.9 with C++11 gives a warning about this in libpng header
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#include <png.h>
|
||||
|
||||
#ifdef HAVE_GCC_4_9
|
||||
#pragma GCC diagnostic pop
|
||||
#endif
|
||||
|
||||
#include "savepng.h"
|
||||
|
||||
#define SAVEPNG_SUCCESS 0
|
||||
|
|
Loading…
Add table
Reference in a new issue