Sophie

Sophie

distrib > Mageia > 3 > i586 > media > core-release-src > by-pkgid > 732691c4d0f08cd3fc5a44a52c6e94ae > files > 3

ocaml-sha-1.8-2.mga3.src.rpm

Name:           ocaml-sha
Version:        1.8
Release:        %mkrel 2
Summary:        SHA Cryptographic Hash Functions for OCaml
License:        LGPL v3.0
Group:          Development/OCaml
URL:            https://github.com/vincenthz/ocaml-sha
Source0:        ocaml-sha-%{version}.tar.gz 
# wget https://github.com/vincenthz/ocaml-sha/archive/v%{version}.tar.gz
# the command line utilities use argv.(0) (cf mlcmd_renamed)
Patch0:         ocaml-sha-1.7_sumrenamed.patch
BuildRequires:  ocaml-findlib

%description
SHA is a cryptographic hash function.
This provide an interface for OCaml program to use
SHA1, SHA256 and SHA512 functions.

SHA1 implements the second implementation that produce
a 160 bit digest from its input.
SHA256 implements newer version that produce 256 bits digest.
SHA512 produces 512 bits digest.

%package        devel
Summary:        Development files for %{name}
Group:          Development/OCaml
Requires:       %{name} = %{version}-%{release}

%description    devel
The %{name}-devel package contains libraries and signature files for
developing applications that use %{name}.

%prep
%setup -q
%patch0 -p1

%build
make       # the lib
make bins  # the progs
make doc

%install
rm -rf %{buildroot}
export DESTDIR=%{buildroot}
export OCAMLFIND_DESTDIR=%{buildroot}/%{_libdir}/ocaml
export DLLDIR=$OCAMLFIND_DESTDIR/stublibs
mkdir -p $OCAMLFIND_DESTDIR/stublibs
mkdir -p $OCAMLFIND_DESTDIR/sha
ocamlfind install sha META ./*.{mli,cmi,cma,a,cmo,cmx,cmxa,so}
install -d -m 0755 %{buildroot}%{_bindir}
for p in sha*sum ; do mv $p ml$p ; done
# mlcmd_renamed: rename shaXsum to mlshaXsum (conflict with coreutils)
install -m 0755 mlsha*sum %{buildroot}%{_bindir}/
mv sha.test.ml sha_test.ml

%files
%doc README
%dir %{_libdir}/ocaml/sha
%{_libdir}/ocaml/sha/META
%{_libdir}/ocaml/sha/*.cma
%{_libdir}/ocaml/sha/*.cmi
%{_libdir}/ocaml/sha/*.cmo
%{_libdir}/ocaml/stublibs/*.so*
%{_bindir}/mlsha1sum
%{_bindir}/mlsha256sum
%{_bindir}/mlsha512sum

%files devel
%doc sha_test.ml
%doc html
%{_libdir}/ocaml/sha/*.a
%{_libdir}/ocaml/sha/*.cmxa
%{_libdir}/ocaml/sha/*.cmx
%{_libdir}/ocaml/sha/*.ml*


%changelog

* Sun Jan 13 2013 umeabot <umeabot> 1.8-2.mga3
+ Revision: 361623
- Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild

* Tue Nov 20 2012 blue_prawn <blue_prawn> 1.8-1.mga3
+ Revision: 319805
- updated to last version 1.8

* Mon Oct 01 2012 blue_prawn <blue_prawn> 1.7-3.mga3
+ Revision: 301110
- rebuild for ocaml-4.00.0

* Sat Sep 29 2012 blue_prawn <blue_prawn> 1.7-2.mga3
+ Revision: 300555
- new rpm group for ocaml
- new homepage url

* Sat Jan 07 2012 blue_prawn <blue_prawn> 1.7-1.mga2
+ Revision: 192880
- imported package ocaml-sha