From e0724780f7ce296811bb67aa030ed629de99a118 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= Date: Fri, 29 Sep 2017 14:06:02 +0200 Subject: [PATCH] Build-require git for optional tests Tests, e.g. ExternalProject, either need no git command or "git submodule" command to pass. This is not true if git-core package is installed without git package. --- cmake.spec | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/cmake.spec b/cmake.spec index 99b9f0d..c5b905b 100644 --- a/cmake.spec +++ b/cmake.spec @@ -12,6 +12,9 @@ # Build with Emacs support %bcond_without cmake_enables_emacs +# Run git tests +%bcond_without cmake_enables_git_test + # Set to bcond_with or use --without gui to disable qt4 gui build %bcond_without cmake_enables_gui @@ -105,6 +108,12 @@ BuildRequires: findutils BuildRequires: gcc-c++ BuildRequires: gcc-gfortran BuildRequires: sed +%if %{with cmake_enables_git_test} +# Tests fail if only git-core is installed, bug #1488830 +BuildRequires: git +%else +BuildConflicts: git-core +%endif %if %{with cmake_enables_X11_test} BuildRequires: libX11-devel %endif