Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ocaml-tyxml: update to 4.6.0 #11682

Draft
wants to merge 2 commits into
base: 3.0-dev
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions SPECS-EXTENDED/ocaml-tyxml/ocaml-tyxml-seq.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
--- tyxml-4.6.0/dune-project.orig 2023-09-27 03:44:48.000000000 -0600
+++ tyxml-4.6.0/dune-project 2023-10-03 13:28:22.210416152 -0600
@@ -81,6 +81,5 @@
(alcotest :with-test)
(re
(>= 1.5.0))
- seq
(uutf
(>= 1.0.0))))
--- tyxml-4.6.0/lib/dune.orig 2023-09-27 03:44:48.000000000 -0600
+++ tyxml-4.6.0/lib/dune 2023-10-03 13:28:22.210416152 -0600
@@ -5,7 +5,7 @@
(modules_without_implementation
Xml_sigs Html_sigs Svg_sigs Html_types Svg_types)
(synopsis "Statically correct HTML and SVG documents (Functor version)")
- (libraries uutf re seq)
+ (libraries uutf re)
(flags (:standard
-safe-string))
)
--- tyxml-4.6.0/tyxml.opam.orig 2023-09-27 03:44:48.000000000 -0600
+++ tyxml-4.6.0/tyxml.opam 2023-10-03 13:28:22.211416134 -0600
@@ -15,7 +15,6 @@ depends: [
"ocaml" {>= "4.04"}
"alcotest" {with-test}
"re" {>= "1.5.0"}
- "seq"
"uutf" {>= "1.0.0"}
"odoc" {with-doc}
]
2 changes: 1 addition & 1 deletion SPECS-EXTENDED/ocaml-tyxml/ocaml-tyxml.signatures.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"Signatures": {
"tyxml-4.5.0.tbz": "c69accef5df4dd89d38f6aa0baad01e8fda4e9e98bb7dad61bec1452c5716068"
"tyxml-4.6.0.tbz": "bfeb673c6b4e120a4eca4c48448add47dc3f8d02c2b40f63ffdccc4e91c902dd"
}
}
173 changes: 39 additions & 134 deletions SPECS-EXTENDED/ocaml-tyxml/ocaml-tyxml.spec
Original file line number Diff line number Diff line change
@@ -1,39 +1,30 @@
Vendor: Microsoft Corporation
Distribution: Azure Linux
%ifnarch %{ocaml_native_compiler}
%global debug_package %{nil}
%endif
# OCaml packages not built on i686 since OCaml 5 / Fedora 39.
ExcludeArch: %{ix86}

%global srcname tyxml
%global giturl https://github.com/ocsigen/tyxml

# This package is needed to build ocaml-odoc, but ocaml-odoc is needed to build
# documentation for this package. Skip building documentation for now until we
# develop a strategy for handling dependency loops.

Name: ocaml-%{srcname}
Version: 4.5.0
Release: 2%{?dist}
Name: ocaml-tyxml
Version: 4.6.0
Release: 13%{?dist}
Summary: Build valid HTML and SVG documents

License: LGPLv2 with exceptions
License: LGPL-2.1-only WITH OCaml-LGPL-linking-exception
URL: https://ocsigen.org/tyxml/
Source0: https://github.com/ocsigen/tyxml/releases/download/%{version}/%{srcname}-%{version}.tbz
VCS: git:%{giturl}.git
Source: %{giturl}/releases/download/%{version}/tyxml-%{version}.tbz
# Fedora's OCaml is new enough that we do not need the seq shim
Patch: %{name}-seq.patch

BuildRequires: ocaml >= 4.04
BuildRequires: ocaml-alcotest-devel
BuildRequires: ocaml-astring-devel
BuildRequires: ocaml-dune >= 2.0
BuildRequires: ocaml-dune >= 2.7
BuildRequires: ocaml-markup-devel >= 0.7.2
BuildRequires: ocaml-ppxlib-devel
BuildRequires: ocaml-ppxlib-devel >= 0.18
BuildRequires: ocaml-re-devel >= 1.5.0
BuildRequires: ocaml-seq-devel
BuildRequires: ocaml-uutf-devel >= 1.0.0

# See comment above about dependency loops. If the issue is not resolved by
# Fedora 36, this can be removed.
Obsoletes: %{name}-doc < 4.4.0-1
Provides: %{name}-doc = %{version}-%{release}

%description
TyXML provides a set of convenient combinators that uses the OCaml type
system to ensure the validity of the generated documents. TyXML can be
Expand All @@ -47,7 +38,6 @@ combinators.
Summary: Development files for %{name}
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: ocaml-re-devel%{?_isa}
Requires: ocaml-seq-devel%{?_isa}
Requires: ocaml-uutf-devel%{?_isa}

