9103d232a5
Whenever a new gcc version is released that introduces new warnings, this breaks lots of builds on the user's side. This change pushes the detection of these new warnings a bit back until either a user reports warnings or developers get the new compiler updates. I think this is a good tradeoff since release builds are no longer totally broken as soon as a new compiler version comes out. Travis still uses -Werror because there we actually want builds to fail.
33 lines
821 B
Bash
Executable File
33 lines
821 B
Bash
Executable File
#!/bin/bash
|
|
mkdir -p "${TRAVIS_BUILD_DIR}/build"
|
|
cd "${TRAVIS_BUILD_DIR}/build" || false
|
|
|
|
FLAGS=""
|
|
|
|
# Disable all extra modules and X extensions for minimal builds
|
|
# Most of these should already be turned off because their libraries are not
|
|
# installed, but some may not be
|
|
if [ "$POLYBAR_BUILD_TYPE" == "minimal" ]; then
|
|
FLAGS=(
|
|
"-DENABLE_PULSEAUDIO=OFF"
|
|
"-DENABLE_NETWORK=OFF"
|
|
"-DENABLE_MPD=OFF"
|
|
"-DENABLE_CURL=OFF"
|
|
"-DENABLE_ALSA=OFF"
|
|
"-DENABLE_I3=OFF"
|
|
"-DWITH_XRM=OFF"
|
|
"-DWITH_XKB=OFF"
|
|
"-DWITH_XRANDR_MONITORS=OFF"
|
|
"-DWITH_XCURSOR=OFF"
|
|
"-DWITH_XRANDR=ON"
|
|
)
|
|
fi
|
|
|
|
cmake \
|
|
-DCMAKE_CXX_COMPILER="${CXX}" \
|
|
-DCMAKE_CXX_FLAGS="${CXXFLAGS} -Werror" \
|
|
-DCMAKE_BUILD_TYPE="${BUILD_TYPE}" \
|
|
-DBUILD_TESTS:BOOL="${BUILD_TESTS:-OFF}" \
|
|
-DBUILD_DOC:BOOL="${BUILD_DOC:-OFF}" \
|
|
"${FLAGS[@]}" ..
|