cabal-rpm-1.0.0: add doc and prof subpkgs
This commit is contained in:
parent
658820cff2
commit
a4ce877d52
76
hlint.spec
76
hlint.spec
|
@ -1,4 +1,4 @@
|
|||
# generated by cabal-rpm-0.13
|
||||
# generated by cabal-rpm-1.0.0
|
||||
# https://fedoraproject.org/wiki/Packaging:Haskell
|
||||
|
||||
%global pkg_name hlint
|
||||
|
@ -6,7 +6,7 @@
|
|||
|
||||
Name: %{pkg_name}
|
||||
Version: 2.1.11
|
||||
Release: 2%{?dist}
|
||||
Release: 3%{?dist}
|
||||
Summary: Haskell source code suggestions
|
||||
|
||||
License: BSD
|
||||
|
@ -17,8 +17,13 @@ Source0: https://hackage.haskell.org/package/%{pkgver}/%{pkgver}.tar.gz
|
|||
|
||||
# Begin cabal-rpm deps:
|
||||
BuildRequires: ghc-Cabal-devel
|
||||
%if %{with haddock}
|
||||
BuildRequires: ghc-doc
|
||||
%endif
|
||||
%if %{with ghc_prof}
|
||||
BuildRequires: ghc-prof
|
||||
%endif
|
||||
BuildRequires: ghc-rpm-macros
|
||||
BuildRequires: chrpath
|
||||
BuildRequires: ghc-aeson-devel
|
||||
BuildRequires: ghc-ansi-terminal-devel
|
||||
BuildRequires: ghc-bytestring-devel
|
||||
|
@ -40,14 +45,24 @@ BuildRequires: ghc-uniplate-devel
|
|||
BuildRequires: ghc-unordered-containers-devel
|
||||
BuildRequires: ghc-vector-devel
|
||||
BuildRequires: ghc-yaml-devel
|
||||
Requires: %{name}-common = %{version}-%{release}
|
||||
# End cabal-rpm deps
|
||||
|
||||
%description
|
||||
HLint gives suggestions on how to improve your source code.
|
||||
|
||||
|
||||
%package common
|
||||
Summary: %{name} common files
|
||||
BuildArch: noarch
|
||||
|
||||
%description common
|
||||
This package provides the %{name} common data files.
|
||||
|
||||
|
||||
%package -n ghc-%{name}
|
||||
Summary: Haskell %{name} library
|
||||
Requires: %{name}-common = %{version}-%{release}
|
||||
|
||||
%description -n ghc-%{name}
|
||||
This package provides the Haskell %{name} shared library.
|
||||
|
@ -56,11 +71,8 @@ This package provides the Haskell %{name} shared library.
|
|||
%package -n ghc-%{name}-devel
|
||||
Summary: Haskell %{name} library development files
|
||||
Provides: ghc-%{name}-static = %{version}-%{release}
|
||||
Provides: ghc-%{name}-doc = %{version}-%{release}
|
||||
%if %{defined ghc_version}
|
||||
Requires: ghc-compiler = %{ghc_version}
|
||||
Requires(post): ghc-compiler = %{ghc_version}
|
||||
Requires(postun): ghc-compiler = %{ghc_version}
|
||||
%endif
|
||||
Requires: ghc-%{name}%{?_isa} = %{version}-%{release}
|
||||
|
||||
|
@ -68,7 +80,27 @@ Requires: ghc-%{name}%{?_isa} = %{version}-%{release}
|
|||
This package provides the Haskell %{name} library development files.
|
||||
|
||||
|
||||
%if %{with haddock}
|
||||
%package -n ghc-%{name}-doc
|
||||
Summary: Haskell %{name} library documentation
|
||||
|
||||
%description -n ghc-%{name}-doc
|
||||
This package provides the Haskell %{name} library documentation.
|
||||
%endif
|
||||
|
||||
|
||||
%if %{with ghc_prof}
|
||||
%package -n ghc-%{name}-prof
|
||||
Summary: Haskell %{name} profiling library
|
||||
Requires: ghc-%{name}-devel%{?_isa} = %{version}-%{release}
|
||||
|
||||
%description -n ghc-%{name}-prof
|
||||
This package provides the Haskell %{name} profiling library.
|
||||
%endif
|
||||
|
||||
|
||||
%prep
|
||||
# Begin cabal-rpm setup:
|
||||
%setup -q
|
||||
# End cabal-rpm setup
|
||||
|
||||
|
@ -80,42 +112,50 @@ This package provides the Haskell %{name} library development files.
|
|||
|
||||
|
||||
%install
|
||||
# Begin cabal-rpm install
|
||||
%ghc_lib_install
|
||||
mv %{buildroot}%{_ghcdocdir}{,-common}
|
||||
# End cabal-rpm install
|
||||
|
||||
mkdir -p %{buildroot}%{_mandir}/man1
|
||||
mv %{buildroot}%{_datadir}/%{name}-%{version}/hlint.1 %{buildroot}%{_mandir}/man1
|
||||
|
||||
|
||||
%post -n ghc-%{name}-devel
|
||||
%ghc_pkg_recache
|
||||
|
||||
|
||||
%postun -n ghc-%{name}-devel
|
||||
%ghc_pkg_recache
|
||||
|
||||
|
||||
%files
|
||||
# Begin cabal-rpm files:
|
||||
%license LICENSE
|
||||
%doc CHANGES.txt README.md
|
||||
%{_bindir}/%{name}
|
||||
%{_datadir}/%{pkgver}
|
||||
# End cabal-rpm files
|
||||
%{_mandir}/man1/%{name}*
|
||||
|
||||
|
||||
%files -n ghc-%{name} -f ghc-%{name}.files
|
||||
%files common
|
||||
# Begin cabal-rpm files:
|
||||
%license LICENSE
|
||||
%doc CHANGES.txt README.md
|
||||
%{_datadir}/%{pkgver}
|
||||
# End cabal-rpm files
|
||||
|
||||
|
||||
%files -n ghc-%{name} -f ghc-%{name}.files
|
||||
|
||||
|
||||
%files -n ghc-%{name}-devel -f ghc-%{name}-devel.files
|
||||
|
||||
|
||||
%if %{with haddock}
|
||||
%files -n ghc-%{name}-doc -f ghc-%{name}-doc.files
|
||||
%endif
|
||||
|
||||
|
||||
%if %{with ghc_prof}
|
||||
%files -n ghc-%{name}-prof -f ghc-%{name}-prof.files
|
||||
%endif
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri Aug 02 2019 Jens Petersen <petersen@redhat.com> - 2.1.11-3
|
||||
- add doc and prof subpackages (cabal-rpm-1.0.0)
|
||||
|
||||
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.1.11-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
|
|
Loading…
Reference in New Issue