Do not check if features named include_paths or preprocessor_defines
are enabled before setting the corresponding build variables for the
crosstool. Such a conditional is unnecessary.
RELNOTES: None.
@@ -256,19 +256,16 @@ public enum CompileBuildVariables {
// Module inputs will be set later when the action is executed.
buildVariables.addStringSequenceVariable(MODULE_FILES.getVariableName(), ImmutableSet.of());
}
- if (featureConfiguration.isEnabled(CppRuleClasses.INCLUDE_PATHS)) {
buildVariables.addStringSequenceVariable(INCLUDE_PATHS.getVariableName(), includeDirs);
buildVariables.addStringSequenceVariable(
QUOTE_INCLUDE_PATHS.getVariableName(), quoteIncludeDirs);
buildVariables.addStringSequenceVariable(
SYSTEM_INCLUDE_PATHS.getVariableName(), systemIncludeDirs);
- }
if (!includes.isEmpty()) {
buildVariables.addStringSequenceVariable(INCLUDES.getVariableName(), includes);
}
- if (featureConfiguration.isEnabled(CppRuleClasses.PREPROCESSOR_DEFINES)) {
Iterable<String> allDefines;
if (fdoStamp != null) {
// Stamp FDO builds with FDO subtype string
@@ -282,7 +279,6 @@ public enum CompileBuildVariables {
}
buildVariables.addStringSequenceVariable(PREPROCESSOR_DEFINES.getVariableName(), allDefines);
- }
if (usePic) {
if (!featureConfiguration.isEnabled(CppRuleClasses.PIC)) {
