File: 0011-rip-out-libxml2-s-libc_single_threaded-support.patch

package info (click to toggle)
ruby-nokogiri 1.18.2%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 8,076 kB
  • sloc: ansic: 38,893; xml: 27,665; ruby: 27,285; java: 15,348; cpp: 7,107; yacc: 244; sh: 208; makefile: 154; sed: 14
file content (30 lines) | stat: -rw-r--r-- 961 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
From fb618bd27ac7a9fd32973320016c7ff28dd2f60e Mon Sep 17 00:00:00 2001
From: Mike Dalessio <mike.dalessio@gmail.com>
Date: Fri, 5 May 2023 10:10:43 -0400
Subject: [PATCH] rip out libxml2's libc_single_threaded support

This is a preventative measure because this feature relies on a glibc
version we can't realistically require of users today. We're not yet
precompiling on a system with a modern-enough glibc to make this an
actual problem, but I'm doing it while all of this context is fresh.
---
 threads.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/threads.c b/threads.c
index 60dbce4c..eb1c12e5 100644
--- a/threads.c
+++ b/threads.c
@@ -27,7 +27,8 @@
 
 #if defined(HAVE_POSIX_THREADS) && \
     defined(__GLIBC__) && \
-    __GLIBC__ * 100 + __GLIBC_MINOR__ >= 234
+    __GLIBC__ * 100 + __GLIBC_MINOR__ >= 234 && \
+    !defined(NOKOGIRI_PRECOMPILED_LIBRARIES)
 
 /*
  * The modern way available since glibc 2.32.
-- 
2.40.1