diff --git a/libreoffice.spec b/libreoffice.spec index 0cabdb9..53a5f24 100644 --- a/libreoffice.spec +++ b/libreoffice.spec @@ -327,13 +327,8 @@ BuildRequires: libmariadb-devel BuildRequires: pkgconfig(icu-i18n) BuildRequires: pkgconfig(libopenjp2) %endif -%if 0%{?with_gcc:1} -BuildRequires: gcc%{with_gcc} -BuildRequires: gcc%{with_gcc}-c++ -%else -BuildRequires: gcc -BuildRequires: gcc-c++ -%endif +BuildRequires: gcc%{?with_gcc} +BuildRequires: gcc%{?with_gcc}-c++ BuildRequires: java-devel >= 1.8 %if 0%{?suse_version} # needed by python3_sitelib @@ -1096,7 +1091,7 @@ CFLAGS="$ARCH_FLAGS" CXXFLAGS="-std=c++20 $ARCH_FLAGS" export ARCH_FLAGS CFLAGS CXXFLAGS -%if 0%{?with_gcc:1} +%if 0%{?with_gcc} export CC=gcc-%{with_gcc} export CXX=g++-%{with_gcc} %endif