Blob Blame History Raw
# ghc does not emit debug information
%define debug_package %{nil}

Name:		cabal-install
Version:	0.6.0
Release:	3%{?dist}
Summary:	Haskell package tool

Group:		Development/Tools
License:	BSD
URL:		http://hackage.haskell.org/cgi-bin/hackage-scripts/package/%{name}
Source0:	http://hackage.haskell.org/archive/hackage-scripts/package/%{name}-%{version}.tar.gz
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

# ghc has only been bootstrapped on the following archs:
ExclusiveArch:	i386 x86_64 ppc

BuildRequires:	ghc, ghc-zlib-devel, ghc-HTTP-devel
Requires:	ghc

%description
The 'cabal' command-line program simplifies the process of managing Haskell
packages by automating fetching, configuration, compilation and
installation of Haskell libraries and programs from Hackage.


%prep
%setup -q


%build
%cabal_configure
%cabal build


%install
rm -rf $RPM_BUILD_ROOT
%cabal_install

mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d
cp -p bash-completion/cabal $RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d

rm ${RPM_BUILD_ROOT}/%{_docdir}/%{name}-%{version}/LICENSE


%clean
rm -rf $RPM_BUILD_ROOT


%files
%defattr(-,root,root,-)
%doc LICENSE README
%{_bindir}/cabal
%{_sysconfdir}/bash_completion.d


%changelog
* Mon Feb  9 2009 Jens Petersen <petersen@redhat.com> - 0.6.0-3
- fix source url

* Wed Jan  7 2009 Jens Petersen <petersen@redhat.com> - 0.6.0-2
- add bash completion file
- update cabal build macro

* Tue Nov 11 2008 Jens Petersen <petersen@redhat.com> - 0.6.0-1
- initial package for Fedora