extra/ntp to 4.2.8.p15-2

This commit is contained in:
Kevin Mihelich 2022-11-05 02:30:31 +00:00
parent 093bacddad
commit 46ce3b8c77
2 changed files with 32 additions and 1 deletions

View file

@ -9,7 +9,7 @@ pkgname=ntp
_pkgname=ntp #-dev
_pkgver=4.2.8p15
pkgver=${_pkgver/p/.p}
pkgrel=1
pkgrel=2
pkgdesc='Network Time Protocol reference implementation'
url='http://www.ntp.org/'
license=('custom')
@ -17,12 +17,14 @@ arch=('x86_64')
depends=('openssl' 'perl' 'libcap' 'libedit')
backup=('etc/ntp.conf')
source=("https://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/${_pkgname}-${_pkgver}.tar.gz"
'ntp-4.2.8_p15-glibc-2.34.patch'
'0001-disable-pthread-warmup-on-ARM.patch'
'ntp.conf'
'ntpd.service'
'ntpdate.service'
'ntp.sysusers')
sha1sums=('e34e5b6f48c3ed1bbcfb03080dec1b8f91e19381'
'1423b8ef72a3806ed74affc1973f66ed7cfa2afb'
'ec9bd3894b65edca8efdb34ce12b3eb144336294'
'ad1d6ee2e9aca64a84a7224c88bf6008ac6c69e1'
'0cccca872385e0142888ab48d273fec0669b30a8'
@ -33,6 +35,7 @@ options=('!emptydirs')
prepare() {
cd "${srcdir}/${_pkgname}-${_pkgver}"
patch -Np1 -i ../ntp-4.2.8_p15-glibc-2.34.patch
patch -p1 -i ../0001-disable-pthread-warmup-on-ARM.patch
}

View file

@ -0,0 +1,28 @@
https://bugs.gentoo.org/806358
https://patchwork.openembedded.org/patch/180019/
From: Khem Raj <raj.khem@gmail.com>
Date: Sat, 31 Jul 2021 10:51:41 -0700
Subject: [PATCH] libntp: Do not use PTHREAD_STACK_MIN on glibc
In glibc 2.34+ PTHREAD_STACK_MIN is not a compile-time constant which
could mean different stack sizes at runtime on different architectures
and it also causes compile failure. Default glibc thread stack size
or 64Kb set by ntp should be good in glibc these days.
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
--- a/libntp/work_thread.c
+++ b/libntp/work_thread.c
@@ -41,7 +41,7 @@
#ifndef THREAD_MINSTACKSIZE
# define THREAD_MINSTACKSIZE (64U * 1024)
#endif
-#ifndef __sun
+#if !defined(__sun) && !defined(__GLIBC__)
#if defined(PTHREAD_STACK_MIN) && THREAD_MINSTACKSIZE < PTHREAD_STACK_MIN
# undef THREAD_MINSTACKSIZE
# define THREAD_MINSTACKSIZE PTHREAD_STACK_MIN
--
2.32.0