From a397a400d44c0dd5d38eab3edaae3ff368cae277 Mon Sep 17 00:00:00 2001 From: Sitsofe Wheeler Date: Sun, 13 Aug 2017 09:03:46 +0100 Subject: [PATCH] ci: make CI builds fail on compilation warnings Fio currently builds without warnings using its default options on at least the platforms where CI is run (Linux, macOS, Windows). Unfortunately it's easy to overlook changes that start generating warnings on a platform you don't use regularly. Make this problem more visible by changing appveyor/travis CI builds to fail when compilation warnings are produced (but don't make this change for normal manual builds). Signed-off-by: Sitsofe Wheeler --- .travis.yml | 2 ++ appveyor.yml | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index e84e61fa..4cdda129 100644 --- a/.travis.yml +++ b/.travis.yml @@ -26,3 +26,5 @@ matrix: before_install: - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get -qq update; fi - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get install -qq -y libaio-dev libnuma-dev libz-dev; fi +script: + - ./configure --extra-cflags="-Werror" && make && make test diff --git a/appveyor.yml b/appveyor.yml index 75433935..39f50a80 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -13,7 +13,7 @@ environment: build_script: - SET PATH=%CYG_ROOT%\bin;%PATH% - - 'bash.exe -lc "cd \"${APPVEYOR_BUILD_FOLDER}\" && ./configure ${CONFIGURE_OPTIONS} && make.exe' + - 'bash.exe -lc "cd \"${APPVEYOR_BUILD_FOLDER}\" && ./configure --extra-cflags=\"-Werror\" ${CONFIGURE_OPTIONS} && make.exe' after_build: - cd os\windows && dobuild.cmd %BUILD_ARCH% -- 2.25.1