Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/extra/ruby
diff options
context:
space:
mode:
authorTasos Sahanidis <tasos@tasossah.com>2024-08-27 00:55:16 +0300
committerTasos Sahanidis <tasos@tasossah.com>2024-08-27 00:55:54 +0300
commitfdd72416f144129166b1b31614e2745b6802e0cf (patch)
tree94281f92d84254814cb4ccbe58277ddd8afc01e2 /extra/ruby
parent7db3ccbd0c0a4d595504c760f7a6fb335ed76704 (diff)
extra/ruby: Add temporary patch
Diffstat (limited to 'extra/ruby')
-rw-r--r--extra/ruby/055613fd868a8c94e43893f8c58a00cdd2a81f6d.patch24
-rw-r--r--extra/ruby/PKGBUILD8
2 files changed, 32 insertions, 0 deletions
diff --git a/extra/ruby/055613fd868a8c94e43893f8c58a00cdd2a81f6d.patch b/extra/ruby/055613fd868a8c94e43893f8c58a00cdd2a81f6d.patch
new file mode 100644
index 00000000..b2ad8437
--- /dev/null
+++ b/extra/ruby/055613fd868a8c94e43893f8c58a00cdd2a81f6d.patch
@@ -0,0 +1,24 @@
+From 055613fd868a8c94e43893f8c58a00cdd2a81f6d Mon Sep 17 00:00:00 2001
+From: Nobuyoshi Nakada <nobu@ruby-lang.org>
+Date: Fri, 22 Mar 2024 18:18:35 +0900
+Subject: [PATCH] Fix pointer incompatiblity
+
+Since the subsecond part is discarded, WIDEVAL to VALUE conversion is
+needed.
+---
+ time.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/time.c b/time.c
+index 6179b081c02fc9..3304b2f4f4856a 100644
+--- a/time.c
++++ b/time.c
+@@ -2346,7 +2346,7 @@ zone_timelocal(VALUE zone, VALUE time)
+ struct time_object *tobj = RTYPEDDATA_GET_DATA(time);
+ wideval_t t, s;
+
+- split_second(tobj->timew, &t, &s);
++ wdivmod(tobj->timew, WINT2FIXWV(TIME_SCALE), &t, &s);
+ tm = tm_from_time(rb_cTimeTM, time);
+ utc = rb_check_funcall(zone, id_local_to_utc, 1, &tm);
+ if (UNDEF_P(utc)) return 0;
diff --git a/extra/ruby/PKGBUILD b/extra/ruby/PKGBUILD
index b03abc17..13473577 100644
--- a/extra/ruby/PKGBUILD
+++ b/extra/ruby/PKGBUILD
@@ -18,3 +18,11 @@ if [ "${CARCH}" = "i486" ]; then
'
)"
fi
+
+# Should be fixed next version
+if [[ $pkgbase == "3.2.4" ]]; then
+ sources+=(055613fd868a8c94e43893f8c58a00cdd2a81f6d.patch)
+ unset sha512sums
+ b2sums+=(SKIP)
+ eval "$(declare -f prepare | sed 's@patch @patch -p1 -i ../055613fd868a8c94e43893f8c58a00cdd2a81f6d.patch; patch @')"
+fi