rename testsuite bcond to tests; latest ghc-rpm-macros sets --enable-tests

This commit is contained in:
Jens Petersen 2014-05-16 23:55:02 +09:00
parent ad3dbe25bd
commit cc8eee5dcb
1 changed files with 12 additions and 9 deletions

View File

@ -1,10 +1,13 @@
# https://fedoraproject.org/wiki/Packaging:Haskell # https://fedoraproject.org/wiki/Packaging:Haskell
%global pkg_name shake
%ifarch %{ix86} x86_64 %ifarch %{ix86} x86_64
%bcond_without testsuite %bcond_without tests
%endif %endif
%global pkg_name shake # no useful debuginfo for Haskell packages without C sources
%global debug_package %{nil}
Name: %{pkg_name} Name: %{pkg_name}
Version: 0.11.4 Version: 0.11.4
@ -13,7 +16,7 @@ Summary: Make-like build system
License: BSD License: BSD
URL: http://hackage.haskell.org/package/%{name} URL: http://hackage.haskell.org/package/%{name}
Source0: http://hackage.haskell.org/packages/archive/%{name}/%{version}/%{name}-%{version}.tar.gz Source0: http://hackage.haskell.org/package/%{name}-%{version}/%{name}-%{version}.tar.gz
BuildRequires: ghc-Cabal-devel BuildRequires: ghc-Cabal-devel
BuildRequires: ghc-rpm-macros BuildRequires: ghc-rpm-macros
@ -32,10 +35,10 @@ BuildRequires: ghc-transformers-devel
BuildRequires: ghc-unix-devel BuildRequires: ghc-unix-devel
BuildRequires: ghc-unordered-containers-devel BuildRequires: ghc-unordered-containers-devel
BuildRequires: ghc-utf8-string-devel BuildRequires: ghc-utf8-string-devel
# End cabal-rpm deps %if %{with tests}
%if %{with testsuite}
BuildRequires: ghc-QuickCheck-devel BuildRequires: ghc-QuickCheck-devel
%endif %endif
# End cabal-rpm deps
BuildRequires: dos2unix BuildRequires: dos2unix
%description %description
@ -90,9 +93,6 @@ done
%build %build
%if %{with testsuite}
%global cabal_configure_options --enable-tests
%endif
%ghc_lib_build %ghc_lib_build
@ -105,7 +105,7 @@ rm %{buildroot}%{_datadir}/%{name}-%{version}/html/*
%check %check
%if %{with testsuite} %if %{with tests}
%cabal test %cabal test
%endif %endif
@ -132,6 +132,9 @@ rm %{buildroot}%{_datadir}/%{name}-%{version}/html/*
%changelog %changelog
* Fri May 16 2014 Jens Petersen <petersen@redhat.com> - 0.11.4-3
- adapt to new tests bcond in ghc-rpm-macros
* Mon Apr 14 2014 Jens Petersen <petersen@redhat.com> - 0.11.4-3 * Mon Apr 14 2014 Jens Petersen <petersen@redhat.com> - 0.11.4-3
- use global to define cabal_configure_options (#1082515) - use global to define cabal_configure_options (#1082515)