Monday, September 22, 2008 4:59 AMHi,
I could learn that vdproj files cannot be build by msbuild. Is there a way that I can build .msi packages by msbuild? or any command to build vdproj files? (other than devenv.com )
Wednesday, September 24, 2008 8:12 AMI have multiple vdproj projects in my solution. I could build them one by one, using the following target.
<Exec Command='"devenv.com" Installer1.vdproj /build "$(BuildType)"'/>
<Exec Command='"devenv.com" Installer2.vdproj /build "$(BuildType)"'/>
<Exec Command='"devenv.com" Installer3.vdproj /build "$(BuildType)"'/>
I know this is not a good way of doing it, since it makes the same project gets built multiple times. So, Is there a better way?
Wednesday, September 24, 2008 11:34 AM
Setup projects (.vdproj) do not have a project system format that can be understood by MSBuild. Hence MSBuild cannot build these projects directl. However, we can use the devenv /build command to build the vdproj files and generate MSI installers. I don’t think that your BuildInstallers target will build the vdproj project multi times. Did you mean the referred project will be build many times?
For more information, please check:
Wednesday, September 24, 2008 7:19 PMWhat I ended up doing was creating a .cmd file that runs msbuild. The msbuild creates all of my click once files.
The .cmd file gets run in the prebuild event of the setup project. Then, a vbs script runs which zips all of my click once files into a zip file. When solution builds it grabs this zip file and puts it into the msi. When the msi installs another vbs expands the zip files and puts my click once files on the server.
Thursday, September 25, 2008 3:45 AMYes, The referred projects will be build multiple times.
Friday, September 26, 2008 12:43 PM
I don’t think that the referred projects will be build multiple times. When the .vdproj is being built, it will force the referred project to be built, however, the build process will check if the output of the referred project is up-to-date, if it is up-to-date, the build process will skip quickly. If you want build all the .vdproj in your solution, I suggest you build the whole solution with devenv.
However, the recommended way is to convert from .vdproj to WiX format. WiX is fully buildable by MSBuild without VS installed. And it is more powerful than .vdproj. For more information about Wix, please check the following page: