[lttng-tools] Fix: Add missing pthread.h include
Commit Message
Some libc like musl and uClibc requires explicit includes of pthread.h
Signed-off-by: Michael Jeanson <mjeanson at efficios.com>
---
src/common/defaults.h | 1 +
1 file changed, 1 insertion(+)
Comments
This should be backported to stable-2.9.
On 2016-12-05 15:39, Michael Jeanson wrote:
> Some libc like musl and uClibc requires explicit includes of pthread.h
>
> Signed-off-by: Michael Jeanson <mjeanson at efficios.com>
> ---
> src/common/defaults.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/src/common/defaults.h b/src/common/defaults.h
> index 27f1ddc..37d222a 100644
> --- a/src/common/defaults.h
> +++ b/src/common/defaults.h
> @@ -20,6 +20,7 @@
> #ifndef _DEFAULTS_H
> #define _DEFAULTS_H
>
> +#include <pthread.h>
> #include <src/common/macros.h>
>
> /* Default unix group name for tracing. */
>
Hello,
On Mon, 5 Dec 2016 15:39:26 -0500, Michael Jeanson wrote:
> Some libc like musl and uClibc requires explicit includes of pthread.h
>
> Signed-off-by: Michael Jeanson <mjeanson at efficios.com>
Tested-by: Thomas Petazzoni <thomas.petazzoni at free-electrons.com>
This is indeed needed to fix the build on musl, I've integrated your
patch in Buildroot for the time being.
Thanks!
Thomas
Merged, thanks!
Jérémie
On 5 December 2016 at 15:39, Michael Jeanson <mjeanson at efficios.com> wrote:
> Some libc like musl and uClibc requires explicit includes of pthread.h
>
> Signed-off-by: Michael Jeanson <mjeanson at efficios.com>
> ---
> src/common/defaults.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/src/common/defaults.h b/src/common/defaults.h
> index 27f1ddc..37d222a 100644
> --- a/src/common/defaults.h
> +++ b/src/common/defaults.h
> @@ -20,6 +20,7 @@
> #ifndef _DEFAULTS_H
> #define _DEFAULTS_H
>
> +#include <pthread.h>
> #include <src/common/macros.h>
>
> /* Default unix group name for tracing. */
> --
> 2.7.4
>
@@ -20,6 +20,7 @@
#ifndef _DEFAULTS_H
#define _DEFAULTS_H
+#include <pthread.h>
#include <src/common/macros.h>
/* Default unix group name for tracing. */