Add registration dialog to PackageMaker - macos

I'm currently in the process of writing a Mac PackageMaker-based installer for an application that I had previously distributed for Windows using an NSIS installer.
In NSIS, I was able to create a customized dialog that allowed the user to enter their serial number and license key before being allowed to install the program.
In PackageMaker, I can't really see anyway to add a custom dialog short of writing an little GUI app that is called by PackageMaker as a requirement. If this is the only way to do what I want, can anyone direct me to a resource that would explain how to do that?
If there is a another way, I'd also love to hear about that too.
(I know this question is similar but seems to deal more with editing the existing PackageMaker screens.)

PackageMaker supports plug-ins which can be added at any step of the installation. What you should do is write a plug-in which shows your license key prompt, and then load this plug-in at a step in the installation (say, the License step).
Here's an example of such a plug-in:
http://lists.apple.com/archives/Installer-dev/2008/Feb/msg00076.html
Personally, I'd recommend that you spare yourself the headache, and not use PackageMaker to make your Mac installer, but rather, an alternative tool, like Iceberg, and save yourself the trouble of tons of bugs.
If you insist on using PackageMaker, you should read this guide first to be ready for the many problems you may encounter:
(couldn't post this link because SO didn't let me, since I'm a first-time poster, but Google "PackageMaker workarounds" and it's the third result.

Apple's InstallerPluginSample sample code demonstrates how to add a registration pane to a PackageMaker-created installer.

I would recommend putting the license dialog in the application rather than in the installer. I haven't ever seen a Mac app that requests a license key during the install. They all do it when you launch the app.

Related

MSIX Installer and dependencies

I have a Windows App SDK based desktop application. I am using the single-project MSIX packaging in VS2022. What I need to figure out is how to get the installer to launch 3rd party installers (Nvidia Cuda for instance) as part of the application install. What should be pretty straight forward is lost in the weeds in the sparse documentation on MSIX. I also will eventually want to overlay multiple MSIX installs in one location. I am pretty sure I can't do this directly from Visual Studio but it seems possible using the MSIX Tool. Any pointers would be helpful.
While MSIX doesn't have install custom actions, for some things we can still customize some things at the user system.
Handling this externally from the package deployment is the recommended method. There may be other options, however.
With source code you can modify the app to detect if you need to do something and do it. If "it" needs elevation you need to add the allowelevationcapability in the manifest and there will be a UAC prompt for the user.
With or without source you can instead add the PsfLauncher of the Package support framework to run a script on launch of the app. PsfLauncher will take care of the detection on if run before for you. And the same elevation concerns apply.
As these methods run in the user context they really aren't any good if elevation is needed, hence not the recommended way.
Tim Mangan.
First of all, don't start using the MSIX Packaging Tool. As I said in previous SO threads, that tool is designed for IT pros, not for developers.
Second, as Tim concluded, I wouldn't recommend overcomplicating yourself to deliver those third-party installers via MSIX.
Instead of overcomplicating yourself with integrating the Package Support Framework into your MSIX package, I would think twice if it is worth deploying the application as MSIX. Last time I checked you could still get an identity for your app even if you deployed it with an MSI (I may be wrong here).
If you choose to keep the MSIX for your app, maybe a cleaner solution is to build an EXE wrapper (also called bootstrapper in the packaging world) over it to handle the third-party package installations, and when done with those it can launch your MSIX installation?
Unfortunately, so far Microsoft isn't making it easy for us to define a non-MSIX dependency.

Windows Logo clean uninstall

Anybody knows a way to cleanly uninstall a program that stores its settings on the per-user basis and installs for all users? I mean only the way to completely following the all Logo (Vista, 7, 8 - Server and Desktop) requirements.
I have found no way but installing a program on per-user basis, which in general can't be the solution.
Maybe leave some .cmd files in each user's home folder for cleaning-up application data?
The Logo requirements contains a lot of contradictions, and precisely following them seems to be impossible.
David Walker in his great comment to What do I do with per-user data when I uninstall? mentions:
Some users prefer that an uninstall would do a complete cleanup of all traces of a program.
Other users wish that a later reinstall would not force them to re-customize their settings.
These two wishes are incompatible.
Which one Microsoft recommends, actually, to pass all their Logo Certification tests? I mean all of them - from Vista to 8, both Server and Desktop.
Here's Raymond Chen's unofficial personal recommendation.
No. Let the data go.

NSIS automatic and silent update

I am currently building an application and want to have an installer and automatic silent updates for it.
Dropbox, Spotify and Chrome all are amazing at updating without anyone noticing. So I took a look at the Dropbox Roaming Folder in AppData and found a file named DropboxUpdateHelper.exe with an NSIS Icon. In the Spotify folder I could only find a SpotifyHelper.exe and a mentioning of NSIS in the Terms.
Is there a tutorial of how to install an application inside the Roaming Folder and have a silent auto updater? I am not fixed on NSIS but would prefer an open source and free installer.
NSIS has the INetC plugin that can be used to download things from the internet but I don't know if there is an auto update tutorial out there. You might also want to take a look at the VPatch plugin...
There are many variables to think about here:
Should your main application look for updates or just run the updater on application (or windows) startup so it can check?
Are the files on the server signed or do you have other ways to detect invalid/corrupted/MitM updates?
Do you require access control/DRM before downloading/applying updates?
How will you handle major version number updates? Will you support more than one major version or force upgrades?
Do you require administrator rights to update? UAC handling?
How are you going to support upgrading from 1.0 to 1.2? Update to 1.1 first or support every possible minor version upgrade path?
I'm sure there are many other issues you also have to think about. You should probably try to answer all these questions before you start coding. During development you might find other questions or that you have to change the design completely.
IMHO, this is not a simple question and I don't think you will be able to find a drop-in solution that fits your exact design/requirements...
It is easy to download files from internet using NSIS (there are several plug-ins for this purpose: NSISdl, InetC, ...) but such functionality is more about coding.
There is no exact solution for this - as Anders said you need to specify every detail to achieve required behaviour.

Windows installer to install browser-extensions

I'm trying to create an installer for windows (and potentially mac) that can install a browser extension for chrome, firefox, and for IE, and I'm totally stuck. Primarily I live in web-development land and I don't even really know where to start. This installer might eventually also include something like a bing toolbar for a kickback to us on a per-install basis. I'm hoping for something that doesn't require us to learn how to author a windows installer, but if that is unavoidable what are some good services / apps we could use?
Any help, would be GREATLY appreciated.
Firefox: https://developer.mozilla.org/en/Adding_Extensions_using_the_Windows_Registry
Chrome: http://code.google.com/chrome/extensions/external_extensions.html#registry
The WiX toolkit and community may be a good place to start wrt IE.
I presume that you are imagining something like LastPass's installer
For Windows there is probably not much you can do to avoid using Windows Installer, therefore I recommend that you take a look at Wix, which is an open source toolset from Microsoft for generating installers that will shield you from a lot of problems.
I don't have any first hand experience with installing browser plugins but I am guessing that installing your plugins isn't all that different from installing a regular program - you need to place a bunch of files and set some registry keys and so on. What registry keys and so on should be documented by the browser developer (and you probably already know this since you have done your plugins).
Unfortunately, I cannot help you when it comes to the Mac.

Auto-answer questions for a GUI install program?

During the install process, we are trying to install a third-party program along with our 'main' program that we install. This third party application is very important (and can't be skipped).
The problem comes in here: the third-party program asks MANY questions when installing on Windows 7, and the user needs to know which are the 'correct' answers. We've contacted the vendor and have never gotten a response (yes! We'll pay!). We don't think a manual will help (who reads that?). And, it's against our licensing to repackage their application into our Installer.
Theirs is a custom installer app, so nothing you've heard of - not INNO Setup or Installshield.
It's too late in the project to change vendors for this app, so what are my options? Is there a program that we can run that will 'auto-answer' the questions this installer asks?
Sounds like something sikuli might be able to solve. But regardless of your solution, you'll still have to distribute the program answering the installer along with the installer. Or you can package them all up in another installer.

Resources