Search code examples
visual-studio-2010macrossetup-project

Why are there only 3 macros for Visual Studio setup projects?


I have created a sample project with an application and a library. I also have a Visual Studio (2010) setup project.

I want to execute a command post build in the setup project (file format of the project file is .vdproj). There are only 3 macro variables (BuiltOutputPath, ProjectDir, Configuration) ... I'm missing all the others I know from Visual C++ projects like SolutionDir etc.

Can I use them somehow in the setup project?


Solution

  • This is what I do to get around this: I create a dummy C++ project that doesn't do anything, and add the MSI postbuild script to that. Given all the macros available it's straightforward to navigate to the MSI build output ans run code or whatever.

    As to "why", I just suspect that postbuild stuff wasn't considered important to vdproj MSI builds.