From: "Jarkko Sakkinen" <jarkko@kernel.org>
To: "Mirsad Todorovac" <mtodorovac69@gmail.com>,
<linux-kselftest@vger.kernel.org>
Cc: "Dave Hansen" <dave.hansen@linux.intel.com>,
"Shuah Khan" <shuah@kernel.org>, <linux-sgx@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, "Edward Liaw" <edliaw@google.com>
Subject: Re: [PATCH v1 1/1] selftests/sgx: Fix the implicit declaration of asprintf() compiler error
Date: Mon, 13 May 2024 01:48:09 +0300 [thread overview]
Message-ID: <D18164GGOJ2P.UC10KNQCPM6Y@kernel.org> (raw)
In-Reply-To: <656c3b4a-0481-4634-9dd4-19bb9e4cd612@gmail.com>
On Fri May 10, 2024 at 11:37 PM EEST, Mirsad Todorovac wrote:
> tools/testing/selftests/sgx/main.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/tools/testing/selftests/sgx/main.c b/tools/testing/selftests/sgx/main.c
> index 9820b3809c69..f5cb426bd797 100644
> --- a/tools/testing/selftests/sgx/main.c
> +++ b/tools/testing/selftests/sgx/main.c
> @@ -6,6 +6,9 @@
> #include <errno.h>
> #include <fcntl.h>
> #include <stdbool.h>
> +#ifndef __USE_GNU
> +#define __USE_GNU
> +#endif
> #include <stdio.h>
> #include <stdint.h>
> #include <stdlib.h>
__USE_GNU is an internal define, never use it for anything.
Use #define _GNU_SOURCE instead without ifndef/endif [1].
[1] https://man7.org/linux/man-pages/man3/asprintf.3.html
BR, Jarkko
next prev parent reply other threads:[~2024-05-12 22:48 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-10 20:37 [PATCH v1 1/1] selftests/sgx: Fix the implicit declaration of asprintf() compiler error Mirsad Todorovac
2024-05-10 20:52 ` John Hubbard
2024-05-10 21:02 ` Mirsad Todorovac
2024-05-12 23:02 ` Jarkko Sakkinen
2024-05-13 9:43 ` Mirsad Todorovac
2024-05-13 11:20 ` Jarkko Sakkinen
2024-05-12 22:58 ` Jarkko Sakkinen
2024-05-12 22:48 ` Jarkko Sakkinen [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-05-10 20:46 Mirsad Todorovac
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=D18164GGOJ2P.UC10KNQCPM6Y@kernel.org \
--to=jarkko@kernel.org \
--cc=dave.hansen@linux.intel.com \
--cc=edliaw@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=linux-sgx@vger.kernel.org \
--cc=mtodorovac69@gmail.com \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).