简体   繁体   English

使用MSBuild for Build解决方案包括InstallShield ProjecT

[英]Using MSBuild for Build solution include InstallShield ProjecT

I'm doing a project in C #. 我正在用C#做一个项目。 In my solution I have an installsheld project that works very well when I compile directly from visual studio, I have a setup that is generated and is ready to be installed. 在我的解决方案中,我有一个installsheld项目,当我直接从Visual Studio进行编译时,它可以很好地工作,并且已经生成并准备好安装。

I would like for various reasons to be able to compile with command-line solution using MSBuild. 由于各种原因,我希望能够使用MSBuild编译命令行解决方案。 Everything works but my setup does not generate correctly despite any errors. 一切正常,但是即使有任何错误,我的设置也无法正确生成。

Below, the log when I compile the installshield project from visual studio: 下面是我从Visual Studio编译installshield项目时的日志:

Log InstallShield compile from visual studio 从Visual Studio编译Log InstallShield

With MSBuild : 使用MSBuild:

Log InstallShield compile from command line using MSBuild 使用MSBuild从命令行记录InstallShield编译

We notice that during the step Building File table, from visual studio we have the dependency of component 'RegieCiel.Primary_output', so we are good. 我们注意到在Visual Studio的构建文件表步骤中,我们具有组件'RegieCiel.Primary_output'的依赖关系,所以我们很好。 Since MSbuild, nothing is added .... 自从MSbuild以来,没有添加任何内容。

So what happens is that during the installation of the Setup, it lacks the dependencies. 因此,发生的情况是在安装安装程序期间缺少依赖项。

I first thought of a build order but it would work in both cases? 我首先想到了构建顺序,但在两种情况下都能正常工作吗?

What do you think ? 你怎么看 ?

I avoid project output references like the plague. 我避免像瘟疫这样的项目输出参考。 I suggest having an Application.sln and an Installer.sln. 我建议有一个Application.sln和Installer.sln。 Have your final projects in application.sln ( EXE, Web Projects ) do a postbuild xcopy or MSBuild publish profile and create a directory that models your deployed application. 将最终项目放在application.sln(EXE,Web Projects)中,进行postbuild xcopy或MSBuild发布配置文件,并创建一个用于对已部署的应用程序进行建模的目录。 From there use one Path Variable in InstallShield to point to all those files as static links. 从那里开始,在InstallShield中使用一个路径变量将所有这些文件指向为静态链接。 Also make sure you turn off all dependency scanning. 另外,请确保关闭所有依赖项扫描。 You want to be 100% in control of what does and doesn't go into your project. 您希望100%地控制项目中哪些内容和哪些内容不做。

I thank you for your answer and actually I think putting up does not place a solution "static" would solve the problem. 我感谢您的回答,实际上我认为提出并不能提出“静态”解决方案来解决问题。

However after a long search I finally found! 但是经过长时间的搜索,我终于找到了!

In my solution I had a package named "SlowCheetah" to manage several configuration files. 在我的解决方案中,我有一个名为“ SlowCheetah”的软件包来管理多个配置文件。 By uninstalling it, restart MSbuild, my Setup works perfectly! 通过卸载它,重新启动MSbuild,我的安装程序可以完美运行!

Thank you for your help ! 谢谢您的帮助 !

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 使用MSBuild通过InstallShield Pro Project生成Visual Studio解决方案时缺少DLL和自定义操作 - Missing DLL's and Custom Actions when using MSBuild to build Visual Studio Solution with InstallShield Pro Project 为什么我无法使用项目解决方案文件在 Msbuild Teamcity 中构建测试项目? - Why i cannot build the test project in Msbuild Teamcity using the project solution file? 如何使用 MSBuild 构建项目? - How to build project using MSBuild? 在Project.Build的程序中使用2013 msbuild - Using 2013 msbuild in program with Project.Build 使用C#代码中的msbuild构建Visual Studio解决方案 - Build visual studio solution using msbuild from c# code MSBuild无法解决具有项目依赖性的解决方案 - MSBuild fails for solution with project dependencies 如何使用 BuildManager 在 Visual Studio 2017 (MsBuild 15) 上构建 .Net Core 项目或解决方案 - How to use BuildManager to build .Net Core project or solution on Visual Studio 2017 (MsBuild 15) 从 msbuild 构建解决方案时未构建 Visual Studio 项目 - Visual Studio project not being built when I build Solution from msbuild 配置MSBuild以构建解决方案,并为每个项目将构建的dll放入一个目录,将外部库放入另一个目录 - Configure MSBuild to build a solution and for each project put the built dlls into one directory and external libraries into another Jenkins Freestyle build 中 MSbuild 中的解决方案路径出错 - Error with solution path in MSbuild in Jenkins Freestyle build
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM