Compare commits

...

No commits in common. "c9s" and "c10s" have entirely different histories.
c9s ... c10s

9 changed files with 105 additions and 104 deletions

5
.gitignore vendored
View File

@ -1,3 +1,2 @@
ocaml-augeas-0.4.tar.gz /ocaml-augeas-*.tar.gz
/ocaml-augeas-0.5.tar.gz /ocaml-augeas-*.tar.gz.sig
/ocaml-augeas-0.6.tar.gz

View File

@ -1,28 +0,0 @@
From 56c0602e972f1fae336198eb9587d71f1e36daff Mon Sep 17 00:00:00 2001
From: "Richard W.M. Jones" <rjones@redhat.com>
Date: Tue, 20 Aug 2019 15:06:57 +0100
Subject: [PATCH 1/2] Use ocamlopt -g option.
Originally from Fedora.
---
Makefile.in | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Makefile.in b/Makefile.in
index e01385f..4ae5ef5 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -34,8 +34,8 @@ LIBS = @AUGEAS_LIBS@ @LIBXML2_LIBS@ @LIBS@
OCAMLCFLAGS = -g
OCAMLCPACKAGES =
-OCAMLOPTFLAGS =
-OCAMLOPTPACKAGES =
+OCAMLOPTFLAGS = $(OCAMLCFLAGS)
+OCAMLOPTPACKAGES = $(OCAMLCPACKAGES)
OCAMLDOCFLAGS = -html -sort
--
2.23.0

View File

