lkml.org 
[lkml]   [2023]   [Jan]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] perf: Add missing sys/types.h include
Em Wed, Jan 04, 2023 at 10:23:13AM -0800, Jesus Sanchez-Palencia escreveu:
> Not all libc implementations define ssize_t as part of stdio.h like
> glibc does since the standard only requires this type to be defined by
> unistd.h and sys/types.h. For this reason the perf build is currently
> broken for toolchains based on uClibc, for instance.
>
> Include sys/types.h explicitly to fix that. This is a follow up to
> commit 378ef0f5d9d7 ("perf build: Use libtraceevent from the system").

Do you mean this problem started with the 378ef0f5d9d7 commit? If so
then this is the fase for adding:

Fixes: 378ef0f5d9d7 ("perf build: Use libtraceevent from the system")

To this patch, ok?

- Arnaldo

> Signed-off-by: Jesus Sanchez-Palencia <jesussanp@google.com>
> ---
> tools/perf/util/trace-event.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/tools/perf/util/trace-event.h b/tools/perf/util/trace-event.h
> index add6c5d9531c..9b3cd79cca12 100644
> --- a/tools/perf/util/trace-event.h
> +++ b/tools/perf/util/trace-event.h
> @@ -4,6 +4,7 @@
>
> #include <stdbool.h>
> #include <stdio.h>
> +#include <sys/types.h>
> #include <linux/types.h>
>
> struct evlist;
> --
> 2.39.0.314.g84b9a713c41-goog

--

- Arnaldo

\
 
 \ /
  Last update: 2023-03-26 23:27    [W:0.037 / U:0.620 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site