INspire said:
Rather than have to learn this artificial concept of install/uninstall,
people could have learned how things work. Why complicate things?
It's not a complication. There are two aspects to writing a program
intended to be used by someone else:
1. Interaction with the user/world. The program should do what it
promises, be easy to use, have documentation etc.
2. Interaction with the system. The program should be a 'good citizen' -
register itself with the central program database, allow ways for other
programs to discover and interact with it, make sure all the programs
and libraries *it* depends on are present and discoverable, allow for
clean uninstallation, etc.
Aspect 1 is the 'meat' of the program, the bit that the developer will
have completed on his own machine before he thinks of releasing the
program to the world at large. Aspect 2 is where an installer comes in -
it involves things that are specific not so much to the program as to
the operating system, and which should therefore be handled in a manner
orthogonal to the actual program code.
To address some of the specific points raised:
1. Why can't you just unzip a program and run it?
There *are* some programs that are entirely standalone, but many of them
need registry keys and environment variables set, or provide support for
other applications, so that they need to be in the path and registry for
those applications to discover them.
Also, unless you want to manually navigate to the folder in which you
unzipped the program, things like start menu entries, desktop shortcuts
and PATH settings are very handy.
2. Why can't the user add all those himself?
It makes no sense to require the user to do manually something the
computer can do automatically. That's what computers are *for*.
3. But the security aspects?
Okay, so a sufficiently malicious installer can put all sorts of
spyware, adware, browser hijackers, trojans etc on your system. But so
can the program itself, and who does anything but click on the exe? Most
of them don't come with source anyway. No, having the user jump through
a few extra hoops merely creates a false sense of 'knowing what's going
on'. A better solution would be for installers to generate detailed logs
of what they're doing.
4. Okay, but why can't the program itself do all that? Why a separate
installer?
Again, interacting with the operating system should be cleanly separated
from the actual program tasks. Having every program reinvent the wheel
and have its own code to write to the reegistry, add itself to the path,
etc is extremely bad design, and creates far more problems than it
solves.
Oh, and anecdotal evidence for those of you muttering about clueless
newbies - most unix system administrators I know prefer installers. They
help keep the system in a consistent, maintainable state, and it's
easier to see what's installed, write scripts to update the system, and
uninstall packages cleanly if required.
martin