%description devel
Expand All @@ -65,6 +55,8 @@ syntaxes for TyXML.
Summary: Development files for %{name}-syntax
Requires: %{name}-syntax%{?_isa} = %{version}-%{release}
Requires: ocaml-ppxlib-devel%{?_isa}
Requires: ocaml-re-devel%{?_isa}
Requires: ocaml-uutf-devel%{?_isa}

%description syntax-devel
The %{name}-syntax-devel package contains libraries and signature files
Expand Down Expand Up @@ -114,136 +106,49 @@ Requires: %{name}-syntax-devel%{?_isa} = %{version}-%{release}
Requires: %{name}-ppx%{?_isa} = %{version}-%{release}
Requires: ocaml-markup-devel%{?_isa}
Requires: ocaml-ppxlib-devel%{?_isa}
Requires: ocaml-re-devel%{?_isa}

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

%prep
%autosetup -n %{srcname}-%{version} -p1
%autosetup -n tyxml-%{version} -p1

%build
dune build %{?_smp_mflags} @install
%dune_build

%install
dune install --destdir=%{buildroot}

# We do not want the ml files
find %{buildroot}%{_libdir}/ocaml -name \*.ml -delete

# We install the documentation with the doc macro
rm -fr %{buildroot}%{_prefix}/doc
%dune_install -s

%check
# As of version 4.4.0, the tyxml-jsx tests fail due to lack of the reason
# package in Fedora.
dune runtest -p tyxml,tyxml-syntax,tyxml-ppx
%dune_check -p tyxml,tyxml-syntax,tyxml-ppx

