From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1791) id 9883038582AE; Wed, 7 Feb 2024 14:04:50 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 9883038582AE DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1707314690; bh=6RL7aywbMwkDGxflBzIqmvRiLZDtYVwXvF3qnZyjXBg=; h=From:To:Subject:Date:From; b=ZfKcJ178MR8k1PHTFBNU5PXa4IQTFcOvKUodhZc4Iu09eMPws1GrlVxrXfClstlHQ +nG6vH1Xh+gkYxWMKnVdNuh/FyjO6Yb0xv7l8blM6lP2713Mi9fRJW2F1matjfBn1k 5w7iB89ij+rq36Xt2k5WGnwGGenY+Lc24MC9NvF8= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Adhemerval Zanella To: glibc-cvs@sourceware.org Subject: [glibc/azanella/clang] posix: Suppress clang confstr -Wignored-attributes X-Act-Checkin: glibc X-Git-Author: Adhemerval Zanella X-Git-Refname: refs/heads/azanella/clang X-Git-Oldrev: db114ef23abe1ca9901a062c2f72f194f88f3564 X-Git-Newrev: 3fb62fb1b5a2a98c9a1d59ff4d38359622ba1a5a Message-Id: <20240207140450.9883038582AE@sourceware.org> Date: Wed, 7 Feb 2024 14:04:50 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=3fb62fb1b5a2a98c9a1d59ff4d38359622ba1a5a commit 3fb62fb1b5a2a98c9a1d59ff4d38359622ba1a5a Author: Adhemerval Zanella Date: Wed Aug 24 12:13:27 2022 -0300 posix: Suppress clang confstr -Wignored-attributes clang warns that alias will be always resolve to _GI___confstr even if weak definition of __GI_confstr is overridden, which is really the intention. Diff: --- posix/confstr.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/posix/confstr.c b/posix/confstr.c index a13a134bf9..099b1b8bb4 100644 --- a/posix/confstr.c +++ b/posix/confstr.c @@ -21,6 +21,7 @@ #include #include #include "../version.h" +#include #define NEED_SPEC_ARRAY 0 #include @@ -290,5 +291,10 @@ __confstr (int name, char *buf, size_t len) return string_len; } libc_hidden_def (__confstr) +/* clang warns that alias will be always resolve to _GI___confstr even if weak + definition of __GI_confstr is overridden, which is really the intention. */ +DIAG_PUSH_NEEDS_COMMENT_CLANG; +DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wignored-attributes"); libc_hidden_def (confstr) +DIAG_POP_NEEDS_COMMENT_CLANG; weak_alias (__confstr, confstr)