[packages/ghc-vector] - unified, added -prof package, release 1

qboosh qboosh at pld-linux.org
Wed Dec 11 18:17:01 CET 2013


commit 96933da161a7303ca72bd2e716f4c3196c9aa94d
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Wed Dec 11 18:18:33 2013 +0100

    - unified, added -prof package, release 1

 ghc-vector.spec | 98 ++++++++++++++++++++++++++++++++++++++++++++++++++-------
 1 file changed, 86 insertions(+), 12 deletions(-)
---
diff --git a/ghc-vector.spec b/ghc-vector.spec
index 7d758fd..a133869 100644
--- a/ghc-vector.spec
+++ b/ghc-vector.spec
@@ -1,16 +1,27 @@
+#
+# Conditional build:
+%bcond_without	prof	# profiling library
+#
 %define		pkgname	vector
-Summary:	A Haskell binding to the vector graphics library
+Summary:	Efficient Arrays
+Summary(pl.UTF-8):	Wydajne tablice
 Name:		ghc-%{pkgname}
 Version:	0.10.0.1
-Release:	0.1
+Release:	1
 License:	BSD
 Group:		Development/Languages
-Source0:	http://hackage.haskell.org/packages/archive/%{pkgname}/%{version}/%{pkgname}-%{version}.tar.gz
+#Source0Download: http://hackage.haskell.org/package/vector
+Source0:	http://hackage.haskell.org/package/%{pkgname}-%{version}/%{pkgname}-%{version}.tar.gz
 # Source0-md5:	a0d48ebfe68c8b90cb1d09589d86a79c
-URL:		http://hackage.haskell.org/package/vector/
+URL:		http://hackage.haskell.org/package/vector
 BuildRequires:	ghc >= 6.12.3
 BuildRequires:	ghc-primitive < 0.6
 BuildRequires:	ghc-primitive >= 0.5.0.1
+%if %{with prof}
+BuildRequires:	ghc-prof >= 6.12.3
+BuildRequires:	ghc-primitive-prof < 0.6
+BuildRequires:	ghc-primitive-prof >= 0.5.0.1
+%endif
 BuildRequires:	rpmbuild(macros) >= 1.608
 %requires_eq	ghc
 BuildRequires:	ghc-primitive < 0.6
@@ -20,25 +31,51 @@ BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 # debuginfo is not useful for ghc
 %define		_enable_debug_packages	0
 
+# don't compress haddock files
+%define		_noautocompressdoc	*.haddock
+
 %description
-A Haskell binding to the vector graphics library.
+An efficient implementation of Int-indexed arrays (both mutable and
+immutable), with a powerful loop optimisation framework.
+
+%description -l pl.UTF-8
+Wydajna implementacja tablic indeksowanych typem Int (zarówno
+zmiennych, jak i niezmiennych) z potężnym szkieletem do optymalizacji
+pętli.
+
+%package prof
+Summary:	Profiling %{pkgname} library for GHC
+Summary(pl.UTF-8):	Biblioteka profilująca %{pkgname} dla GHC
+Group:		Development/Libraries
+Requires:	%{name} = %{version}-%{release}
+Requires:	ghc-primitive-prof < 0.6
+Requires:	ghc-primitive-prof >= 0.5.0.1
+
+%description prof
+Profiling %{pkgname} library for GHC. Should be installed when
+GHC's profiling subsystem is needed.
+
+%description prof -l pl.UTF-8
+Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
+kiedy potrzebujemy systemu profilującego z GHC.
 
 %package doc
-Summary:	HTML documentation for %{pkgname}
-Summary(pl.UTF-8):	Dokumentacja w formacie HTML dla %{pkgname}
+Summary:	HTML documentation for ghc %{pkgname} package
+Summary(pl.UTF-8):	Dokumentacja w formacie HTML dla pakietu ghc %{pkgname}
 Group:		Documentation
 
 %description doc
-HTML documentation for %{pkgname}.
+HTML documentation for ghc %{pkgname} package.
 
 %description doc -l pl.UTF-8
-Dokumentacja w formacie HTML dla %{pkgname}.
+Dokumentacja w formacie HTML dla pakietu ghc %{pkgname}.
 
 %prep
 %setup -q -n %{pkgname}-%{version}
 
 %build
 runhaskell Setup.hs configure -v2 \
+	%{?with_prof:--enable-library-profiling} \
 	--prefix=%{_prefix} \
 	--libdir=%{_libdir} \
 	--libexecdir=%{_libexecdir} \
@@ -54,12 +91,12 @@ install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
 
 # work around automatic haddock docs installation
-rm -rf %{name}-%{version}-doc
+%{__rm} -rf %{name}-%{version}-doc
 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/html %{name}-%{version}-doc
 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
 
 runhaskell Setup.hs register \
-	--gen-pkg-config=$RPM_BUILD_ROOT/%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
+	--gen-pkg-config=$RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -72,8 +109,45 @@ rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
+%doc LICENSE
 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
-%{_libdir}/%{ghcdir}/%{pkgname}-%{version}
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/HSvector-%{version}.o
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSvector-%{version}.a
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector.hi
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/*.hi
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Fusion
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Fusion/*.hi
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Fusion/Stream
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Fusion/Stream/*.hi
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Generic
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Generic/*.hi
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Internal
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Internal/*.hi
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Primitive
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Primitive/*.hi
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Storable
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Storable/*.hi
+%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Unboxed
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Unboxed/*.hi
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/include
+
+%if %{with prof}
+%files prof
+%defattr(644,root,root,755)
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSvector-%{version}_p.a
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector.p_hi
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/*.p_hi
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Fusion/*.p_hi
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Fusion/Stream/*.p_hi
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Generic/*.p_hi
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Internal/*.p_hi
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Primitive/*.p_hi
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Storable/*.p_hi
+%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Vector/Unboxed/*.p_hi
+%endif
 
 %files doc
 %defattr(644,root,root,755)
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/ghc-vector.git/commitdiff/96933da161a7303ca72bd2e716f4c3196c9aa94d



More information about the pld-cvs-commit mailing list