From 2cb92a3b5dc04f1e5d8859274c67f397190540e2 Mon Sep 17 00:00:00 2001 From: Martin Ecker Date: Thu, 18 Dec 2025 14:01:55 -0800 Subject: [PATCH] Also supply 'conf' for the current configuration when resolving a custom build step. In all cases sharpmake uses 'conf' as resolve parameter name when resolving sharpmake strings, all but in the case of custom build steps where 'config' is used instead. This seems like a simple oversight, so this change also adds 'conf' for consistency. --- Sharpmake.Generators/FastBuild/Bff.Util.cs | 1 + Sharpmake.Generators/VisualStudio/Vcxproj.cs | 1 + 2 files changed, 2 insertions(+) diff --git a/Sharpmake.Generators/FastBuild/Bff.Util.cs b/Sharpmake.Generators/FastBuild/Bff.Util.cs index a02173241..c6caa8c85 100644 --- a/Sharpmake.Generators/FastBuild/Bff.Util.cs +++ b/Sharpmake.Generators/FastBuild/Bff.Util.cs @@ -879,6 +879,7 @@ internal static void WriteConfigCustomBuildStepsAsGenericExecutable(string proje { using (bffGenerator.Resolver.NewScopedParameter("project", project)) using (bffGenerator.Resolver.NewScopedParameter("config", config)) + using (bffGenerator.Resolver.NewScopedParameter("conf", config)) using (bffGenerator.Resolver.NewScopedParameter("target", config.Target)) { foreach (var customBuildStep in config.CustomFileBuildSteps) diff --git a/Sharpmake.Generators/VisualStudio/Vcxproj.cs b/Sharpmake.Generators/VisualStudio/Vcxproj.cs index 39d239afa..3b40df274 100644 --- a/Sharpmake.Generators/VisualStudio/Vcxproj.cs +++ b/Sharpmake.Generators/VisualStudio/Vcxproj.cs @@ -1391,6 +1391,7 @@ IList skipFiles { using (fileGenerator.Resolver.NewScopedParameter("project", context.Project)) using (fileGenerator.Resolver.NewScopedParameter("config", config)) + using (fileGenerator.Resolver.NewScopedParameter("conf", config)) using (fileGenerator.Resolver.NewScopedParameter("target", config.Target)) { var customFileBuildSteps = CombineCustomFileBuildSteps(context.ProjectDirectory, fileGenerator.Resolver, config.CustomFileBuildSteps.Where(step => step.Filter != Project.Configuration.CustomFileBuildStep.ProjectFilter.BFFOnly));