# "fix" underlinking: %define _disable_ld_no_undefined 1 %global srcname camlbz2 Name: ocaml-camlbz2 Version: 0.7.0 Release: %mkrel 3 Summary: OCaml bindings for the libbz2 (AKA, bzip2) (de)compression library License: LGPLv2 with linking exception Group: Development/OCaml URL: https://gitlab.com/irill/camlbz2 Source0: %{url}/-/archive/%{version}/%{srcname}-%{version}.tar.gz # Generate useful debuginfo Patch0: %{name}-debuginfo.patch # Use Stdlib instead of the deprecated Pervasives Patch1: %{name}-pervasives.patch # Make the C code const-correct # https://gitlab.com/irill/camlbz2/-/merge_requests/1 Patch2: %{name}-const.patch # Unbundle the OCaml io.h header file Patch3: %{name}-io-h.patch BuildRequires: automake BuildRequires: make BuildRequires: ocaml BuildRequires: ocaml-findlib BuildRequires: ocaml-ocamldoc BuildRequires: pkgconfig(bzip2) %description CamlBZ2 provides OCaml bindings for libbz2 (AKA bzip2), a popular compression library which typically compresses better (i.e., smaller resulting files) than gzip. Using CamlBZ2 you can read and write compressed "files", where files can be anything offering an in_channel/out_channel abstraction (files, sockets, ...). Also, with CamlBZ2 you can compress and decompress strings in memory using the bzip2 compression algorithm. %package devel Summary: Development files for %{name} Group: Development/OCaml Requires: %{name} = %{version}-%{release} Requires: bzip2-devel %description devel The %{name}-devel package contains libraries and signature files for developing applications that use %{name}. %prep %autosetup -n %{srcname}-%{version} -p1 # Generate the configure script autoreconf -fi -I . # Make sure we don't use the bundled copy of io.h rm io.h %build %configure # FIXME: parallel builds often fail due to missing dependencies make make doc %install export DESTDIR=%{buildroot} export OCAMLFIND_DESTDIR=%{buildroot}/%{_libdir}/ocaml export DLLDIR=$OCAMLFIND_DESTDIR/stublibs mkdir -p $OCAMLFIND_DESTDIR/bz2 mkdir -p $DLLDIR make install %files %doc BUGS COPYING ChangeLog README ROADMAP %license COPYING LICENSE %dir %{_libdir}/ocaml/bz2 %{_libdir}/ocaml/bz2/META %{_libdir}/ocaml/bz2/*.cma %{_libdir}/ocaml/bz2/*.cmi %{_libdir}/ocaml/stublibs/*.so* %files devel %doc doc %{_libdir}/ocaml/bz2/*.a %{_libdir}/ocaml/bz2/*.cmxa %{_libdir}/ocaml/bz2/*.cmx %{_libdir}/ocaml/bz2/*.mli %changelog * Wed May 18 2022 pterjan <pterjan> 0.7.0-3.mga9 + Revision: 1858753 - Rebuild for OCaml 4.14 * Tue Mar 29 2022 umeabot <umeabot> 0.7.0-2.mga9 + Revision: 1832444 - Mageia 9 Mass Rebuild * Tue Oct 12 2021 tv <tv> 0.7.0-1.mga9 + Revision: 1750691 - 0.7.0 * Tue Oct 12 2021 tv <tv> 0.6.0-24.mga9 + Revision: 1750690 - Rebuild for ocaml 4.13.1 * Wed Mar 03 2021 tv <tv> 0.6.0-23.mga9 + Revision: 1696535 - rebuild for ocaml-4.2-12 * Sun Jan 10 2021 pterjan <pterjan> 0.6.0-22.mga8 + Revision: 1670435 - Rebuild to generate ocamlx provides * Fri Feb 28 2020 umeabot <umeabot> 0.6.0-21.mga8 + Revision: 1551132 - Rebuild for ocaml 4.10.0 final * Wed Feb 19 2020 umeabot <umeabot> 0.6.0-20.mga8 + Revision: 1543243 - Mageia 8 Mass Rebuild * Sun Jan 19 2020 tv <tv> 0.6.0-19.mga8 + Revision: 1481533 - rebuild for ocaml-4.10 + wally <wally> - replace deprecated %%configure2_5x * Tue Oct 23 2018 tv <tv> 0.6.0-18.mga7 + Revision: 1324028 - rebuild with ocaml-4.07.1 * Mon Oct 22 2018 pterjan <pterjan> 0.6.0-17.mga7 + Revision: 1323725 - Rebuild for ocaml 4.07 * Sun Sep 23 2018 umeabot <umeabot> 0.6.0-16.mga7 + Revision: 1299844 - Mageia 7 Mass Rebuild * Sat Nov 25 2017 tv <tv> 0.6.0-15.mga7 + Revision: 1179136 - rebuild for new ocaml * Thu Oct 05 2017 daviddavid <daviddavid> 0.6.0-14.mga7 + Revision: 1169179 - use %%configure2_5x macro thus fixing empty debugsourcefiles.list * Mon Sep 26 2016 pterjan <pterjan> 0.6.0-13.mga6 + Revision: 1056266 - Rebuild for fix in ocaml * Fri Jan 29 2016 pterjan <pterjan> 0.6.0-12.mga6 + Revision: 929044 - Rebuild for new ocaml * Wed Oct 15 2014 umeabot <umeabot> 0.6.0-11.mga5 + Revision: 742660 - Second Mageia 5 Mass Rebuild * Tue Sep 16 2014 umeabot <umeabot> 0.6.0-10.mga5 + Revision: 682999 - Mageia 5 Mass Rebuild * Sat Oct 19 2013 umeabot <umeabot> 0.6.0-9.mga4 + Revision: 536414 - Mageia 4 Mass Rebuild * Mon Sep 23 2013 blue_prawn <blue_prawn> 0.6.0-8.mga4 + Revision: 484218 - rebuild for ocaml-4.01.0 * Sat Jan 12 2013 umeabot <umeabot> 0.6.0-7.mga3 + Revision: 361196 - Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild * Mon Oct 01 2012 blue_prawn <blue_prawn> 0.6.0-6.mga3 + Revision: 301640 - new rpm group for ocaml - new rpm group for ocaml * Wed Nov 23 2011 malo <malo> 0.6.0-4.mga2 + Revision: 171412 - fixing License field. - missing Requires bzip2-devel - missing explicit BuildRequires * Sun Oct 02 2011 fwang <fwang> 0.6.0-3.mga2 + Revision: 150880 - rebuild for new ocaml * Tue Apr 12 2011 ennael <ennael> 0.6.0-2.mga1 + Revision: 83662 - clean spec file - imported package ocaml-camlbz2