subpackages are now all packaged in Fedora

This commit is contained in:
Jens Petersen 2017-10-23 18:53:25 +09:00
parent 3a9a9ce1dd
commit 524df7ecc4
1 changed files with 10 additions and 36 deletions

View File

@ -4,41 +4,30 @@
%global pkg_name uuid
%global pkgver %{pkg_name}-%{version}
%global cryptohashmd5 cryptohash-md5-0.11.100.1
%global cryptohashsha1 cryptohash-sha1-0.11.100.1
%global networkinfo network-info-0.2.0.8
%global uuidtypes uuid-types-1.0.3
%global subpkgs %{cryptohashmd5} %{cryptohashsha1} %{networkinfo} %{uuidtypes}
%bcond_with tests
Name: ghc-%{pkg_name}
Version: 1.3.13
# can only be reset when all subpkgs bumped
Release: 3%{?dist}
Release: 4%{?dist}
Summary: For creating, comparing, parsing and printing Universally Unique Identifiers
License: BSD
Url: https://hackage.haskell.org/package/%{pkg_name}
Source0: https://hackage.haskell.org/package/%{pkgver}/%{pkgver}.tar.gz
Source1: https://hackage.haskell.org/package/%{cryptohashmd5}/%{cryptohashmd5}.tar.gz
Source2: https://hackage.haskell.org/package/%{cryptohashsha1}/%{cryptohashsha1}.tar.gz
Source3: https://hackage.haskell.org/package/%{networkinfo}/%{networkinfo}.tar.gz
Source4: https://hackage.haskell.org/package/%{uuidtypes}/%{uuidtypes}.tar.gz
BuildRequires: ghc-Cabal-devel
BuildRequires: ghc-rpm-macros-extra
BuildRequires: ghc-rpm-macros
# Begin cabal-rpm deps:
BuildRequires: ghc-binary-devel
BuildRequires: ghc-bytestring-devel
#BuildRequires: ghc-cryptohash-md5-devel
#BuildRequires: ghc-cryptohash-sha1-devel
BuildRequires: ghc-cryptohash-md5-devel
BuildRequires: ghc-cryptohash-sha1-devel
BuildRequires: ghc-entropy-devel
#BuildRequires: ghc-network-info-devel
BuildRequires: ghc-network-info-devel
BuildRequires: ghc-random-devel
BuildRequires: ghc-text-devel
BuildRequires: ghc-time-devel
#BuildRequires: ghc-uuid-types-devel
BuildRequires: ghc-uuid-types-devel
%if %{with tests}
BuildRequires: ghc-HUnit-devel
BuildRequires: ghc-QuickCheck-devel
@ -47,8 +36,6 @@ BuildRequires: ghc-tasty-hunit-devel
BuildRequires: ghc-tasty-quickcheck-devel
%endif
# End cabal-rpm deps
# uuid-types needs
BuildRequires: ghc-hashable-devel
%description
This library is useful for creating, comparing, parsing and printing
@ -69,33 +56,17 @@ Requires: %{name}%{?_isa} = %{version}-%{release}
This package provides the Haskell %{pkg_name} library development files.
%global main_version %{version}
%if %{defined ghclibdir}
%ghc_lib_subpackage %{cryptohashmd5}
%ghc_lib_subpackage %{cryptohashsha1}
%ghc_lib_subpackage %{networkinfo}
%ghc_lib_subpackage %{uuidtypes}
%endif
%global version %{main_version}
%prep
%setup -q -n %{pkgver} -a1 -a2 -a3 -a4
%setup -q -n %{pkgver}
%build
%ghc_libs_build %{subpkgs}
%ghc_lib_build
%install
%ghc_libs_install %{subpkgs}
%ghc_lib_install
%ghc_fix_rpath %{subpkgs}
%check
%cabal_test
@ -118,6 +89,9 @@ This package provides the Haskell %{pkg_name} library development files.
%changelog
* Mon Oct 23 2017 Jens Petersen <petersen@redhat.com> - 1.3.13-4
- subpackages are now all packaged in Fedora
* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.13-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild