Skip to content

Commit 79c00e1

Browse files
committed
Apply upstream patch to remove sibling argument
1 parent b092e83 commit 79c00e1

File tree

2 files changed

+29
-0
lines changed

2 files changed

+29
-0
lines changed

configs/components/_base-ruby-augeas.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
#
55

66
pkg.add_source("file://resources/patches/augeas/ruby-augeas-0.5.0-patch_c_extension.patch")
7+
pkg.add_source("file://resources/patches/augeas/ruby-augeas-0.5.0-remove-sibling-argument.patch")
78

89
# These can be overridden by the including component.
910
ruby_version ||= settings[:ruby_version]
@@ -75,6 +76,7 @@
7576
if ruby_version =~ /^3/
7677
build_commands << "#{platform.patch} --strip=2 --fuzz=0 --ignore-whitespace --no-backup-if-mismatch < ../ruby-augeas-0.5.0-patch_c_extension.patch"
7778
end
79+
build_commands << "#{platform.patch} --strip=1 --fuzz=0 --ignore-whitespace --no-backup-if-mismatch < ../ruby-augeas-0.5.0-remove-sibling-argument.patch"
7880
build_commands << "#{ruby} ext/augeas/extconf.rb"
7981
build_commands << "#{platform[:make]} -e -j$(shell expr $(shell #{platform[:num_cores]}) + 1)"
8082

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
From 9f1f9df48ef8c6f62349eccb90dc54a3c3d75e3f Mon Sep 17 00:00:00 2001
2+
From: Ewoud Kohl van Wijngaarden <[email protected]>
3+
Date: Wed, 31 Jan 2024 12:52:45 +0100
4+
Subject: [PATCH] Remove unused sibling argument from augeas_rm
5+
6+
This makes the function match the method definition. There was already a
7+
warning about this, but Fedora 40 applies more hardening and it's a
8+
fatal error.
9+
10+
Fixes: e6b57c58d24b ("Initial ruby bindings, written by Bryan Kearney")
11+
---
12+
ext/augeas/_augeas.c | 2 +-
13+
1 file changed, 1 insertion(+), 1 deletion(-)
14+
15+
diff --git a/ext/augeas/_augeas.c b/ext/augeas/_augeas.c
16+
index f9b49d1..7ef0d7d 100644
17+
--- a/ext/augeas/_augeas.c
18+
+++ b/ext/augeas/_augeas.c
19+
@@ -184,7 +184,7 @@ VALUE augeas_mv(VALUE s, VALUE src, VALUE dst) {
20+
*
21+
* Remove path and all its children. Returns the number of entries removed
22+
*/
23+
-VALUE augeas_rm(VALUE s, VALUE path, VALUE sibling) {
24+
+VALUE augeas_rm(VALUE s, VALUE path) {
25+
augeas *aug = aug_handle(s);
26+
const char *cpath = StringValueCStr(path) ;
27+

0 commit comments

Comments
 (0)