Accepting request 964749 from devel:libraries:c_c++
OBS-URL: https://build.opensuse.org/request/show/964749 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/augeas?expand=0&rev=55
This commit is contained in:
commit
070bc76fe9
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Mar 24 12:11:08 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
|
- add sysctl_parsing.patch (bsc#1197443)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Fri Jan 28 16:14:57 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
Fri Jan 28 16:14:57 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
|
@ -32,6 +32,8 @@ Patch1: gcc9-disable-broken-test.patch
|
|||||||
Patch2: augeas-new_options_for_chrony.patch
|
Patch2: augeas-new_options_for_chrony.patch
|
||||||
Patch3: augeas-allow_printable_ASCII.patch
|
Patch3: augeas-allow_printable_ASCII.patch
|
||||||
Patch4: remove-unportable-tests.patch
|
Patch4: remove-unportable-tests.patch
|
||||||
|
# from https://patch-diff.githubusercontent.com/raw/hercules-team/augeas/pull/755.patch
|
||||||
|
Patch5: sysctl_parsing.patch
|
||||||
BuildRequires: glibc-locale
|
BuildRequires: glibc-locale
|
||||||
BuildRequires: pkgconfig
|
BuildRequires: pkgconfig
|
||||||
BuildRequires: readline-devel
|
BuildRequires: readline-devel
|
||||||
@ -100,6 +102,7 @@ modifying the official lenses, or when creating new ones.
|
|||||||
%patch2 -p1
|
%patch2 -p1
|
||||||
%patch3 -p1
|
%patch3 -p1
|
||||||
%patch4 -p1
|
%patch4 -p1
|
||||||
|
%patch5 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%configure \
|
%configure \
|
||||||
@ -121,13 +124,13 @@ mv %{buildroot}/%{_datadir}/vim/vimfiles %{buildroot}/%{_datadir}/vim/site
|
|||||||
%postun -n %{libname} -p /sbin/ldconfig
|
%postun -n %{libname} -p /sbin/ldconfig
|
||||||
|
|
||||||
%files
|
%files
|
||||||
|
%license COPYING
|
||||||
|
%doc AUTHORS NEWS
|
||||||
%{_bindir}/augmatch
|
%{_bindir}/augmatch
|
||||||
%{_bindir}/augtool
|
%{_bindir}/augtool
|
||||||
%{_bindir}/augparse
|
%{_bindir}/augparse
|
||||||
%{_bindir}/fadot
|
%{_bindir}/fadot
|
||||||
%{_mandir}/man1/*
|
%{_mandir}/man1/*
|
||||||
%license COPYING
|
|
||||||
%doc AUTHORS NEWS
|
|
||||||
|
|
||||||
%files -n %{libname}
|
%files -n %{libname}
|
||||||
%{_libdir}/*.so.*
|
%{_libdir}/*.so.*
|
||||||
|
152
sysctl_parsing.patch
Normal file
152
sysctl_parsing.patch
Normal file
@ -0,0 +1,152 @@
|
|||||||
|
From 6ddfca24cd333ec93938b3de85c2658da19ca8c8 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Michal Filka <mfilka@suse.cz>
|
||||||
|
Date: Thu, 24 Mar 2022 11:18:10 +0100
|
||||||
|
Subject: [PATCH] Sysctl keys can contain some more non-alphanumeric
|
||||||
|
charackters
|
||||||
|
|
||||||
|
like net.ipv4.conf.*.rp_filter = 2
|
||||||
|
---
|
||||||
|
.gnulib | 2 +-
|
||||||
|
lenses/sysctl.aug | 14 +++++++++++++-
|
||||||
|
lenses/tests/test_sysctl.aug | 24 ++++++++++++++++++++++++
|
||||||
|
man/augtool.1 | 26 +++++++++++---------------
|
||||||
|
4 files changed, 49 insertions(+), 17 deletions(-)
|
||||||
|
|
||||||
|
--- a/lenses/sysctl.aug
|
||||||
|
+++ b/lenses/sysctl.aug
|
||||||
|
@@ -33,8 +33,20 @@ let filter = incl "/boot/loader.conf"
|
||||||
|
(* View: comment *)
|
||||||
|
let comment = Util.comment_generic /[ \t]*[#;][ \t]*/ "# "
|
||||||
|
|
||||||
|
+(* View: entry
|
||||||
|
+ basically a Simplevars.entry but key has to allow some special chars as '*' *)
|
||||||
|
+let entry =
|
||||||
|
+ let some_value = Sep.space_equal . store Simplevars.to_comment_re
|
||||||
|
+ (* Rx.word extended by * and : *)
|
||||||
|
+ in let word = /[*:A-Za-z0-9_.-]+/
|
||||||
|
+ (* Avoid ambiguity in tree by making a subtree here *)
|
||||||
|
+ in let empty_value = [del /[ \t]*=/ "="] . store ""
|
||||||
|
+ in [ Util.indent . key word
|
||||||
|
+ . (some_value? | empty_value)
|
||||||
|
+ . (Util.eol | Util.comment_eol) ]
|
||||||
|
+
|
||||||
|
(* View: lns
|
||||||
|
The sysctl lens *)
|
||||||
|
-let lns = (Util.empty | comment | Simplevars.entry)*
|
||||||
|
+let lns = (Util.empty | comment | entry)*
|
||||||
|
|
||||||
|
let xfm = transform lns filter
|
||||||
|
diff --git a/lenses/tests/test_sysctl.aug b/lenses/tests/test_sysctl.aug
|
||||||
|
index 42f31c0f..daec3dc8 100644
|
||||||
|
--- a/lenses/tests/test_sysctl.aug
|
||||||
|
+++ b/lenses/tests/test_sysctl.aug
|
||||||
|
@@ -18,6 +18,13 @@ kernel.sysrq = 0
|
||||||
|
net.ipv4.tcp_mem = \t393216 524288 786432
|
||||||
|
"
|
||||||
|
|
||||||
|
+(* Variable: spec_chars_sysctl *)
|
||||||
|
+let spec_chars_sysctl = "# Kernel sysctl configuration file
|
||||||
|
+# Controls IP packet forwarding
|
||||||
|
+net.ipv4.conf.*.rp_filter = 2
|
||||||
|
+net.ipv4.conf.ib0:0.arp_filter = 1
|
||||||
|
+"
|
||||||
|
+
|
||||||
|
(* Test: Sysctl.lns *)
|
||||||
|
test Sysctl.lns get default_sysctl =
|
||||||
|
{ "#comment" = "Kernel sysctl configuration file" }
|
||||||
|
@@ -31,6 +38,13 @@ test Sysctl.lns get default_sysctl =
|
||||||
|
{ "#comment" = "Semicolon comments are also allowed" }
|
||||||
|
{ "net.ipv4.tcp_mem" = "393216 524288 786432" }
|
||||||
|
|
||||||
|
+(* Test: Sysctl.lns *)
|
||||||
|
+test Sysctl.lns get spec_chars_sysctl =
|
||||||
|
+ { "#comment" = "Kernel sysctl configuration file" }
|
||||||
|
+ { "#comment" = "Controls IP packet forwarding"}
|
||||||
|
+ { "net.ipv4.conf.*.rp_filter" = "2" }
|
||||||
|
+ { "net.ipv4.conf.ib0:0.arp_filter" = "1" }
|
||||||
|
+
|
||||||
|
(* Test: Sysctl.lns *)
|
||||||
|
test Sysctl.lns put default_sysctl after
|
||||||
|
set "net.ipv4.ip_forward" "1" ;
|
||||||
|
@@ -46,6 +60,16 @@ net.ipv4.ip_forward = 1
|
||||||
|
net.ipv4.tcp_mem = \t393216 524288 786432
|
||||||
|
"
|
||||||
|
|
||||||
|
+(* Test: Sysctl.lns *)
|
||||||
|
+test Sysctl.lns put spec_chars_sysctl after
|
||||||
|
+ set "net.ipv4.conf.*.rp_filter" "0" ;
|
||||||
|
+ set "net.ipv4.conf.ib0:0.arp_filter" "0"
|
||||||
|
+ = "# Kernel sysctl configuration file
|
||||||
|
+# Controls IP packet forwarding
|
||||||
|
+net.ipv4.conf.*.rp_filter = 0
|
||||||
|
+net.ipv4.conf.ib0:0.arp_filter = 0
|
||||||
|
+"
|
||||||
|
+
|
||||||
|
(* Local Variables: *)
|
||||||
|
(* mode: caml *)
|
||||||
|
(* End: *)
|
||||||
|
diff --git a/man/augtool.1 b/man/augtool.1
|
||||||
|
index c58cbc1a..7279654c 100644
|
||||||
|
--- a/man/augtool.1
|
||||||
|
+++ b/man/augtool.1
|
||||||
|
@@ -1,4 +1,4 @@
|
||||||
|
-.\" Automatically generated by Pod::Man 2.28 (Pod::Simple 3.31)
|
||||||
|
+.\" Automatically generated by Pod::Man 4.09 (Pod::Simple 3.35)
|
||||||
|
.\"
|
||||||
|
.\" Standard preamble:
|
||||||
|
.\" ========================================================================
|
||||||
|
@@ -46,7 +46,7 @@
|
||||||
|
.ie \n(.g .ds Aq \(aq
|
||||||
|
.el .ds Aq '
|
||||||
|
.\"
|
||||||
|
-.\" If the F register is turned on, we'll generate index entries on stderr for
|
||||||
|
+.\" If the F register is >0, we'll generate index entries on stderr for
|
||||||
|
.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
|
||||||
|
.\" entries marked with X<> in POD. Of course, you'll have to process the
|
||||||
|
.\" output yourself in some meaningful fashion.
|
||||||
|
@@ -54,20 +54,16 @@
|
||||||
|
.\" Avoid warning from groff about undefined register 'F'.
|
||||||
|
.de IX
|
||||||
|
..
|
||||||
|
-.nr rF 0
|
||||||
|
-.if \n(.g .if rF .nr rF 1
|
||||||
|
-.if (\n(rF:(\n(.g==0)) \{
|
||||||
|
-. if \nF \{
|
||||||
|
-. de IX
|
||||||
|
-. tm Index:\\$1\t\\n%\t"\\$2"
|
||||||
|
+.if !\nF .nr F 0
|
||||||
|
+.if \nF>0 \{\
|
||||||
|
+. de IX
|
||||||
|
+. tm Index:\\$1\t\\n%\t"\\$2"
|
||||||
|
..
|
||||||
|
-. if !\nF==2 \{
|
||||||
|
-. nr % 0
|
||||||
|
-. nr F 2
|
||||||
|
-. \}
|
||||||
|
+. if !\nF==2 \{\
|
||||||
|
+. nr % 0
|
||||||
|
+. nr F 2
|
||||||
|
. \}
|
||||||
|
.\}
|
||||||
|
-.rr rF
|
||||||
|
.\"
|
||||||
|
.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
|
||||||
|
.\" Fear. Run. Save yourself. No user-serviceable parts.
|
||||||
|
@@ -133,7 +129,7 @@
|
||||||
|
.\" ========================================================================
|
||||||
|
.\"
|
||||||
|
.IX Title "AUGTOOL 1"
|
||||||
|
-.TH AUGTOOL 1 "2016-08-05" "Augeas 1.5.0" "Augeas"
|
||||||
|
+.TH AUGTOOL 1 "2021-05-26" "Augeas 1.13.0" "Augeas"
|
||||||
|
.\" For nroff, turn off justification. Always turn off hyphenation; it makes
|
||||||
|
.\" way too many mistakes in technical documents.
|
||||||
|
.if n .ad l
|
||||||
|
@@ -275,7 +271,7 @@ Parse \s-1NODE\s0 using \s-1LENS\s0 and store the resulting tree at \s-1PATH.\s0
|
||||||
|
Add a transform for \s-1FILE\s0 using \s-1LENS.\s0 The \s-1LENS\s0 may be a module name or a
|
||||||
|
full lens name. If a module name is given, then \*(L"lns\*(R" will be the lens
|
||||||
|
assumed. The \s-1FILTER\s0 must be either \*(L"incl\*(R" or \*(L"excl\*(R". If the filter is
|
||||||
|
-\&\*(L"incl\*(R", the \s-1FILE\s0 will be parsed by the \s-1LENS. \s0 If the filter is \*(L"excl\*(R",
|
||||||
|
+\&\*(L"incl\*(R", the \s-1FILE\s0 will be parsed by the \s-1LENS.\s0 If the filter is \*(L"excl\*(R",
|
||||||
|
the \s-1FILE\s0 will be excluded from the \s-1LENS. FILE\s0 may contain wildcards.
|
||||||
|
.IP "\fBload-file\fR <\s-1FILE\s0>" 4
|
||||||
|
.IX Item "load-file <FILE>"
|
Loading…
x
Reference in New Issue
Block a user