cabal2spec-2.4: test/golden-test-cases/mersenne-random.spec.golden
#
# spec file for package mersenne-random
#
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%global pkg_name mersenne-random
Name: %{pkg_name}
Version: 1.0.0.1
Release: 0
Summary: Generate high quality pseudorandom numbers using a SIMD Fast Mersenne Twister
License: BSD-3-Clause
URL: https://hackage.haskell.org/package/%{name}
Source0: https://hackage.haskell.org/package/%{name}-%{version}/%{name}-%{version}.tar.gz
BuildRequires: ghc-Cabal-devel
BuildRequires: ghc-old-time-devel
BuildRequires: ghc-rpm-macros
%description
The Mersenne twister is a pseudorandom number generator developed by Makoto
Matsumoto and Takuji Nishimura that is based on a matrix linear recurrence over
a finite binary field. It provides for fast generation of very high quality
pseudorandom numbers
This library uses SFMT, the SIMD-oriented Fast Mersenne Twister, a variant of
Mersenne Twister that is much faster than the original. It is designed to be
fast when it runs on 128-bit SIMD. It can be compiled with either SSE2 and
PowerPC AltiVec support, to take advantage of these instructions.
> cabal install -fuse_sse2
On an x86 system, for performance win.
By default the period of the function is 2^19937-1, however, you can compile in
other defaults. Note that this algorithm on its own is not cryptographically
secure.
For more information about the algorithm and implementation, see the SFMT
homepage,
<http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/emt.html>
and, Mutsuo Saito and Makoto Matsumoto, /SIMD-oriented Fast Mersenne Twister: a
128-bit Pseudorandom Number Generator/, in the Proceedings of MCQMC2006, here:
<http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/ARTICLES/sfmt.pdf> .
%package -n ghc-%{name}
Summary: Haskell %{name} library
%description -n ghc-%{name}
This package provides the Haskell %{name} shared library.
%package -n ghc-%{name}-devel
Summary: Haskell %{name} library development files
Requires: ghc-%{name} = %{version}-%{release}
Requires: ghc-compiler = %{ghc_version}
Requires(post): ghc-compiler = %{ghc_version}
Requires(postun): ghc-compiler = %{ghc_version}
%description -n ghc-%{name}-devel
This package provides the Haskell %{name} library development files.
%prep
%setup -q
%build
%ghc_lib_build
%install
%ghc_lib_install
%post -n ghc-%{name}-devel
%ghc_pkg_recache
%postun -n ghc-%{name}-devel
%ghc_pkg_recache
%files
%license LICENSE
%files -n ghc-%{name} -f ghc-%{name}.files
%license LICENSE
%files -n ghc-%{name}-devel -f ghc-%{name}-devel.files
%changelog