diff --git a/Source/CPack/cmCPackGenerator.h b/Source/CPack/cmCPackGenerator.h index 5354fca08d..57b8fff382 100644 --- a/Source/CPack/cmCPackGenerator.h +++ b/Source/CPack/cmCPackGenerator.h @@ -13,7 +13,6 @@ #include "cmCPackComponentGroup.h" #include "cmSystemTools.h" -class cmCPackGenerator; class cmCPackLog; class cmInstalledFile; class cmMakefile; diff --git a/Source/cmBuildNameCommand.cxx b/Source/cmBuildNameCommand.cxx index 12b69a8538..93e5ca2763 100644 --- a/Source/cmBuildNameCommand.cxx +++ b/Source/cmBuildNameCommand.cxx @@ -6,7 +6,6 @@ #include #include "cmMakefile.h" -#include "cmPolicies.h" #include "cmStateTypes.h" #include "cmSystemTools.h" diff --git a/Source/cmCTest.h b/Source/cmCTest.h index 4d334585f4..ebdc8b0b41 100644 --- a/Source/cmCTest.h +++ b/Source/cmCTest.h @@ -14,7 +14,6 @@ #include #include -class cmCTest; class cmCTestGenericHandler; class cmCTestStartCommand; class cmGeneratedFileStream; diff --git a/Source/cmCommands.cxx b/Source/cmCommands.cxx index b58dc627c7..1576722baf 100644 --- a/Source/cmCommands.cxx +++ b/Source/cmCommands.cxx @@ -1,6 +1,7 @@ /* Distributed under the OSI-approved BSD 3-Clause License. See accompanying file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmCommands.h" +#include "cmPolicies.h" #include "cmState.h" #include "cmAddCustomCommandCommand.h" diff --git a/Source/cmCoreTryCompile.cxx b/Source/cmCoreTryCompile.cxx index ff9ffc04e7..fd9d04b307 100644 --- a/Source/cmCoreTryCompile.cxx +++ b/Source/cmCoreTryCompile.cxx @@ -8,6 +8,7 @@ #include #include #include +#include #include "cmAlgorithms.h" #include "cmExportTryCompileFileGenerator.h" diff --git a/Source/cmExportLibraryDependenciesCommand.cxx b/Source/cmExportLibraryDependenciesCommand.cxx index e3fb412a8f..deecad84e5 100644 --- a/Source/cmExportLibraryDependenciesCommand.cxx +++ b/Source/cmExportLibraryDependenciesCommand.cxx @@ -9,7 +9,6 @@ #include "cmGeneratedFileStream.h" #include "cmGlobalGenerator.h" #include "cmMakefile.h" -#include "cmPolicies.h" #include "cmStateTypes.h" #include "cmSystemTools.h" #include "cmTarget.h" diff --git a/Source/cmLinkLineDeviceComputer.cxx b/Source/cmLinkLineDeviceComputer.cxx index 6a700ff151..6789555d55 100644 --- a/Source/cmLinkLineDeviceComputer.cxx +++ b/Source/cmLinkLineDeviceComputer.cxx @@ -2,10 +2,18 @@ file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmLinkLineDeviceComputer.h" + +#include +#include +#include + #include "cmComputeLinkInformation.h" #include "cmGeneratorTarget.h" #include "cmGlobalNinjaGenerator.h" -#include "cmOutputConverter.h" +#include "cmStateDirectory.h" +#include "cmStateTypes.h" + +class cmOutputConverter; cmLinkLineDeviceComputer::cmLinkLineDeviceComputer( cmOutputConverter* outputConverter, cmStateDirectory stateDir) diff --git a/Source/cmLinkLineDeviceComputer.h b/Source/cmLinkLineDeviceComputer.h index f4bb3ebfb1..f275a0dead 100644 --- a/Source/cmLinkLineDeviceComputer.h +++ b/Source/cmLinkLineDeviceComputer.h @@ -4,8 +4,17 @@ #ifndef cmLinkLineDeviceComputer_h #define cmLinkLineDeviceComputer_h +#include + +#include + #include "cmLinkLineComputer.h" + +class cmComputeLinkInformation; +class cmGeneratorTarget; class cmGlobalNinjaGenerator; +class cmOutputConverter; +class cmStateDirectory; class cmLinkLineDeviceComputer : public cmLinkLineComputer { diff --git a/Source/cmLoadCommandCommand.cxx b/Source/cmLoadCommandCommand.cxx index 39e5684c6f..5cf185347e 100644 --- a/Source/cmLoadCommandCommand.cxx +++ b/Source/cmLoadCommandCommand.cxx @@ -2,22 +2,21 @@ file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmLoadCommandCommand.h" -#include "cmCPluginAPI.cxx" -#include "cmCPluginAPI.h" -#include "cmDynamicLoader.h" -#include "cmMakefile.h" -#include "cmPolicies.h" -#include "cmState.h" -#include "cmSystemTools.h" - -class cmExecutionStatus; - #include #include #include #include #include +#include "cmCPluginAPI.cxx" +#include "cmCPluginAPI.h" +#include "cmDynamicLoader.h" +#include "cmMakefile.h" +#include "cmState.h" +#include "cmSystemTools.h" + +class cmExecutionStatus; + #ifdef __QNX__ #include /* for malloc/free on QNX */ #endif diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx index 44c390c141..07d712c0a3 100644 --- a/Source/cmLocalGenerator.cxx +++ b/Source/cmLocalGenerator.cxx @@ -13,7 +13,6 @@ #include "cmInstallScriptGenerator.h" #include "cmInstallTargetGenerator.h" #include "cmLinkLineComputer.h" -#include "cmLinkLineDeviceComputer.h" #include "cmMakefile.h" #include "cmRulePlaceholderExpander.h" #include "cmSourceFile.h" diff --git a/Source/cmMakefileExecutableTargetGenerator.cxx b/Source/cmMakefileExecutableTargetGenerator.cxx index b76ddeb5aa..8ed50517fc 100644 --- a/Source/cmMakefileExecutableTargetGenerator.cxx +++ b/Source/cmMakefileExecutableTargetGenerator.cxx @@ -2,6 +2,7 @@ file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmMakefileExecutableTargetGenerator.h" +#include #include #include #include diff --git a/Source/cmMakefileExecutableTargetGenerator.h b/Source/cmMakefileExecutableTargetGenerator.h index 642182b675..598ac3dd22 100644 --- a/Source/cmMakefileExecutableTargetGenerator.h +++ b/Source/cmMakefileExecutableTargetGenerator.h @@ -5,6 +5,8 @@ #include +#include + #include "cmMakefileTargetGenerator.h" class cmGeneratorTarget; diff --git a/Source/cmMakefileLibraryTargetGenerator.cxx b/Source/cmMakefileLibraryTargetGenerator.cxx index ff8b604a41..bc456cf255 100644 --- a/Source/cmMakefileLibraryTargetGenerator.cxx +++ b/Source/cmMakefileLibraryTargetGenerator.cxx @@ -2,8 +2,7 @@ file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmMakefileLibraryTargetGenerator.h" -#include // IWYU pragma: keep - +#include #include #include diff --git a/Source/cmOutputRequiredFilesCommand.cxx b/Source/cmOutputRequiredFilesCommand.cxx index f1209716cb..3db0fec5dd 100644 --- a/Source/cmOutputRequiredFilesCommand.cxx +++ b/Source/cmOutputRequiredFilesCommand.cxx @@ -10,7 +10,6 @@ #include "cmAlgorithms.h" #include "cmGeneratorExpression.h" #include "cmMakefile.h" -#include "cmPolicies.h" #include "cmSourceFile.h" #include "cmSystemTools.h" #include "cmTarget.h" diff --git a/Source/cmQtAutoGenerators.cxx b/Source/cmQtAutoGenerators.cxx index 1d6972b8e1..32dd547bd1 100644 --- a/Source/cmQtAutoGenerators.cxx +++ b/Source/cmQtAutoGenerators.cxx @@ -14,6 +14,7 @@ #include #include "cmAlgorithms.h" +#include "cmFilePathChecksum.h" #include "cmGlobalGenerator.h" #include "cmMakefile.h" #include "cmOutputConverter.h" diff --git a/Source/cmSourceGroupCommand.cxx b/Source/cmSourceGroupCommand.cxx index 5555199088..631f2a6834 100644 --- a/Source/cmSourceGroupCommand.cxx +++ b/Source/cmSourceGroupCommand.cxx @@ -2,7 +2,9 @@ file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmSourceGroupCommand.h" +#include #include +#include #include "cmMakefile.h" #include "cmSourceGroup.h" diff --git a/Source/cmSubdirDependsCommand.cxx b/Source/cmSubdirDependsCommand.cxx index 36e84d51e8..0bb2c0ac49 100644 --- a/Source/cmSubdirDependsCommand.cxx +++ b/Source/cmSubdirDependsCommand.cxx @@ -2,8 +2,6 @@ file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmSubdirDependsCommand.h" -#include "cmPolicies.h" - class cmExecutionStatus; bool cmSubdirDependsCommand::InitialPass(std::vector const&, diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx index 9efc13b14f..87fe4401e9 100644 --- a/Source/cmSystemTools.cxx +++ b/Source/cmSystemTools.cxx @@ -45,6 +45,7 @@ #include #include #include +#include #if defined(_WIN32) #include diff --git a/Source/cmUseMangledMesaCommand.cxx b/Source/cmUseMangledMesaCommand.cxx index 3d57f0e0ba..8ef095890c 100644 --- a/Source/cmUseMangledMesaCommand.cxx +++ b/Source/cmUseMangledMesaCommand.cxx @@ -5,7 +5,6 @@ #include #include -#include "cmPolicies.h" #include "cmSystemTools.h" class cmExecutionStatus; diff --git a/Source/cmUtilitySourceCommand.cxx b/Source/cmUtilitySourceCommand.cxx index 9b24a74ebd..37d8bfb3bf 100644 --- a/Source/cmUtilitySourceCommand.cxx +++ b/Source/cmUtilitySourceCommand.cxx @@ -5,7 +5,6 @@ #include #include "cmMakefile.h" -#include "cmPolicies.h" #include "cmState.h" #include "cmStateTypes.h" #include "cmSystemTools.h" diff --git a/Source/cmVariableRequiresCommand.cxx b/Source/cmVariableRequiresCommand.cxx index bff6ec528c..10b0a88509 100644 --- a/Source/cmVariableRequiresCommand.cxx +++ b/Source/cmVariableRequiresCommand.cxx @@ -3,7 +3,6 @@ #include "cmVariableRequiresCommand.h" #include "cmMakefile.h" -#include "cmPolicies.h" #include "cmState.h" #include "cmSystemTools.h"