diff --git a/contrib/fedora/rpm/NetworkManager.spec b/contrib/fedora/rpm/NetworkManager.spec index 255c2178d3..1285977603 100644 --- a/contrib/fedora/rpm/NetworkManager.spec +++ b/contrib/fedora/rpm/NetworkManager.spec @@ -56,7 +56,7 @@ %bcond_without nmtui %bcond_without regen_docs %bcond_with debug -%bcond_without test +%bcond_with test %bcond_with sanitizer %if 0%{?fedora} > 28 || 0%{?rhel} > 7 %bcond_with libnm_glib @@ -541,7 +541,11 @@ intltoolize --automake --copy --force --with-system-ca-path=/etc/pki/tls/cert.pem \ --with-dbus-sys-dir=%{dbus_sys_dir} \ --with-tests=yes \ +%if %{with test} + --enable-more-warnings=error \ +%else --enable-more-warnings=yes \ +%endif --with-valgrind=no \ --enable-ifcfg-rh=yes \ %if %{with ppp} diff --git a/contrib/fedora/rpm/build_clean.sh b/contrib/fedora/rpm/build_clean.sh index c6d08f538c..888cac8cbb 100755 --- a/contrib/fedora/rpm/build_clean.sh +++ b/contrib/fedora/rpm/build_clean.sh @@ -41,7 +41,7 @@ IGNORE_DIRTY=0 GIT_CLEAN=0 QUICK=0 NO_DIST=0 -WITH_LIST=() +WITH_LIST=(--with test) SOURCE_FROM_GIT=0 SNAPSHOT="$NM_BUILD_SNAPSHOT" @@ -157,10 +157,6 @@ if [[ $NO_DIST != 1 ]]; then fi fi -if [[ $QUICK == 1 ]]; then - WITH_LIST=(--without test "${WITH_LIST[@]}") -fi - export SOURCE_FROM_GIT export BUILDTYPE export NM_RPMBUILD_ARGS="${WITH_LIST[@]}"