3 %bcond_without prof # profiling library
5 %define pkgname uuid-types
6 Summary: Type definitions for Universally Unique Identifiers
11 Group: Development/Languages
12 #Source0Download: http://hackage.haskell.org/package/uuid-types
13 Source0: http://hackage.haskell.org/package/%{pkgname}-%{version}/%{pkgname}-%{version}.tar.gz
14 # Source0-md5: 8eb681871f48a2f7fd739fad9e91c341
15 Patch0: hashable-1.3.patch
16 URL: http://hackage.haskell.org/package/uuid-types
17 BuildRequires: ghc >= 6.12.3
18 BuildRequires: ghc-hashable
19 BuildRequires: ghc-random
21 BuildRequires: ghc-prof
22 BuildRequires: ghc-hashable-prof
23 BuildRequires: ghc-random-prof
25 BuildRequires: rpmbuild(macros) >= 1.608
27 Requires(post,postun): /usr/bin/ghc-pkg
28 Requires: ghc-hashable
30 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32 # debuginfo is not useful for ghc
33 %define _enable_debug_packages 0
35 # don't compress haddock files
36 %define _noautocompressdoc *.haddock
39 This library contains type definitions for Universally Unique
40 Identifiers and basic conversion functions.
41 See http://en.wikipedia.org/wiki/UUID for the general idea.
44 Summary: Profiling %{pkgname} library for GHC
45 Summary(pl.UTF-8): Biblioteka profilująca %{pkgname} dla GHC
46 Group: Development/Libraries
47 Requires: %{name} = %{version}-%{release}
48 Requires: ghc-hashable-prof
49 Requires: ghc-random-prof
52 Profiling %{pkgname} library for GHC. Should be installed when
53 GHC's profiling subsystem is needed.
55 %description prof -l pl.UTF-8
56 Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
57 kiedy potrzebujemy systemu profilującego z GHC.
60 %setup -q -n %{pkgname}-%{version}
64 runhaskell Setup.hs configure -v2 \
65 %{?with_prof:--enable-library-profiling} \
68 --libexecdir=%{_libexecdir} \
69 --docdir=%{_docdir}/%{name}-%{version}
71 runhaskell Setup.hs build
72 runhaskell Setup.hs haddock --executables
75 rm -rf $RPM_BUILD_ROOT
76 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
78 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
80 # work around automatic haddock docs installation
81 %{__rm} -rf %{name}-%{version}-doc
82 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
83 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
85 runhaskell Setup.hs register \
86 --gen-pkg-config=$RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
89 rm -rf $RPM_BUILD_ROOT
98 %defattr(644,root,root,755)
99 %doc CHANGES %{name}-%{version}-doc/*
100 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
101 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
102 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.so
103 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.a
104 %exclude %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
106 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data
107 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID
108 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/*.hi
109 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/*.dyn_hi
110 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/Types
111 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/Types/*.hi
112 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/Types/*.dyn_hi
113 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/Types/Internal
114 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/Types/Internal/*.hi
115 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/Types/Internal/*.dyn_hi
119 %defattr(644,root,root,755)
120 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
121 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/*.p_hi
122 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/Types/*.p_hi
123 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/UUID/Types/Internal/*.p_hi