From patchwork Fri Feb 4 16:47:28 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Tremer X-Patchwork-Id: 5059 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4Jr1gd07BLz3xff for ; Fri, 4 Feb 2022 16:48:13 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4Jr1gM6dbMz5G1; Fri, 4 Feb 2022 16:47:59 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4Jr1gM3vGbz32MJ; Fri, 4 Feb 2022 16:47:59 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4Jr1gJ5zBxz315y for ; Fri, 4 Feb 2022 16:47:56 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4Jr1gJ57YGz80; Fri, 4 Feb 2022 16:47:56 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1643993276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=htGP2HYLWFU1auDY16REgB9rS8U7SIdbkmwh54EfkeY=; b=zrcDkYf55QUS3AaSEPfkZ7+wFVP7mKYmGcfD9jbapzXJ4SOKDRFXtzd18dV08mY+wlcBdG T/RMzmbbHe+5vgBw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1643993276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=htGP2HYLWFU1auDY16REgB9rS8U7SIdbkmwh54EfkeY=; b=IKfUfF7kwEEFVlwFi50CYmrgw7zf/1ZDQTtswozsR2vqxENV1t2+Gh8t3H0jVTiYTZTJG9 7GiVMHw/timEuZD/7zctaggwei2E1oE+igIoPChRgESY/rLeYnClosBQysWVAI670YZ9Ak bPx20hIEf2gKOJpL4EeOBcnzlWB/TKPVkDYNTn88f6LTVDJYeSu+NFx2/SlY0pYTDkRbXm iIfc/LqUnq5I6CeplHE2TT93NxcNZ2tDoH5NKx3XY+mce2a8xkKAN0WcCppHUzX0HLXeMp sniIiPFxgFWnmkMWIS2wWQoyzJwwHbVyhGSrKHPWAvo78TgOhur36hbRcKY6iw== From: Michael Tremer To: development@lists.ipfire.org Subject: [PATCH 08/28] ntp: Fix FTBFS with glibc 2.34 Date: Fri, 4 Feb 2022 16:47:28 +0000 Message-Id: <20220204164748.315559-8-michael.tremer@ipfire.org> In-Reply-To: <20220204164748.315559-1-michael.tremer@ipfire.org> References: <20220204164748.315559-1-michael.tremer@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Michael Tremer Errors-To: development-bounces@lists.ipfire.org Sender: "Development" Signed-off-by: Michael Tremer --- lfs/ntp | 1 + ...tp-4.2.8p15-build-fix-for-glibc-2.34.patch | 29 +++++++++++++++++++ 2 files changed, 30 insertions(+) create mode 100644 src/patches/ntp-4.2.8p15-build-fix-for-glibc-2.34.patch diff --git a/lfs/ntp b/lfs/ntp index ca46e5163..e039d7bdd 100644 --- a/lfs/ntp +++ b/lfs/ntp @@ -70,6 +70,7 @@ $(subst %,%_MD5,$(objects)) : $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) @$(PREBUILD) @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar zxf $(DIR_DL)/$(DL_FILE) + cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/ntp-4.2.8p15-build-fix-for-glibc-2.34.patch $(UPDATE_AUTOMAKE) cd $(DIR_APP) && \ ./configure \ diff --git a/src/patches/ntp-4.2.8p15-build-fix-for-glibc-2.34.patch b/src/patches/ntp-4.2.8p15-build-fix-for-glibc-2.34.patch new file mode 100644 index 000000000..442fe7828 --- /dev/null +++ b/src/patches/ntp-4.2.8p15-build-fix-for-glibc-2.34.patch @@ -0,0 +1,29 @@ +From 082a504cfcc046c3d8adaae1164268bc94e5108a Mon Sep 17 00:00:00 2001 +From: Khem Raj +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 +--- + libntp/work_thread.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) +diff --git a/libntp/work_thread.c b/libntp/work_thread.c +index 03a5647..3ddd751 100644 +--- 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 +