@ -1,35 +0,0 @@
From 1cf5aef99b26a46529ca797547c0b49627fffe78 Mon Sep 17 00:00:00 2001
From: "Richard W.M. Jones" <rjones@redhat.com>
Date: Sat, 7 Dec 2019 11:08:54 +0000
Subject: [PATCH 2/2] caml_named_value returns const value pointer in OCaml
4.09+
---
augeas-c.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/augeas-c.c b/augeas-c.c
index 9217017..679bcb5 100644
--- a/augeas-c.c
+++ b/augeas-c.c
@@ -86,7 +86,7 @@ static const int error_map_len = sizeof error_map / sizeof error_map[0];
static void
raise_error_and_maybe_close (augeas_t t, const char *msg, bool close_handle)
{
- value *exn = caml_named_value ("Augeas.Error");
+ const value *exn = caml_named_value ("Augeas.Error");
value args[5];
const int code = aug_error (t);
const char *aug_err_msg;
@@ -132,7 +132,7 @@ raise_error_and_maybe_close (augeas_t t, const char *msg, bool close_handle)
static void
raise_init_error (const char *msg)
{
- value *exn = caml_named_value ("Augeas.Error");
+ const value *exn = caml_named_value ("Augeas.Error");
value args[5];
args[0] = caml_alloc (1, 0);
--
2.23.0

6
gating.yaml Executable file
View File

@ -0,0 +1,6 @@
--- !Policy
product_versions:
- rhel-*
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional}

BIN
libguestfs.keyring Normal file

Binary file not shown.

View File

@ -1,26 +1,24 @@
%undefine _package_note_flags # OCaml packages not built on i686 since OCaml 5 / Fedora 39.
%global opt %(test -x %{_bindir}/ocamlopt && echo 1 || echo 0) ExcludeArch: %{ix86}
Name: ocaml-augeas Name: ocaml-augeas
Version: 0.6 Version: 0.7
Release: 23%{?dist} Release: 1%{?dist}
Summary: OCaml bindings for Augeas configuration API Summary: OCaml bindings for Augeas configuration API
License: LGPLv2+ with exceptions License: LGPL-2.1-or-later WITH OCaml-LGPL-linking-exception
URL: http://people.redhat.com/~rjones/augeas/files/ URL: https://people.redhat.com/~rjones/augeas/
Source0: http://people.redhat.com/~rjones/augeas/files/%{name}-%{version}.tar.gz Source0: https://download.libguestfs.org/ocaml-augeas/ocaml-augeas-%{version}.tar.gz
Source1: https://download.libguestfs.org/ocaml-augeas/ocaml-augeas-%{version}.tar.gz.sig
Source2: libguestfs.keyring
# Upstream patch to enable debuginfo. BuildRequires: make
Patch1: 0001-Use-ocamlopt-g-option.patch
# Const-correctness fix for OCaml 4.09+
Patch2: 0002-caml_named_value-returns-const-value-pointer-in-OCam.patch
BuildRequires: make
BuildRequires: ocaml >= 3.09.0 BuildRequires: ocaml >= 3.09.0
BuildRequires: ocaml-findlib-devel BuildRequires: ocaml-findlib
BuildRequires: ocaml-ocamldoc BuildRequires: ocaml-ocamldoc
BuildRequires: ocaml-rpm-macros
BuildRequires: augeas-devel >= 0.1.0 BuildRequires: augeas-devel >= 0.1.0
BuildRequires: chrpath BuildRequires: gnupg2
%description %description
@ -30,7 +28,7 @@ files. This provides complete OCaml bindings for Augeas.
%package devel %package devel
Summary: Development files for %{name} Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release} Requires: %{name}%{?_isa} = %{version}-%{release}
%description devel %description devel
@ -39,12 +37,17 @@ developing applications that use %{name}.
%prep %prep
%{gpgverify} --keyring='%{SOURCE2}' --signature='%{SOURCE1}' --data='%{SOURCE0}'
%autosetup -p1 %autosetup -p1
# Pass -g to ocamlmklib
sed -i 's/ocamlmklib/& -g/' Makefile.in
%build %build
%configure %configure
%if %opt %ifarch %{ocaml_native_compiler}
# _smp_mflags breaks the build.
make make
%else %else
make mlaugeas.cma test_augeas make mlaugeas.cma test_augeas
@ -64,39 +67,72 @@ mkdir -p $OCAMLFIND_DESTDIR $OCAMLFIND_DESTDIR/stublibs
# The upstream 'make install' rule is missing '*.so' and distributes # The upstream 'make install' rule is missing '*.so' and distributes
# '*.cmi' instead of just the augeas.cmi file. Temporary fix: # '*.cmi' instead of just the augeas.cmi file. Temporary fix:
#make install #make install
%if %opt %ifarch %{ocaml_native_compiler}
ocamlfind install augeas META *.mli *.cmx *.cma *.cmxa *.a augeas.cmi *.so ocamlfind install augeas META *.mli *.cmx *.cma *.cmxa *.a augeas.cmi *.so
%else %else
ocamlfind install augeas META *.mli *.cma *.a augeas.cmi *.so ocamlfind install augeas META *.mli *.cma *.a augeas.cmi *.so
%endif %endif
chrpath --delete $OCAMLFIND_DESTDIR/stublibs/dll*.so %ocaml_files
%files %files -f .ofiles
%doc COPYING.LIB %license COPYING.LIB
%{_libdir}/ocaml/augeas
%if %opt
%exclude %{_libdir}/ocaml/augeas/*.a
%exclude %{_libdir}/ocaml/augeas/*.cmxa
%exclude %{_libdir}/ocaml/augeas/*.cmx
%endif
%exclude %{_libdir}/ocaml/augeas/*.mli
%{_libdir}/ocaml/stublibs/*.so
%{_libdir}/ocaml/stublibs/*.so.owner
%files devel %files devel -f .ofiles-devel
%doc html %doc html
%if %opt
%{_libdir}/ocaml/augeas/*.a
%{_libdir}/ocaml/augeas/*.cmxa
%{_libdir}/ocaml/augeas/*.cmx
%endif
%{_libdir}/ocaml/augeas/*.mli
%changelog %changelog
* Thu May 08 2025 Richard W.M. Jones <rjones@redhat.com> - 0.7-1
- New upstream version 0.7
- New download URL
- Check GPG signature
resolves: RHEL-90257
* Wed Oct 30 2024 Troy Dawson <tdawson@redhat.com> - 0.6-37
- Bump release for October 2024 mass rebuild:
Resolves: RHEL-64018
* Tue Jun 25 2024 Troy Dawson <tdawson@redhat.com> - 0.6-36
- Bump release for June 2024 mass rebuild
* Wed Jun 19 2024 Richard W.M. Jones <rjones@redhat.com> - 0.6-35
- OCaml 5.2.0 ppc64le fix
* Wed May 29 2024 Richard W.M. Jones <rjones@redhat.com> - 0.6-34
- OCaml 5.2.0 for Fedora 41
* Mon Apr 08 2024 Richard W.M. Jones <rjones@redhat.com> - 0.6-33
- No change, just bump release.
* Thu Jan 25 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.6-31
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Sun Jan 21 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.6-30
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Mon Dec 18 2023 Richard W.M. Jones <rjones@redhat.com> - 0.6-29
- OCaml 5.1.1 + s390x code gen fix for Fedora 40
* Tue Dec 12 2023 Richard W.M. Jones <rjones@redhat.com> - 0.6-28
- OCaml 5.1.1 rebuild for Fedora 40
* Thu Oct 05 2023 Richard W.M. Jones <rjones@redhat.com> - 0.6-27
- OCaml 5.1 rebuild for Fedora 40
* Thu Jul 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.6-26
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Tue Jul 11 2023 Richard W.M. Jones <rjones@redhat.com> - 0.6-25
- OCaml 5.0 rebuild for Fedora 39
* Mon Jul 10 2023 Jerry James <loganjerry@gmail.com> - 0.6-24
- OCaml 5.0.0 rebuild
- Convert License tag to SPDX
- Use new OCaml macros
* Tue Jan 24 2023 Richard W.M. Jones <rjones@redhat.com> - 0.6-23 * Tue Jan 24 2023 Richard W.M. Jones <rjones@redhat.com> - 0.6-23
- Rebuild OCaml packages for F38 - Rebuild OCaml packages for F38

View File

@ -1 +1,2 @@
SHA512 (ocaml-augeas-0.6.tar.gz) = e747f5c09d3821b41d98e3f12c8dfe9bb13a69d6ccaaf954f4bb33e8e4d9d62603ae26fe9f93f10b2705872526b1863a1c20e0c8a53858fdf60f8cb8cbf50b7a SHA512 (ocaml-augeas-0.7.tar.gz) = 2d1ef07f116abf04d74ae4bb2b9c088fd69b1d46509b684fdad454deeca554bbf737346b115976f2f7a29851a3f5186ef0479197412684a83fcd60286e6ae3ec
SHA512 (ocaml-augeas-0.7.tar.gz.sig) = 5834ea0cd1a991f08b6c61c783cad7c9e9aaf5a3d0ac86ac8e9609353daf43b9a9fab9df2241b5f5aee225358ab89dfd7e0a579b044d01b2e2007fc4be50ee92

8
tests/basic-test.sh Executable file
View File

@ -0,0 +1,8 @@
#!/bin/bash -
set -e
set -x
# Compile trivial augeas program.
echo 'Augeas.create "/" None [AugNoLoad]' > augtest.ml
ocamlfind ocamlopt -package augeas augtest.ml -linkpkg -o augtest
./augtest

14
tests/tests.yml Executable file
View File

@ -0,0 +1,14 @@
- hosts: localhost
roles:
- role: standard-test-basic
tags:
- classic
required_packages:
- ocaml
- ocaml-findlib
- ocaml-augeas-devel
- augeas-devel
tests:
- simple:
dir: .
run: ./basic-test.sh