%files
%files -f .ofiles-tyxml
%doc CHANGES.md README.md
%license LICENSE
%dir %{_libdir}/ocaml/%{srcname}/
%dir %{_libdir}/ocaml/%{srcname}/functor/
%{_libdir}/ocaml/%{srcname}/META
%{_libdir}/ocaml/%{srcname}/%{srcname}*.cma
%{_libdir}/ocaml/%{srcname}/%{srcname}*.cmi
%{_libdir}/ocaml/%{srcname}/functor/*.cma
%{_libdir}/ocaml/%{srcname}/functor/*.cmi
%ifarch %{ocaml_native_compiler}
%{_libdir}/ocaml/%{srcname}/%{srcname}*.cmxs
%{_libdir}/ocaml/%{srcname}/functor/*.cmxs
%endif

%files devel
%{_libdir}/ocaml/%{srcname}/dune-package
%{_libdir}/ocaml/%{srcname}/opam
%ifarch %{ocaml_native_compiler}
%{_libdir}/ocaml/%{srcname}/%{srcname}*.a
%{_libdir}/ocaml/%{srcname}/%{srcname}*.cmx
%{_libdir}/ocaml/%{srcname}/%{srcname}*.cmxa
%{_libdir}/ocaml/%{srcname}/functor/*.a
%{_libdir}/ocaml/%{srcname}/functor/*.cmx
%{_libdir}/ocaml/%{srcname}/functor/*.cmxa
%endif
%{_libdir}/ocaml/%{srcname}/%{srcname}*.cmt
%{_libdir}/ocaml/%{srcname}/%{srcname}*.cmti
%{_libdir}/ocaml/%{srcname}/%{srcname}*.mli
%{_libdir}/ocaml/%{srcname}/functor/*.cmt
%{_libdir}/ocaml/%{srcname}/functor/*.cmti
%{_libdir}/ocaml/%{srcname}/functor/*.mli

%files syntax
%dir %{_libdir}/ocaml/%{srcname}-syntax/
%{_libdir}/ocaml/%{srcname}-syntax/META
%{_libdir}/ocaml/%{srcname}-syntax/%{srcname}*.cma
%{_libdir}/ocaml/%{srcname}-syntax/%{srcname}*.cmi
%ifarch %{ocaml_native_compiler}
%{_libdir}/ocaml/%{srcname}-syntax/%{srcname}*.cmxs
%endif

%files syntax-devel
%{_libdir}/ocaml/%{srcname}-syntax/dune-package
%{_libdir}/ocaml/%{srcname}-syntax/opam
%ifarch %{ocaml_native_compiler}
%{_libdir}/ocaml/%{srcname}-syntax/%{srcname}*.a
%{_libdir}/ocaml/%{srcname}-syntax/%{srcname}*.cmx
%{_libdir}/ocaml/%{srcname}-syntax/%{srcname}*.cmxa
%endif
%{_libdir}/ocaml/%{srcname}-syntax/%{srcname}*.cmt
%{_libdir}/ocaml/%{srcname}-syntax/%{srcname}*.cmti
%{_libdir}/ocaml/%{srcname}-syntax/*.mli

%files jsx
%dir %{_libdir}/ocaml/%{srcname}-jsx/
%{_libdir}/ocaml/%{srcname}-jsx/META
%{_libdir}/ocaml/%{srcname}-jsx/ppx.exe
%{_libdir}/ocaml/%{srcname}-jsx/%{srcname}*.cma
%{_libdir}/ocaml/%{srcname}-jsx/%{srcname}*.cmi
%ifarch %{ocaml_native_compiler}
%{_libdir}/ocaml/%{srcname}-jsx/%{srcname}*.cmxs
%endif

%files jsx-devel
%{_libdir}/ocaml/%{srcname}-jsx/dune-package
%{_libdir}/ocaml/%{srcname}-jsx/opam
%ifarch %{ocaml_native_compiler}
%{_libdir}/ocaml/%{srcname}-jsx/%{srcname}*.a
%{_libdir}/ocaml/%{srcname}-jsx/%{srcname}*.cmx
%{_libdir}/ocaml/%{srcname}-jsx/%{srcname}*.cmxa
%endif
%{_libdir}/ocaml/%{srcname}-jsx/%{srcname}*.cmt

%files ppx
%dir %{_libdir}/ocaml/%{srcname}-ppx/
%dir %{_libdir}/ocaml/%{srcname}-ppx/internal/
%{_libdir}/ocaml/%{srcname}-ppx/META
%{_libdir}/ocaml/%{srcname}-ppx/ppx.exe
%{_libdir}/ocaml/%{srcname}-ppx/%{srcname}*.cma
%{_libdir}/ocaml/%{srcname}-ppx/%{srcname}*.cmi
%{_libdir}/ocaml/%{srcname}-ppx/internal/*.cma
%{_libdir}/ocaml/%{srcname}-ppx/internal/*.cmi
%ifarch %{ocaml_native_compiler}
%{_libdir}/ocaml/%{srcname}-ppx/%{srcname}*.cmxs
%{_libdir}/ocaml/%{srcname}-ppx/internal/*.cmxs
%endif

%files ppx-devel
%{_libdir}/ocaml/%{srcname}-ppx/dune-package
%{_libdir}/ocaml/%{srcname}-ppx/opam
%ifarch %{ocaml_native_compiler}
%{_libdir}/ocaml/%{srcname}-ppx/%{srcname}*.a
%{_libdir}/ocaml/%{srcname}-ppx/%{srcname}*.cmx
%{_libdir}/ocaml/%{srcname}-ppx/%{srcname}*.cmxa
%{_libdir}/ocaml/%{srcname}-ppx/internal/*.a
%{_libdir}/ocaml/%{srcname}-ppx/internal/*.cmx
%{_libdir}/ocaml/%{srcname}-ppx/internal/*.cmxa
%endif
%{_libdir}/ocaml/%{srcname}-ppx/%{srcname}*.cmt
%{_libdir}/ocaml/%{srcname}-ppx/internal/*.cmt
%{_libdir}/ocaml/%{srcname}-ppx/internal/*.cmti
%{_libdir}/ocaml/%{srcname}-ppx/internal/*.mli

%files devel -f .ofiles-tyxml-devel

%files syntax -f .ofiles-tyxml-syntax

%files syntax-devel -f .ofiles-tyxml-syntax-devel

%files jsx -f .ofiles-tyxml-jsx

%files jsx-devel -f .ofiles-tyxml-jsx-devel

%files ppx -f .ofiles-tyxml-ppx

%files ppx-devel -f .ofiles-tyxml-ppx-devel

%changelog
* Mon Dec 23 2024 Durga Jagadeesh Palli <[email protected]> - 4.6.0-13
- Initial Azure Linux import from Fedora 41 (license: MIT)
- License verified

* Fri Oct 15 2021 Pawel Winogrodzki <[email protected]> - 4.5.0-2
- Initial CBL-Mariner import from Fedora 34 (license: MIT).

Expand Down
4 changes: 2 additions & 2 deletions cgmanifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -14912,8 +14912,8 @@
"type": "other",
"other": {
"name": "ocaml-tyxml",
"version": "4.5.0",
"downloadUrl": "https://github.com/ocsigen/tyxml/releases/download/4.5.0/tyxml-4.5.0.tbz"
"version": "4.6.0",
"downloadUrl": "https://github.com/ocsigen/tyxml/releases/download/4.6.0/tyxml-4.6.0.tbz"
}
}
},
Expand Down