Sync from SUSE:ALP:Source:Standard:1.0 ocaml-augeas revision a6c8c0bd2092b957ec925ac2b469438b

This commit is contained in:
Adrian Schröter 2023-11-27 11:58:02 +01:00
commit 7047595881
7 changed files with 185 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

View File

@ -0,0 +1,35 @@
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

BIN
ocaml-augeas-0.6.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -0,0 +1,17 @@
-----BEGIN PGP SIGNATURE-----
iQJFBAABCAAvFiEE93dPsa0HSn6Mh2fqkXOPc+G3aKAFAl1b/RIRHHJpY2hAYW5u
ZXhpYS5vcmcACgkQkXOPc+G3aKCWeA//bU7ozTCLmfRRJk0PpHeMjzLbtMF+2Yh3
hY9Ey2q9Kt4yoRrneEL4QWL5y87PFjAoabNOtP7bJN36xZYQ66C/GGSmg2DjFPHL
Ol2FOU7O63auKFsiXt9mDQRO2Mh/Trv+ZJ4cSW/gTpEH4YsSp+70rsfvADQlEWhO
fYr7A0JPynxhVCM/cOsJ6Dvgtl2Iwb6CJ8a9kqACJQ8KvcFhkrsBiliAo5omlXev
YjZ/iX1EWIGxeCfOvPpkkP4jBWS28aQqvCQIJ/e3dOOO4W9R0bFz1Xi4I+C7oieV
Yxqn9DBmLuHw2ZCgxd626RZ5LApOnjH/kz4vkWBSmTrhbAhIcfsgq49iAtw8r14E
D1NjEIr2NrEkqswdO8ZU8UYv1AgXxIeyFfjcCj0+X3QRpvBzd22SVb+iTLdo//sp
xDJNCy7QHxKnWS+bAAcK5dHEeYPamqn+B1Veato7rRn0a0yxb328H4YVUv3U/DMN
UXKz+JKVBI5RjH13K4HWCiUb2shy08q/VnsILxaz4k/v6p0Wm6ub+pVoUFPl98n9
3VB+ltoAJrI7AoPnkvHWTAm/tQ8ZHepF2fAU8cHMxoOx2HmGka+r3SsG2lepm7k6
Kqd4K0SchBOSsMzbqoAaq5XIBm/Ieo0+6ZdlvUDfqQq5JLREXsvn4eqQ8a1EnJvV
d0suVCSUapM=
=cw0u
-----END PGP SIGNATURE-----

8
ocaml-augeas.changes Normal file
View File

@ -0,0 +1,8 @@
-------------------------------------------------------------------
Thu Feb 9 14:11:01 MST 2023 - carnold@suse.com
- Initial creation of the ocaml-augeas package. This code was
originally bundled in libguestfs.
- Initial version 0.6
caml_named_value-returns-const-value-pointer-in-OCam.patch

1
ocaml-augeas.rpmlintrc Normal file
View File

@ -0,0 +1 @@
addFilter("static-library-without-debuginfo")

98
ocaml-augeas.spec Normal file
View File

@ -0,0 +1,98 @@
#
# spec file for package ocaml-augeas
#
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: ocaml-augeas
Version: 0.6
Release: 0
Summary: OCaml bindings for Augeas configuration API
License: GPL-2.0-or-later
URL: http://people.redhat.com/~rjones/augeas/files/
Source0: http://people.redhat.com/~rjones/augeas/files/%{name}-%{version}.tar.gz
Source1: %{name}-%{version}.tar.gz.sig
Source2: ocaml-augeas.rpmlintrc
Patch1: caml_named_value-returns-const-value-pointer-in-OCam.patch
BuildRequires: make
BuildRequires: ocaml >= 3.09.0
BuildRequires: ocaml-findlib-devel
BuildRequires: ocaml-ocamldoc
BuildRequires: augeas-devel >= 0.1.0
BuildRequires: chrpath
%description
Augeas is a unified system for editing arbitrary configuration
files. This provides complete OCaml bindings for Augeas.
%package devel
Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release}
%description devel
The %{name}-devel package contains libraries and signature files for
developing applications that use %{name}.
%prep
%autosetup -p1
%build
%define _lto_cflags %{nil}
%configure
make all
make doc
%check
make check
%install
export DESTDIR=$RPM_BUILD_ROOT
export OCAMLFIND_DESTDIR=$RPM_BUILD_ROOT%{_libdir}/ocaml
mkdir -p $OCAMLFIND_DESTDIR $OCAMLFIND_DESTDIR/stublibs
ocamlfind install augeas META *.mli *.cmx *.cma *.cmxa *.a augeas.cmi *.so
chrpath --delete $OCAMLFIND_DESTDIR/stublibs/dll*.so
%files
%doc COPYING.LIB
%{_libdir}/ocaml/augeas
%exclude %{_libdir}/ocaml/augeas/*.a
%exclude %{_libdir}/ocaml/augeas/*.cmxa
%exclude %{_libdir}/ocaml/augeas/*.cmx
%exclude %{_libdir}/ocaml/augeas/*.mli
%{_libdir}/ocaml/stublibs/*.so
%{_libdir}/ocaml/stublibs/*.so.owner
%files devel
%doc html
%{_libdir}/ocaml/augeas/*.a
%{_libdir}/ocaml/augeas/*.cmxa
%{_libdir}/ocaml/augeas/*.cmx
%{_libdir}/ocaml/augeas/*.mli
%changelog