- initial packaging for Fedora automatically generated by cabal2spec-0.24.1

OBS-URL: https://build.opensuse.org/package/show/devel:languages:haskell/ghc-digest?expand=0&rev=2
This commit is contained in:
Herbert Graeber 2012-01-18 23:06:22 +00:00 committed by Git OBS Bridge
parent f33975633c
commit 68b3a66793
6 changed files with 79 additions and 121 deletions

3
_service Normal file
View File

@ -0,0 +1,3 @@
<services>
<service name="download_files"/>
</services>

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:40319762afc05823920126f13cba02b06544ba039e08c3f63db2ed084a9a4edc
size 2519

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:5a0613309463324942d10275e5cfc544dd87cc6d869276b9fe979db48493b396
size 13091

4
ghc-digest.changes Normal file
View File

@ -0,0 +1,4 @@
-------------------------------------------------------------------
Wed Jan 18 20:38:15 UTC 2012 - herbert@graeber-clan.de
- initial packaging for Fedora automatically generated by cabal2spec-0.24.1

View File

@ -1,82 +1,72 @@
%define pkg_name digest # For Haskell Packaging Guidelines see:
%define ghc_version %(ghc --numeric-version) # - https://fedoraproject.org/wiki/Packaging:Haskell
# - https://fedoraproject.org/wiki/PackagingDrafts/Haskell
%define pkg_libdir %{_libdir}/ghc-%{ghc_version}/%{pkg_name}-%{version} # Copyright (c) 2012 Herbert Graeber <herbert@graeber-clan.de>
%define pkg_docdir %{_datadir}/doc/ghc/libraries/%{pkg_name}-%{version} #
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# ghc does not emit debug information # Please submit bugfixes or comments via http://bugs.opensuse.org/
%define debug_package %{nil} #
%global pkg_name digest
# common part of summary for all the subpackages
%global common_summary Haskell %{pkg_name} library
# main description used for all the subpackages
%global common_description A %{pkg_name} library for Haskell.
Name: ghc-%{pkg_name} Name: ghc-%{pkg_name}
Version: 0.0.0.6 Version: 0.0.1.0
Release: 0 Release: 1
Summary: Various cryptographic hashes for bytestrings; CRC32 and Adler32 for now Summary: %{common_summary}
Group: Development/Libraries
License: BSD3 Group: Development/Libraries/Other
URL: http://hackage.haskell.org/cgi-bin/hackage-scripts/package/%{pkg_name} License: BSD3c
Source0: http://hackage.haskell.org/packages/archive/%{pkg_name}/%{version}/%{pkg_name}-%{version}.tar.bz2 # BEGIN cabal2spec
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) URL: http://hackage.haskell.org/package/%{pkg_name}
BuildRequires: ghc, ghc-doc, ghc-prof Source0: http://hackage.haskell.org/packages/archive/%{pkg_name}/%{version}/%{pkg_name}-%{version}.tar.gz
ExclusiveArch: %{ix86} x86_64 %{ghc_arches}
BuildRequires: ghc-Cabal-devel
BuildRequires: ghc-rpm-macros
%if %{undefined without_hscolour}
BuildRequires: hscolour
%endif
BuildRequires: ghc-base-devel
BuildRequires: ghc-bytestring-devel
BuildRequires: zlib-devel BuildRequires: zlib-devel
BuildRequires: licenses # END cabal2spec
# BR any C devel dependency here
# list ghc-*-prof dependencies:
%description %description
This package provides efficient cryptographic hash implementations for strict %{common_description}
and lazy bytestrings. For now, CRC32 and Adler32 are supported; they are
implemented as FFI bindings to efficient code from zlib.
This package provides the Haskell %{pkg_name} library for ghc.
%package devel %package -n ghc-%{pkg_name}-devel
Summary: Haskell %{pkg_name} library Summary: Development files for %{common_summary}
Group: Development/Libraries Group: Development/Libraries/Other
Requires: ghc = %{ghc_version} # BEGIN cabal2spec
Requires(post): ghc = %{ghc_version} %{?ghc_devel_requires}
Requires(preun): ghc = %{ghc_version} Obsoletes: ghc-%{pkg_name}-prof < %{version}-%{release}
Requires: ghc-bytestring-devel Provides: ghc-%{pkg_name}-prof = %{version}-%{release}
# END cabal2spec
# remember to require any C devel dependency here
# Haskell devel dependencies are autogenerated by ghc-deps.sh
Requires: zlib-devel Requires: zlib-devel
Requires: licenses
%description devel %description -n ghc-%{pkg_name}-devel
This package provides efficient cryptographic hash implementations for strict %{common_description}
and lazy bytestrings. For now, CRC32 and Adler32 are supported; they are
implemented as FFI bindings to efficient code from zlib.
This package contains the development files for %{name} This package contains the development files.
built for ghc-%{ghc_version}.
%package doc
Summary: Documentation for %{name}
Group: Development/Libraries
Requires: ghc-doc = %{ghc_version}
Requires(post): ghc-doc = %{ghc_version}
Requires(postun): ghc-doc = %{ghc_version}
Requires: ghc-bytestring-doc
%description doc
This package provides efficient cryptographic hash implementations for strict
and lazy bytestrings. For now, CRC32 and Adler32 are supported; they are
implemented as FFI bindings to efficient code from zlib.
This package contains development documentation files for the %{name} library.
%package prof
Summary: Profiling libraries for %{name}
Group: Development/Libraries
Requires: %{name}-devel = %{version}-%{release}
Requires: ghc-prof = %{ghc_version}
Requires: ghc-bytestring-prof
Requires: zlib-devel
%description prof
This package provides efficient cryptographic hash implementations for strict
and lazy bytestrings. For now, CRC32 and Adler32 are supported; they are
implemented as FFI bindings to efficient code from zlib.
This package contains profiling libraries for %{name}.
%prep %prep
@ -84,64 +74,30 @@ This package contains profiling libraries for %{name}.
%build %build
%cabal_configure --ghc %{!?without_prof:-p} #%%define cabal_configure_options -f "opt1 -opt2 ..."
%cabal build %ghc_lib_build
%cabal haddock
%ghc_gen_scripts
%install %install
%cabal_install %ghc_lib_install
%ghc_install_scripts
%ghc_gen_filelists %{name}
for FILE in LICENSE ; do
MD5SUM=$(md5sum $FILE | sed 's/ .*//')
if test -f /usr/share/doc/licenses/md5/$MD5SUM ; then
ln -sf /usr/share/doc/licenses/md5/$MD5SUM $FILE
fi
done
%post devel %post -n ghc-%{pkg_name}-devel
%ghc_register_pkg %ghc_pkg_recache
%post doc %postun -n ghc-%{pkg_name}-devel
%ghc_reindex_haddock %ghc_pkg_recache
%preun devel %if %{undefined ghc_without_shared}
if [ "$1" -eq 0 ] ; then %files -n ghc-%{pkg_name} -f ghc-%{pkg_name}.files
%ghc_unregister_pkg
fi
%postun doc
if [ "$1" -eq 0 ] ; then
%ghc_reindex_haddock
fi
%files devel -f %{name}-devel.files
%defattr(-,root,root,-) %defattr(-,root,root,-)
%{_docdir}/%{name}-%{version} %endif
%files doc %files -n ghc-%{pkg_name}-devel -f ghc-%{pkg_name}-devel.files
%defattr(-,root,root,-)
%{pkg_docdir}
%files prof -f %{name}-prof.files
%defattr(-,root,root,-) %defattr(-,root,root,-)
%changelog %changelog
* Sun Aug 2 2009 Herbert Graeber <herbert@graeber-clan.de> - 0.0.0.6
- Require zlib-devel
* Sat Aug 1 2009 Herbert Graeber <herbert@graeber-clan.de> - 0.0.0.6
- Require ghc-bytestring instead of ghc-binary
* Fri Jul 31 2009 Herbert Graeber <herbert@graeber-clan.de> - 0.0.0.6
- Initial Package

View File

@ -1,6 +1 @@
addFilter("devel-dependency gmp-devel") addFilter("useless-provides")
addFilter("devel-file-in-non-devel-package")
addFilter("static-library-without-debuginfo")
addFilter("useless-explicit-requires ghc")
addFilter("useless-explicit-requires ghc-doc")
addFilter("devel-dependency ghc-digest-devel")