]> git.ipfire.org Git - people/mfischer/ipfire-2.x.git/blame - src/patches/ntp-4.2.8p15-build-fix-for-glibc-2.34.patch
Merge branch 'master' of ssh://git.ipfire.org/pub/git/ipfire-2.x
[people/mfischer/ipfire-2.x.git] / src / patches / ntp-4.2.8p15-build-fix-for-glibc-2.34.patch
CommitLineData
9c7de660
MT
1From 082a504cfcc046c3d8adaae1164268bc94e5108a Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Sat, 31 Jul 2021 10:51:41 -0700
4Subject: [PATCH] libntp: Do not use PTHREAD_STACK_MIN on glibc
5In glibc 2.34+ PTHREAD_STACK_MIN is not a compile-time constant which
6could mean different stack sizes at runtime on different architectures
7and it also causes compile failure. Default glibc thread stack size
8or 64Kb set by ntp should be good in glibc these days.
9Upstream-Status: Pending
10Signed-off-by: Khem Raj <raj.khem@gmail.com>
11---
12 libntp/work_thread.c | 2 +-
13 1 file changed, 1 insertion(+), 1 deletion(-)
14diff --git a/libntp/work_thread.c b/libntp/work_thread.c
15index 03a5647..3ddd751 100644
16--- a/libntp/work_thread.c
17+++ b/libntp/work_thread.c
18@@ -41,7 +41,7 @@
19 #ifndef THREAD_MINSTACKSIZE
20 # define THREAD_MINSTACKSIZE (64U * 1024)
21 #endif
22-#ifndef __sun
23+#if !defined(__sun) && !defined(__GLIBC__)
24 #if defined(PTHREAD_STACK_MIN) && THREAD_MINSTACKSIZE < PTHREAD_STACK_MIN
25 # undef THREAD_MINSTACKSIZE
26 # define THREAD_MINSTACKSIZE PTHREAD_STACK_MIN
27--
282.32.0
29