EXE 和 MSI 之间的最佳方法

发布于 2024-11-10 17:27:29 字数 103 浏览 4 评论 0原文

我有一个需要作为包交付的应用程序。

  1. EXE 和 MSI 安装程序中最好的是什么,为什么?
  2. 有没有开源工具可以反编译EXE或MSI?

I have an application that needs to be delivered as a package.

  1. What are the best among EXE and MSI Installers, and why?
  2. Is there any open source tool to decompile the EXE or MSI?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(6

万劫不复 2024-11-17 17:27:32

如今,许多安装程序在内部使用 MSI,尽管它们以 EXE 形式分发。您需要一个 EXE 来确保安装所有先决条件:例如 .NET Framework;如果没有,它会安装先决条件。然后它会提取 MSI 包来处理其余的安装。

MSI 提供了一些高级安装功能:

  • 回滚支持:如果安装过程中出现故障,它会将系统返回到安装开始之前的状态。
  • 修复:如果您的应用程序停止正常运行,用户可以使用此功能重新安装应用程序。它可以恢复丢失的文件、注册表项。
  • 更新/升级:MSI 处理应用程序更新/升级。当用户开始安装新版本时,MSI 包可以自动配置为应用程序的先前版本。这对用户来说是透明的:看起来好像只安装了新版本。
  • 补丁:MSI 支持补丁。当您的应用程序仅修改了几个文件时,您可以使用补丁包(MSP)来更新它们。补丁将小于完整包。
  • 广告快捷方式:您可以允许用户不安装应用程序的某些功能,除非使用它们。当用户访问此类功能时,MSI 会安装必要的文件。

虽然学习技术需要一些时间。


您可以从 EXE 文件执行任何操作,而 MSI 仅用于安装。 Inno SetupNSIS 安装包以 exe 文件形式分发。他们有一种描述安装步骤的脚本语言。


WiX 工具集 具有名为 黑暗

Many installers these days use MSI internally although they're distributed as EXE. You need an EXE to ensure all the prerequisites are installed: .NET framework, for example; and it installs the prerequisites if they're not. Then it extracts the MSI package which handles the rest of the installation.

MSI provides some advanced install features:

  • rollback support: if something failed during installation, it returns the system to the state before installation started.
  • repair: if your application stopped functioning correctly, users can use this feature to reinstall the application. It restores missing files, registry entries.
  • updates/upgrades: MSI handles application updates/upgrades. MSI package can be configured to automatically the previous version of the application when user starts installation of a newer version. This happens transparently to user: it looks as if only the new version is installed.
  • patches: MSI supports patches. When only several files of your application are modified, you can update them using a patch package (MSP). The patch will be smaller than the full package.
  • advertised shortcuts: you can allow users to not install some features of your application unless they're used. When users access such a feature, MSI installs the necessary files.

Though it takes some time to learn the technology.


You can do anything from an EXE file, while MSI is for installation only. Inno Setup and NSIS installation packages are distributed as exe files. They have a scripting language which describes installation steps.


WiX toolset has MSI decompiler called dark.

成熟的代价 2024-11-17 17:27:32

我在 serverfault.com 上发布了一些 MSI 优点(和问题)的摘要:

https://serverfault .com/questions/11670/advantages-of-using-msi-files

I posted a summary of some MSI benefits (and problems) on serverfault.com:

https://serverfault.com/questions/11670/advantages-of-using-msi-files

静若繁花 2024-11-17 17:27:32

MSI 是一个 Microsoft 安装程序,它比旧的 EXE 更新,Wise Installer 和许多其他程序都支持它。它允许更智能地安装需要部署的内容(例如 CAB 文件和注册表设置等),并且可以检查以前的安装等。MSI

仅用于安装,而 EXE 可以执行其他操作,例如运行。

我会使用 InstallShield 并构建一个

我不确定 #2 的MSI

MSI is a Microsoft Installer, it is newer than the older EXE , Wise Installer and many others support it. It allows for a smarter install with what needs to be deployed (like CAB files, and registry settings etc...) and it can check for previous installs etc..

MSI are ONLY installations, while EXE can do other things like run.

I would use InstallShield and build an MSI

I'm unsure about #2

凯凯我们等你回来 2024-11-17 17:27:32

您可以直接告诉 Visual Studio 将您的应用程序制作成 MSI/EXE。如果这有效并且达到了你想要的效果,那就这么做吧。创建安装程序需要您付出很大的努力。

MSI 表示您正在使用 Microsoft 的安装程序。 Microsoft 有正当理由推荐(即不向您的应用程序提供认证)MSI。然而,一个好的 MSI 很难产生,所以我不推荐它,除非您需要您的应用程序经过认证。

如果您不需要认证,我推荐 Inno Setup,以及像 < a href="http://sourceforge.net/projects/istool/" rel="nofollow">ISTool。它易于使用,并为您提供简单的界面来执行最常见的安装程序任务。在紧要关头,它支持脚本,允许您执行它不支持的任何操作。

You can just tell Visual Studio to make your application into an MSI/EXE. If that works and does what you want, just do that. It much effort on your part creating an installer.

MSI means you are using Microsoft's Installer. Microsoft has legitimate reasons for recommending (i.e., not giving your application Certification) MSI. However, a good MSI is tough to produce, so I don't recommend it unless you need your application to be certified.

If you don't require certification, I recommend Inno Setup, along with a front-end like ISTool. It's easy to use and gives you simple interfaces to perform most common installer tasks. In a pinch, it supports scripting to allow you to do anything it doesn't support.

伴梦长久 2024-11-17 17:27:31

这取决于你所说的 EXE 类型。

MSI 是由 Windows Installer 运行的安装包。如果您使用 Visual Studio 创建安装项目,它将为您提供 MSI 和 EXE。 EXE 在这种情况下只是一个引导程序(MSI 或 EXE)。检查 Windows Installer 是否就位后,它将运行 MSI。

如果您使用 InnoSetup 等其他工具,则此 EXE 本身就是一个安装包,而不是引导程序。

关于您关于 MSI 编辑器的问题:Orca MSI 编辑器

如果不需要非常复杂的安装程序,我建议使用 Visual Studio 安装项目,因为它很简单,但足够强大。

It depends on what kind of EXE you are talking about.

MSI is setup package that is run by Windows Installer. If you make setup project with Visual Studio it will provide both MSI and EXE for you. EXE in this case just a bootstrapper (MSI or EXE). It will run MSI after checks that Windows Installer is in place.

If you use other tools like InnoSetup, this EXE is a setup package itself, not a bootstrapper.

Regarding to your question about MSI editor: Orca MSI Editor.

If don't need need very complicated installer, I suggest using Visual Studio setup project as it is simple, yet powerful enough.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文