From 8f57ba0fb9ba439dfa21f2253beb0bcd207990b5 Mon Sep 17 00:00:00 2001 From: Pablo Barciela Date: Mon, 13 Apr 2020 23:45:54 +0200 Subject: Travis CI: debian build: add clang compiler --- .build.yml | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) diff --git a/.build.yml b/.build.yml index 93d25ad..172186d 100644 --- a/.build.yml +++ b/.build.yml @@ -90,6 +90,19 @@ variables: -enable-checker alpha.core.FixedAddr -enable-checker security.insecureAPI.strcpy"' +before_scripts: + - cd ${START_DIR} + - '[ -f mate-common-1.24.1.tar.xz ] || curl -Ls -o mate-common-1.24.1.tar.xz https://github.com/mate-desktop/mate-common/releases/download/v1.24.1/mate-common-1.24.1.tar.xz' + - tar xf mate-common-1.24.1.tar.xz + - cd mate-common-1.24.1 + - if [ ${DISTRO_NAME} == "debian" -o ${DISTRO_NAME} == "ubuntu" ];then + - ./configure --prefix=/usr --libdir=/usr/lib/x86_64-linux-gnu --libexecdir=/usr/lib/x86_64-linux-gnu + - else + - ./configure --prefix=/usr + - fi + - make + - make install + build_scripts: - if [ ${DISTRO_NAME} == "debian" ];then - export CFLAGS+=" -Wsign-compare -Wunused-parameter" @@ -99,24 +112,19 @@ build_scripts: - ./autogen.sh --enable-compile-warnings=maximum - scan-build $CHECKERS ./configure --enable-compile-warnings=maximum - if [ $CPU_COUNT -gt 1 ]; then + - if [ ${DISTRO_NAME} == "debian" ];then + - scan-build $CHECKERS --keep-cc --use-cc=clang --use-c++=clang++ -o html-report make -j $(( $CPU_COUNT + 1 )) + - make clean + - fi - scan-build $CHECKERS --keep-cc -o html-report make -j $(( $CPU_COUNT + 1 )) - else + - if [ ${DISTRO_NAME} == "debian" ];then + - scan-build $CHECKERS --keep-cc --use-cc=clang --use-c++=clang++ -o html-report make + - make clean + - fi - scan-build $CHECKERS --keep-cc -o html-report make - fi -before_scripts: - - cd ${START_DIR} - - '[ -f mate-common-1.24.1.tar.xz ] || curl -Ls -o mate-common-1.24.1.tar.xz https://github.com/mate-desktop/mate-common/releases/download/v1.24.1/mate-common-1.24.1.tar.xz' - - tar xf mate-common-1.24.1.tar.xz - - cd mate-common-1.24.1 - - if [ ${DISTRO_NAME} == "debian" -o ${DISTRO_NAME} == "ubuntu" ];then - - ./configure --prefix=/usr --libdir=/usr/lib/x86_64-linux-gnu --libexecdir=/usr/lib/x86_64-linux-gnu - - else - - ./configure --prefix=/usr - - fi - - make - - make install - after_scripts: - if [ ${DISTRO_NAME} == "fedora" ];then - cppcheck --xml --output-file=cppcheck.xml --enable=warning,style,performance,portability,information,missingInclude . -- cgit v1.2.1