Skip to content
This repository was archived by the owner on Nov 8, 2023. It is now read-only.

Commit 18c18b1

Browse files
tobluxkees
authored andcommitted
gcc-plugins: Remove duplicate included header file stringpool.h
The header file stringpool.h is included for GCC version >= 8 and then again for all versions. Since the header file stringpool.h was added in GCC 4.9 and the kernel currently requires GCC 5.1 as a minimum, remove the conditional include. Including the header file only once removes the following warning reported by make includecheck: stringpool.h is included more than once However, it's important to include stringpool.h before attribs.h because attribs.h uses some of its functions. Compile-tested with GCC 14. Signed-off-by: Thorsten Blum <thorsten.blum@toblux.com> Link: https://lore.kernel.org/r/20240629233608.278028-2-thorsten.blum@toblux.com Signed-off-by: Kees Cook <kees@kernel.org>
1 parent ef40d28 commit 18c18b1

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

scripts/gcc-plugins/gcc-common.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -62,11 +62,7 @@
6262
#include "pass_manager.h"
6363
#include "predict.h"
6464
#include "ipa-utils.h"
65-
66-
#if BUILDING_GCC_VERSION >= 8000
6765
#include "stringpool.h"
68-
#endif
69-
7066
#include "attribs.h"
7167
#include "varasm.h"
7268
#include "stor-layout.h"
@@ -78,7 +74,6 @@
7874
#include "context.h"
7975
#include "tree-ssa-alias.h"
8076
#include "tree-ssa.h"
81-
#include "stringpool.h"
8277
#if BUILDING_GCC_VERSION >= 7000
8378
#include "tree-vrp.h"
8479
#endif

0 commit comments

Comments
 (0)