user3309953
user3309953

Reputation: 171

Building InstallShield project with Multiple Product configuration using MSBuild command line

I have created InstallShield Basic MSI project from Visual Studio (IS 2012 Spring, VS 2010). My InstallShield project having 2 product configurations and each configuration having one release. Product Configuration 1 Release 1 Product Configuration 2 Release 2

For building project in VS IDE, I need to set the corresponding product configuration as 'Default Product Configuration' and build. This is working fine. The Default configuration release is getting build.

But, how can we achieve this in MSBuild command line?

I need to build both configuration separately using MSBuild command line (without changing Default configuration through IDE).

Could anyone please share the proper way to build IS project in MSBuild command line?

Thanks, Saravanan

Upvotes: 0

Views: 512

Answers (1)

Leo Liu
Leo Liu

Reputation: 76910

how can we achieve this in MSBuild command line?

You can use Properties in the MSBuild command line:

msbuild test.sln /t:project /p:Configuration="Release" /p:Platform="x86" /p:BuildProjectReferences=false

You can also build multiple projects at once:

msbuild test.sln /t:project;project2 /p:Configuration="Release" /p:Platform="x86" /p:BuildProjectReferences=false

Note:

  • what is assigned to /t is the project name in the solution, it can be different from the project file name.
  • One important note: if your project has a '.' in the name, you'll need to replace it with a '_' when specifying it with /t

Upvotes: 1

Related Questions