clang70_tests.sh 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. #!/usr/bin/env bash
  2. export CC=clang-7
  3. export CXX=clang++-7
  4. if [ "$NEWCC" != "" ]; then
  5. export CC="$NEWCC"
  6. fi
  7. if [ "$NEWCXX" != "" ]; then
  8. export CXX="$NEWCXX"
  9. fi
  10. export LOGFILE=clang70.log
  11. source ./tools/ci/scripts/init.sh
  12. # need fix -Wshadow-field
  13. # add -Wno-zero-as-null-pointer-constant due clang bug
  14. export CXXFLAGS="$CXXFLAGS -Weverything -Wno-documentation -Wno-padded -Wno-sign-conversion \
  15. -Wno-global-constructors -Wno-exit-time-destructors -Wno-weak-vtables \
  16. -Wno-overloaded-virtual -Wno-covered-switch-default -Wno-float-equal -Wno-conversion \
  17. -Wno-shorten-64-to-32 -Wno-missing-variable-declarations \
  18. -Wno-disabled-macro-expansion -Wno-format-nonliteral \
  19. -Wno-reserved-id-macro -Wno-packed -Wno-documentation-unknown-command \
  20. -Wno-variadic-macros -Wno-double-promotion -Wno-attributes -Wno-shadow-field \
  21. -Wpointer-bool-conversion -fno-omit-frame-pointer -Wno-c++98-compat-pedantic \
  22. -Wno-implicit-fallthrough -Wno-zero-as-null-pointer-constant \
  23. -ggdb3 -stdlib=libc++ $POST_CXXFLAGS"
  24. do_init
  25. run_configure --enable-unittests=yes $*
  26. export SDL_VIDEODRIVER=dummy
  27. run_make_check
  28. source ./tools/ci/scripts/exit.sh
  29. exit 0