From 4b3b8e4ad436df173c9ecdf8279ccaa3a6d41201 Mon Sep 17 00:00:00 2001 From: Simon Marchi Date: Tue, 22 Oct 2019 11:16:58 -0400 Subject: [PATCH] lib: remove includes from logging.h MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Nothing in logging.h uses anything from those includes. Removing them causes this failure in py-common.c: CC py-common.lo In file included from /home/smarchi/src/babeltrace/src/py-common/py-common.c:32:0: /home/smarchi/src/babeltrace/src/py-common/py-common.h:44:18: error: unknown type name ‘bool’; did you mean ‘_Bool’? int log_level, bool chain); ^~~~ _Bool Doing this change revealed a few files that were using bool without including stdbool.h, add the includes there. Change-Id: Ica802312a21c2a28cfaa1011d0034f0d1f65594e Signed-off-by: Simon Marchi Reviewed-on: https://review.lttng.org/c/babeltrace/+/2241 Tested-by: jenkins Reviewed-by: Francis Deslauriers --- include/babeltrace2/logging.h | 4 ---- src/cli/babeltrace2-plugins.c | 1 + src/plugins/common/param-validation/param-validation.h | 1 + src/py-common/py-common.h | 1 + 4 files changed, 3 insertions(+), 4 deletions(-) diff --git a/include/babeltrace2/logging.h b/include/babeltrace2/logging.h index ae03d8d1..37143e19 100644 --- a/include/babeltrace2/logging.h +++ b/include/babeltrace2/logging.h @@ -27,10 +27,6 @@ # error "Please include instead." #endif -#include -#include -#include - #ifdef __cplusplus extern "C" { #endif diff --git a/src/cli/babeltrace2-plugins.c b/src/cli/babeltrace2-plugins.c index 0093d4ce..42cda686 100644 --- a/src/cli/babeltrace2-plugins.c +++ b/src/cli/babeltrace2-plugins.c @@ -27,6 +27,7 @@ #include "babeltrace2-plugins.h" +#include #include /* Array of bt_plugin * */ diff --git a/src/plugins/common/param-validation/param-validation.h b/src/plugins/common/param-validation/param-validation.h index a78f997b..3113ff4d 100644 --- a/src/plugins/common/param-validation/param-validation.h +++ b/src/plugins/common/param-validation/param-validation.h @@ -25,6 +25,7 @@ #include #include +#include #include /* For __MINGW_PRINTF_FORMAT. */ diff --git a/src/py-common/py-common.h b/src/py-common/py-common.h index 27a3a619..6622438a 100644 --- a/src/py-common/py-common.h +++ b/src/py-common/py-common.h @@ -27,6 +27,7 @@ #include #include +#include #include "common/macros.h" -- 2.34.1