Name: ocaml-sedlex Version: 3.0 Release: %mkrel 4 Summary: Unicode-friendly lexer generator Group: Development/OCaml License: MIT URL: https://github.com/ocaml-community/sedlex Source0: https://github.com/ocaml-community/sedlex/archive/v%{version}/%{name}-%{version}.tar.gz # Use local Unicode files instead of attempting to download them Patch0: %{name}-no-curl.patch # Do not depend on the uchar compatibility package; our OCaml is new enough Patch1: %{name}-uchar.patch BuildRequires: ocaml >= 4.08.0 BuildRequires: ocaml-dune BuildRequires: ocaml-ppxlib-devel >= 0.26.0 BuildRequires: ocaml-gen-devel BuildRequires: unicode-ucd %description A lexer generator for OCaml, similar to ocamllex, but supporting Unicode. Contrary to ocamllex, lexer specifications for sedlex are embedded in regular OCaml source files. %package devel Summary: Development files for %{name} Group: Development/OCaml Requires: %{name}%{?_isa} = %{version}-%{release} Requires: ocaml-ppxlib-devel%{?_isa} Requires: ocaml-gen-devel%{?_isa} %description devel The %{name}-devel package contains libraries and signature files for developing applications that use %{name}. %prep %setup -q -n sedlex-%{version} %autopatch -p1 if false; then # Upstream's regression test is written for Unicode 6.3.0 through 13.0.0. Our # Unicode files are from a more recent version of the standard. The test has a # good chance of succeeding anyway, so we cross our fingers and give it a try. # If the regression test fails, we'll have to try another approach. univer=$(sed -n 's/.*PropList-\([.[:digit:]]*\)\.txt/\1/p' %{_datadir}/unicode/ucd/PropList.txt) sed -i "s/13\\.0\\.0/$univer/" examples/regressions.ml fi %build dune build %{?_smp_mflags} -p sedlex --verbose %install dune install --destdir="$RPM_BUILD_ROOT" --verbose # These will be installed using doc and license directives. rm -r $RPM_BUILD_ROOT%{_prefix}/doc/sedlex/{CHANGES,README.md,LICENSE} %check # Disabled this because it prints: # (cd _build/default/examples && ./regressions.exe) # Fatal error: exception (Failure "Test written for versions: 12.1.0 => 14.0.0\n") # I think the version number refers to the version of Unicode (not OCaml). dune runtest ||: %files %doc README.md CHANGES %license LICENSE %dir %{_libdir}/ocaml/sedlex %dir %{_libdir}/ocaml/sedlex/ppx/ %{_libdir}/ocaml/sedlex/META %{_libdir}/ocaml/sedlex/*.cma %{_libdir}/ocaml/sedlex/*.cmi %{_libdir}/ocaml/sedlex/*.cmxs %{_libdir}/ocaml/sedlex/ppx/*.cma %{_libdir}/ocaml/sedlex/ppx/*.cmi %{_libdir}/ocaml/sedlex/ppx/*.cmxs %{_libdir}/ocaml/sedlex/ppx/*.exe %files devel %doc README.md CHANGES %license LICENSE %{_libdir}/ocaml/sedlex/opam %{_libdir}/ocaml/sedlex/*dune* %{_libdir}/ocaml/sedlex/*.a %{_libdir}/ocaml/sedlex/*.cmti %{_libdir}/ocaml/sedlex/*.cmt %{_libdir}/ocaml/sedlex/*.cmxa %{_libdir}/ocaml/sedlex/*.cmx %{_libdir}/ocaml/sedlex/*.ml %{_libdir}/ocaml/sedlex/*.mli %{_libdir}/ocaml/sedlex/ppx/*.a %{_libdir}/ocaml/sedlex/ppx/*.cmti %{_libdir}/ocaml/sedlex/ppx/*.cmt %{_libdir}/ocaml/sedlex/ppx/*.cmxa %{_libdir}/ocaml/sedlex/ppx/*.cmx %{_libdir}/ocaml/sedlex/ppx/*.ml %{_libdir}/ocaml/sedlex/ppx/*.mli %changelog * Sun Jan 01 2023 daviddavid <daviddavid> 3.0-4.mga9 + Revision: 1928690 - rebuild for new ocaml-gen 1.0 - own properly lib dir * Sun Dec 11 2022 pterjan <pterjan> 3.0-3.mga9 + Revision: 1920630 - Rebuild for new ppxlib * Sat Oct 15 2022 neoclust <neoclust> 3.0-2.mga9 + Revision: 1897017 - Rebuild against new ocaml-base * Sun Sep 11 2022 neoclust <neoclust> 3.0-1.mga9 + Revision: 1886965 - New version 3.0 * Fri May 20 2022 pterjan <pterjan> 2.6-2.mga9 + Revision: 1859451 - Rebuild for OCaml 4.14 * Wed May 18 2022 pterjan <pterjan> 2.6-1.mga9 + Revision: 1858610 - Update to 2.6 * Fri Oct 15 2021 tv <tv> 2.4-2.mga9 + Revision: 1751532 - Version 2.4 - Add -uchar patch to avoid the need for a compatibility package - Run testsuite * Thu Mar 25 2021 tv <tv> 2.3-2.mga9 + Revision: 1709724 - Rebuild for ocaml-4.12 + daviddavid <daviddavid> - new version: 2.3 - rebuild for ocaml 4.12.0 * Sun Jan 10 2021 pterjan <pterjan> 2.1-4.mga8 + Revision: 1670791 - Rebuild to generate ocamlx provides * Fri Feb 28 2020 umeabot <umeabot> 2.1-3.mga8 + Revision: 1551747 - Rebuild for ocaml 4.10.0 final * Thu Feb 20 2020 umeabot <umeabot> 2.1-2.mga8 + Revision: 1545731 - Mageia 8 Mass Rebuild * Wed Jan 29 2020 tv <tv> 2.1-1.mga8 + Revision: 1485119 - new release + rebuild for ocaml-4.10 * Thu Oct 25 2018 pterjan <pterjan> 1.99.4-5.mga7 + Revision: 1325266 - Fix build with ppx_tools_versioned 5.2.1 + daviddavid <daviddavid> - rebuild for new ocaml 4.07.1 * Thu Aug 30 2018 daviddavid <daviddavid> 1.99.4-4.mga7 + Revision: 1255688 - rebuild for new ocaml-result 1.3 * Sat Jul 21 2018 daviddavid <daviddavid> 1.99.4-2.mga7 + Revision: 1244715 - rebuild against current ocaml stack * Sat Mar 31 2018 daviddavid <daviddavid> 1.99.4-1.mga7 + Revision: 1213708 - initial package ocaml-sedlex