gcc5_sdl2_tests.sh 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. #!/usr/bin/env bash
  2. export CC=gcc-5
  3. export CXX=g++-5
  4. if [ "$NEWCC" != "" ]; then
  5. export CC="$NEWCC"
  6. fi
  7. if [ "$NEWCXX" != "" ]; then
  8. export CXX="$NEWCXX"
  9. fi
  10. export LOGFILE=gcc5_sdl2_tests.log
  11. source ./tools/ci/scripts/init.sh
  12. export CXXFLAGS="-ggdb3 -O2 -pipe -ffast-math \
  13. -fno-omit-frame-pointer -funswitch-loops \
  14. -Wvariadic-macros -Wvla -Wredundant-decls \
  15. -Wpacked-bitfield-compat -Wtrampolines \
  16. -Wsuggest-attribute=noreturn -Wunused -Wstrict-aliasing=2 \
  17. -fstrict-aliasing -Wunreachable-code \
  18. -Wvolatile-register-var -Winvalid-pch -Wredundant-decls \
  19. -Wnormalized=nfkc -Wmissing-format-attribute -Wmissing-noreturn \
  20. -Wswitch-default -Wsign-promo -Waddress -Wmissing-declarations \
  21. -Wctor-dtor-privacy -Wstrict-null-sentinel -Wlogical-op \
  22. -Wcast-align -Wpointer-arith -Wundef \
  23. -Wmissing-include-dirs -Winit-self -pedantic -Wall \
  24. -Wpacked -Wextra -fstrict-overflow -Wstrict-overflow=1 -Wunknown-pragmas \
  25. -Wwrite-strings -Wstack-protector -Wshadow -Wunused-macros -Wsynth \
  26. -Wbuiltin-macro-redefined -Wctor-dtor-privacy -Wdeprecated \
  27. -Wendif-labels -Wformat=1 -Wimport -Wnon-virtual-dtor -Wpsabi \
  28. -Wsign-promo -Wwrite-strings -D_FORTIFY_SOURCE=2 -std=gnu++1y \
  29. -Wdelete-non-virtual-dtor -Wmaybe-uninitialized -Wunused-local-typedefs \
  30. -Wvector-operation-performance -Wfree-nonheap-object -Winvalid-memory-model \
  31. -Wnarrowing -Wzero-as-null-pointer-constant -funsafe-loop-optimizations \
  32. -Waggressive-loop-optimizations -Wclobbered -Wempty-body \
  33. -Wignored-qualifiers -Wliteral-suffix -Wmissing-field-initializers \
  34. -Woverlength-strings -Wpedantic -Wsign-compare -Wsizeof-pointer-memaccess \
  35. -Wsuggest-attribute=format -Wtype-limits -Wuninitialized \
  36. -Wunused-but-set-parameter -Wunused-but-set-variable -Wunused-function \
  37. -Wunused-label -Wunused-parameter -Wunused-value -Wunused-variable -ftrapv \
  38. -fsched-pressure \
  39. -Wconditionally-supported -Wdate-time \
  40. -fno-var-tracking -Wno-attributes \
  41. -Wopenmp-simd -Wformat-signedness \
  42. -Wswitch-bool -Wmemset-transposed-args -Wchkp -Wc++14-compat -Wsized-deallocation \
  43. -Wlogical-not-parentheses -Woverloaded-virtual"
  44. do_init
  45. run_configure --with-sdl2 --enable-unittests=yes $*
  46. export SDL_VIDEODRIVER=dummy
  47. run_make_check
  48. source ./tools/ci/scripts/exit.sh
  49. exit 0