refresh to cabal-rpm-0.13

This commit is contained in:
Jens Petersen 2019-02-17 22:41:51 +08:00
parent 381aecc283
commit 9e6df6678b
1 changed files with 29 additions and 5 deletions

View File

@ -1,4 +1,4 @@
# generated by cabal-rpm-0.12.5
# generated by cabal-rpm-0.13
# https://fedoraproject.org/wiki/Packaging:Haskell
%global pkg_name Agda
@ -15,11 +15,12 @@
Name: %{pkg_name}
Version: 2.5.3
# can only be reset when all subpkgs bumped
Release: 15%{?dist}
Release: 16%{?dist}
Summary: A dependently typed functional programming language and proof assistant
License: MIT and BSD
Url: https://hackage.haskell.org/package/%{name}
# Begin cabal-rpm sources:
Source0: https://hackage.haskell.org/package/%{pkgver}/%{pkgver}.tar.gz
Source1: https://hackage.haskell.org/package/%{EdisonAPI}/%{EdisonAPI}.tar.gz
Source2: https://hackage.haskell.org/package/%{EdisonCore}/%{EdisonCore}.tar.gz
@ -28,11 +29,12 @@ Source4: https://hackage.haskell.org/package/%{monadplus}/%{monadplus}.ta
Source5: https://hackage.haskell.org/package/%{murmurhash}/%{murmurhash}.tar.gz
Source6: https://hackage.haskell.org/package/%{uriencode}/%{uriencode}.tar.gz
Source7: https://hackage.haskell.org/package/%{pkgver}/%{name}.cabal#/%{pkgver}.cabal
# End cabal-rpm sources
Source10: agda-mode-init.el
# Begin cabal-rpm deps:
BuildRequires: ghc-Cabal-devel
BuildRequires: ghc-rpm-macros-extra
# Begin cabal-rpm deps:
BuildRequires: alex
BuildRequires: chrpath
BuildRequires: cpphs
@ -73,6 +75,7 @@ BuildRequires: ghc-unordered-containers-devel
#BuildRequires: ghc-uri-encode-devel
BuildRequires: ghc-zlib-devel
BuildRequires: happy
Requires: %{name}-common = %{version}-%{release}
# End cabal-rpm deps
BuildRequires: emacs(bin)
# EdisonCore needs
@ -102,8 +105,17 @@ the Swedish logician Per Martin-Löf. It has many similarities with other
proof assistants based on dependent types, such as Coq, Epigram and NuPRL.
%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.
@ -140,8 +152,10 @@ This package provides the Haskell %{name} library development files.
%prep
# Begin cabal-rpm setup:
%setup -q -a1 -a2 -a3 -a4 -a5 -a6
cp -p %{SOURCE7} %{name}.cabal
cp -bp %{SOURCE7} %{name}.cabal
# End cabal-rpm setup
# tweak the Agda version in the emacs mode
if ! grep -q \"%{version}\" src/data/emacs-mode/agda2-mode.el; then
@ -163,8 +177,10 @@ for i in *.el; do
done
cd -
# Begin cabal-rpm build:
%ghc_libs_build %{subpkgs}
%ghc_lib_build
# End cabal-rpm build
# el6 macro does not add "." to load-path
%if %{defined el6}
@ -179,10 +195,11 @@ cd -
%install
# Begin cabal-rpm install
%ghc_libs_install %{subpkgs}
%ghc_lib_install
%ghc_fix_rpath %{pkgver}
# End cabal-rpm install
for i in $(find %{buildroot}%{_datadir}/%{pkgver} -name "*.agda"); do
Agda_datadir=%{buildroot}%{_datadir}/%{pkgver} LD_LIBRARY_PATH=%{buildroot}%{_ghcdynlibdir} %{buildroot}%{_bindir}/agda $i
@ -211,6 +228,8 @@ mv %{buildroot}%{_ghclicensedir}/{,ghc-}%{name}
%files
# Begin cabal-rpm files:
%license LICENSE
%doc README.md
%dir %{_emacs_sitelispdir}/agda
%{_emacs_sitelispdir}/agda/*.el
@ -219,7 +238,9 @@ mv %{buildroot}%{_ghclicensedir}/{,ghc-}%{name}
%files -n ghc-%{name} -f ghc-%{name}.files
# Begin cabal-rpm files:
%license LICENSE
# End cabal-rpm files
%{_bindir}/agda
%{_datadir}/%{pkgver}
@ -229,6 +250,9 @@ mv %{buildroot}%{_ghclicensedir}/{,ghc-}%{name}
%changelog
* Sun Feb 17 2019 Jens Petersen <petersen@redhat.com> - 2.5.3-16
- refresh to cabal-rpm-0.13
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.5.3-15
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild