Visual Studio Installer,在安装时编译 [英] Visual Studio Installer, compile on install

查看:111
本文介绍了Visual Studio Installer,在安装时编译的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想为一个控制台应用程序创建一个安装,该应用程序要求一个应用程序密钥,然后编译一个控制台应用程序,并将应用程序密钥编译到生成的exe中。我从未使用过Visual Studio Installer项目,因此我不知道从哪里开始或者是否可以完成?



Visual Studio 2010



任何帮助表示感谢。

解决方案

它可以,是的 - 每次安装.NET框架都包含C#编译器(csc ,。exe)所以不需要额外的软件。



这是个好主意吗?可能不是,因为这意味着您的安装需要包含要编译的源代码,这意味着它可能以某种形式提供给您的所有客户......这可能比不实施粗略形式的DRM更大的安全风险这个! :笑:

I would like to create an install for a console application that asks for an application key then compiles a console application with the application key compiled into the resulting exe. I have never used a Visual Studio Installer project so I don't know where to start or if it can be done??

Visual Studio 2010

Any help appreciated.

解决方案

It can, yes - every installation of the .NET framework includes the C# Compiler (csc,.exe) so no additional software should be needed.

Is it a good idea? Probably not, as it means that your installation needs to include the source code to compile, which means it may be available in some form to all your clients...which could be a bigger security risk than not implementing a rough form of DRM like this! :laugh:


这篇关于Visual Studio Installer,在安装时编译的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