5

There is a .NET application built using F# (the core part, as a DLL) and C# (the GUI part, using WPF). What is the best way to package it and to make an installer package and what are the most appropriate tools to use, commercial or free? It needs to include F# redistributable package in my application package and to check/download .NET framework needed.

As you guessed, I'm completely new to this Windows world.

Thanks in advance.

Kh

duros
  • 2,464
  • 1
  • 21
  • 25

4 Answers4

4

The easiest and the most flexible installer software I've used is Inno Setup These are the key features:

  • Check for the .NET Framework and install if not found
  • Check if Remote Registry is running and start if stopped.
  • Support for all versions of Windows in use today: 7, 2008 R2, Vista, XP, 2008, 2003, 2000, Me, 98, 95, and NT 4.0. (No service packs are required.)
  • Extensive support for installation of 64-bit applications on the 64-bit editions of Windows. Both the x64 and Itanium architectures are supported. (On the Itanium architecture, Service Pack 1 or later is required on Windows Server 2003 to install in 64-bit mode.)
  • Supports creation of a single EXE to install your program for easy online distribution. Disk spanning is also supported.
  • Standard Windows 2000/XP-style wizard interface.
  • Customizable setup types, e.g. Full, Minimal, Custom.
  • Complete uninstall capabilities.
  • Installation of files: Includes integrated support for "deflate", bzip2, and 7-Zip LZMA/LZMA2 file compression. The installer has the ability to compare file version info, replace in-use files, use shared file counting, register DLL/OCX's and type libraries, and install fonts.
  • Creation of shortcuts anywhere, including in the Start Menu and on the desktop.
  • Creation of registry and .INI entries.
  • Running other programs before, during or after install.
  • Support for multilingual installs, including right-to-left language support.
  • Support for passworded and encrypted installs.
  • Support for digitally signed installs and uninstalls.
  • Silent install and uninstall.
  • Unicode installs. (Windows 2000/XP or later)
  • Integrated preprocessor option for advanced compile-time customization.
  • Integrated Pascal scripting engine option for advanced run-time install and uninstall customization.

The best thing about it is that it provides full control to a developer. Here is a sample setup script.

Sorantis
  • 2,720
  • 17
  • 24
3

To build an installer I'd recommend using WiX, you should be able to pull in all the required redistributables, regardless of language.

WiX might look a bit harder than some of the more visual / integrated tools, but in the longer term it is much easier to maintain and can build your installers as part of a build processes if you use msbuild for example.

Steve
  • 5,264
  • 1
  • 21
  • 27
3

I've used NSIS to do complicated installs. It has its own domain specific language you will need to learn to use, but Eclipse has a plugin to help make it a lot easier. Essentially, you can embed any install package you want. You want to embed .Net for safekeeping? No problem. You want the F# redistributable? No problem. You want to conditionally install some parts and not others based on registry settings, files that have certain settings in them, etc.? No problem.

The only problem is that you have a new learning curve. NSIS creates .exe files, so you don't have to worry about the .msi runtime unless you are embedding an MSI file to install first.

Berin Loritsch
  • 45,784
  • 7
  • 87
  • 160
2

Since you are using Visual C# Express, you should be able to use ClickOnce. That would be the best bet as that should bundle everything for you. The only requirement is that you need to have a server (a web host should suffice).

Jetti
  • 5,163
  • 2
  • 26
  • 41
  • Does it allow to create MSI bundle with F# re-distributable package? :-/ – duros Apr 29 '11 at 16:32
  • @duros - I'm not 100% sure about the MSI (I can check when I get home tonight) but I know you can have it distribute the pre-requisites. See http://msdn.microsoft.com/en-us/library/8st7th1x(v=vs.80).aspx – Jetti Apr 29 '11 at 17:40
  • @Jetti. I created a clickonce package (not MSI) which checks (and downloads if needed) the required .NET framework. But I couldn't put f# re-distributable inside... Thank you. – duros Apr 29 '11 at 18:59
  • @duros - I'm sorry that I wasn't able to help you then :( – Jetti Apr 29 '11 at 20:26
  • I do have VS studio 2010, and soon will finish my first application made for public, how do you create an installer there? Is it much different? I have a SQL compact db and a word document in my solution. – Ziv May 04 '11 at 16:43
  • @Ziv - My link to ClickOnce should be able to help you out. – Jetti May 04 '11 at 17:41
  • Oh, how silly of me, I didn't even notice it was a link. *8) – Ziv May 04 '11 at 19:25