简体   繁体   中英

why no output when use command line to build VS setup project?

I have installed Visual Studio 2008 on our build machine because we want to build the setup project to create MSI installer for our C# application.

From IDE, it works fine. The installer is created as expected.

Switch to command line, with the follow command the process finished without any error but there is no output (no installer created)

DevEnv.exe .\\SystemSoftwareInstaller\\SystemSoftwareInstaller.vdproj /build Debug /Out "debugErr.txt"

change the /build to /deploy to /rebuild have no difference (no installer created)

I am doing anything wrong?

I just fought with a similar issue, where I'd run the devenv.exe and get no feedback and no output, even with the /Log flag. This is the exact same call I'd use in 2005, and it worked like a charm. But then I found a devenv.com in the same folder, so I tried that, and it ran as expected. I don't know the difference between the .com and .exe versions, but you might try that.

I think the problem is that you are running DevEnv.exe and not DevEnv.com.

This should output to the console.

DevEnv .\\SystemSoftwareInstaller\\SystemSoftwareInstaller.vdproj /build Debug /Out "debugErr.txt"

Try building the solution file instead of the vdproj file in your command line statement

There must be at least one project in the solution that form the output of the installer project. These will need to be built as well.

Interesting question. I thought this would be pretty easy as well. I was able to easily do a release build by opening a VS2008 command prompt in the folder with my vdproj and running:

devenv SomeName.vdproj /build

But release was a lot trickier. After a few failed attempts on my own, this guy showed the way. For some reason, the fully qualified path to the sln and the vdproj seemed to do the trick (again I was in a VS2008 command prompt but this time I was in the SLN folder):

devenv "C:\\SomePath\\SomeSlnName.sln" /rebuild Debug /project "C:\\SomePath\\ProjectFolder\\SomeProjectName.vdproj" /projectconfig Debug

It doesn't make sense to create an installer for the Debug build, you always want the Release build.

If that's really necessary then open the .vdproj in Visual Studio, Build + Configuration Manager and tick the Build checkbox for the Debug configuration. Beware that this property is stored in the .sln file, not the .vdproj file so click File + Save All to let VS write the solution file.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM