1 %define pkgname binary-shared
2 Summary: Sharing for the binary package
7 Group: Development/Languages
8 Source0: http://hackage.haskell.org/packages/archive/%{pkgname}/%{version}/%{pkgname}-%{version}.tar.gz
9 # Source0-md5: 6439668d378a4c165d72b1c8c429d22e
10 URL: http://hackage.haskell.org/package/binary-shared/
11 BuildRequires: ghc >= 6.12.3
12 BuildRequires: ghc-prof
13 BuildRequires: rpmbuild(macros) >= 1.608
15 Requires(post,postun): /usr/bin/ghc-pkg
16 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
18 # debuginfo is not useful for ghc
19 %define _enable_debug_packages 0
21 # don't compress haddoc files
22 %define _noautocompressdoc *.haddock
25 Generic solution for ghc-binary package lack of support for
26 sharing of identical elements.
29 Summary: Profiling %{pkgname} library for GHC
30 Summary(pl.UTF-8): Biblioteka profilująca %{pkgname} dla GHC.
31 Group: Development/Libraries
32 Requires: %{name} = %{version}-%{release}
35 Profiling %{pkgname} library for GHC. Should be installed when
36 GHC's profiling subsystem is needed.
38 %description prof -l pl.UTF-8
39 Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
40 kiedy potrzebujemy systemu profilującego z GHC.
43 %setup -q -n %{pkgname}-%{version}
46 runhaskell Setup.lhs configure -v2 --enable-library-profiling \
49 --libexecdir=%{_libexecdir} \
50 --docdir=%{_docdir}/%{name}-%{version}
52 runhaskell Setup.lhs build
53 runhaskell Setup.lhs haddock --executables
56 rm -rf $RPM_BUILD_ROOT
57 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
59 runhaskell Setup.lhs copy --destdir=$RPM_BUILD_ROOT
61 # work around automatic haddock docs installation
62 rm -rf %{name}-%{version}-doc
63 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
65 runhaskell Setup.lhs register \
66 --gen-pkg-config=$RPM_BUILD_ROOT/%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
69 rm -rf $RPM_BUILD_ROOT
78 %defattr(644,root,root,755)
80 %doc %{name}-%{version}-doc/*
81 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
82 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
83 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.o
84 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.a
85 %exclude %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
87 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/PACKAGE
88 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/PACKAGE/*.hi
91 %defattr(644,root,root,755)
92 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
93 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/PACKAGE/*.p_hi