From patchwork Sat Jul 6 11:51:31 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Marcus Haehnel X-Patchwork-Id: 1957585 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=kernkonzept.com header.i=@kernkonzept.com header.a=rsa-sha256 header.s=mx1 header.b=QaVXedeR; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=uclibc-ng.org (client-ip=2a00:1828:2000:679::23; helo=helium.openadk.org; envelope-from=devel-bounces@uclibc-ng.org; receiver=patchwork.ozlabs.org) Received: from helium.openadk.org (helium.openadk.org [IPv6:2a00:1828:2000:679::23]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4WGTHJ1rYdz1xql for ; Sat, 6 Jul 2024 21:51:06 +1000 (AEST) Received: from helium.openadk.org (localhost [IPv6:::1]) by helium.openadk.org (Postfix) with ESMTP id 1717235363BF; Sat, 6 Jul 2024 13:50:59 +0200 (CEST) Authentication-Results: helium.openadk.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=kernkonzept.com header.i=@kernkonzept.com header.a=rsa-sha256 header.s=mx1 header.b=QaVXedeR; dkim-atps=neutral Received: from mx.kernkonzept.com (serv1.kernkonzept.com [159.69.200.6]) by helium.openadk.org (Postfix) with ESMTPS id 0F1D035282A4 for ; Sat, 6 Jul 2024 13:50:51 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=kernkonzept.com; s=mx1; h=Content-Transfer-Encoding:Content-Type: MIME-Version:Message-ID:Date:Subject:Cc:To:From:References:In-Reply-To: Reply-To:Content-ID:Content-Description; bh=QD85uIsI/niuKjXf1CMV5O8pdm2ffZRQv40c/L3Vwq4=; b=QaVXedeRNHPNC3qpEAMkw2/iBk UJ7fB2zkji0JaG3XnNaO4hxt77W4J5BTKjk4s/ambRRZNmU1b624N7ud5LeNpzVEzxyHnYlP/1iVR qmw0bR7kPin+lIk5C4EtfvjTOFzCdru48bpbkE6WcllyTiB0t2xSZmNq5TkzK2sYeXSKR7QTtWty9 KfURu3NZOlSOOfJMUYXqU8+tqRYdxSFkgUax4gxVt02n0LXpffLtNec79xW3qyY3Qn40HFTHv1UNm KAqZDuqkO5aoO2lnrhu43twojvWq/WPS3Amq1zThNCnmOi02JGkWutk6sQjz2hMU781nBPI6f0oAn H81S0SXg==; Received: from dslb-092-072-034-079.092.072.pools.vodafone-ip.de ([92.72.34.79] helo=localhost.localdomain) by mx.kernkonzept.com with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.96) id 1sQ3wH-000QRM-2X; Sat, 06 Jul 2024 13:50:50 +0200 From: Marcus Haehnel To: devel@uclibc-ng.org Date: Sat, 6 Jul 2024 13:51:31 +0200 Message-ID: <20240706115143.24946-1-marcus.haehnel@kernkonzept.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 Message-ID-Hash: SD2CF5IQC5ABI3TYMKS6BPAETSWJRHYX X-Message-ID-Hash: SD2CF5IQC5ABI3TYMKS6BPAETSWJRHYX X-MailFrom: marcus.haehnel@kernkonzept.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: =?utf-8?q?Marcus_H=C3=A4hnel?= X-Mailman-Version: 3.3.3 Precedence: list Subject: [uclibc-ng-devel] [PATCH v2] Clang support for gnu_inline attribute List-Id: uClibc-ng Development Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Marcus Hähnel Clang also supports the gnu_inline attribute and the __GNUC_STDC_INLINE__ macro (C99 semantics). However, it reports as GCC 4.2 compatible (__GNUC_MINOR__ / __GNUC__) and thus the current defines do not think it can support this. Add clang as an alternative for this support. Documentation shows that this attribute is supported since at least Clang 8. --- include/sys/cdefs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/sys/cdefs.h b/include/sys/cdefs.h index 9b3a02177..656548c52 100644 --- a/include/sys/cdefs.h +++ b/include/sys/cdefs.h @@ -320,7 +320,7 @@ inline semantics, unless -fgnu89-inline is used. For -std=gnu99, forcing gnu_inline attribute does not change behavior, but may silence spurious warnings (such as in GCC 4.2). */ -#if !defined __cplusplus || __GNUC_PREREQ (4,3) +#if !defined __cplusplus || __GNUC_PREREQ (4,3) || __CLANG_PREREQ(8,0) # if defined __GNUC_STDC_INLINE__ || defined __GNUC_GNU_INLINE__ || defined __cplusplus # define __extern_inline extern __inline __attribute__ ((__gnu_inline__)) # if __GNUC_PREREQ (4,3)