Showing results for 
Show  only  | Search instead for 
Did you mean: 
Intrepid explorer

Trouble with .isproj files and MSBuild

We have been successfully building a solution with VS 2013 integrated with InstallShield 2013 Premier. The solution contains a number of VB projects and 4 InstallScript MSI projects. Now we want to build with MSBuild in preparation for doing nightly builds. There are some files that appear in the VS build output that do not appear in the output of the MSBuild. These files are included in the bin folder of the VB project but do not get included in the Installer folders. I tried the following:
1. Compressed and uncompressed InstallShield release. That does seem to matter.
2. A Precompression Event in InstallShield. I am able to copy files to the proper folder with all the other files but they don't get included in the compressed Setup.exe (they just remain in the folder). The files don't get installed if you install from uncompressed output either. This method would be a bit of a kludge anyway.
3. Including the files as TaggedOutputs in the .isproj file. That does seem to matter.
4. Adding a ProjectReference in the .isproj file. That does seem to matter.

I notice that the build order is different between the 2 methods. I am not getting any errors... it's just that the content of the 2 builds does not match. What things typically need to be changed (in .isproj files) to use MSBuild? All ideas are greatly appreciated... ideas that work even more so! :)

Edit: The missing files are dependencies that are not added. For example, the following two lines appear in the log file of a build from VS but are missing in the log of a build from command line MSBuild:
Adding file 'Castnet.App.Core.Security.dll' that is a dependency of component 'SwitchingInterface.Primary_output'
Adding file 'Telerik.Web.UI.Skins.dll' that is a dependency of component 'SwitchingInterface.Primary_output'
There are many other dependencies that are properly included though.
Labels (1)
0 Kudos
2 Replies
Intrepid explorer

Re: Trouble with .isproj files and MSBuild

There may be a better solution, but here is what I am doing right now to resolve this:
Visual Studio Solution Explorer
Click on the appropriate InstallShield Project
Project Assistant
Application Files
Drill down to the folder that should contain the missing file(s)
Add Files (add missing files as needed)

I am using VS 2013 and InstallShield 2013 Premier
0 Kudos

Re: Trouble with .isproj files and MSBuild

Hi there,

There was an interesting forum discussion about continuous integration a few weeks ago.

I mentioned that I don't like the InstallShield integration in Visual Studio. Well, you have just found one of the reason why I don't like it.
The InstallShield integration in MSBuild is another thing, and it is working quite well.

Here is what I do:

  • I create my Installation project in InstallShield, and I make sure it builds correctly in InstallShield.
    The meaning of "correctly" here is up to you, but I would expect the have an complete installation package, that includes the prerequisites, and all the required dependencies.
    By the way, I handle most dependencies by hand in InstallShield, which sort of corresponds to what you described in your previous post. The difference is: You do in in VS, I do it in IS.
  • Then I create a separate VS solution and add my InstallShield project to this solution. This creates the ISPROJ file.
    One of the reason for isolating the Installation project in its own solution is: we only got a few InstallShield licenses for some developers, and quite a few InstallShield Standalone Build license for our build servers.
    Therefore, only the build servers and the developers with an InstallShield license build this solution.
  • I normally tweak this ISPROJ file a bit, mainly to override some path variables and some properties, like the ProductName and ProductVersion. In our build system, these properties are set in the Build definition in TFS.
  • I build this solution with MSBuild, and check that the results corresponds to what I built in InstallShield.
  • Once this is done, chances are that the central build of this solution works.

What I don't do is:

  • Edit or build my InstallShield project from Visual Studio.
    It means I cannot just refer the output of another project in Visual Studio, but after a few tests, I realized that the VS integration was changing my ISM file in unexpected ways.

To conclude: What counts is the build we create with MSBuild. I don't mind not building my Installation Package in Visual Studio.
The Build server does not normally use devenv.exe (aka Visual Studio) to build your package, it uses MSBuild.
0 Kudos