Software installation opinions needed

David Emery emery at linus.mitre.org
Thu Sep 20 03:17:15 AEST 1990


Here's another do/don't do:

     I get VERY UPSET by 3rd party installations that must be done as
'root'.  An installation script should NOT require that it be run by the
superuser to do mundane things such as get the stuff off the tape,
build its directory structure, etc.  It should be MY decision what
userid owns the software, and to run the installation using an userid
other than root.  Besides, in this era of viruses, etc, who knows what
an installation script is doing to your system?

     Generally there is a little bit of installation that must be run
as root, to install things in places like /usr/bin, and /usr/lib.  The
right approach (in my opinion) is to provide these scripts separately,
and also provide an alternate approach.  

     For instance, suppose you have a tool called "munger", and it
needs a file called "munge_lib".  The default installation procedures
would be to install "munger" in /usr/bin and "munge_lib" in /usr/lib.
However, if I want, it should be OK for me to install "munger" in its
own directory /usr/munge, and put the "munge_lib" file in
/usr/munge/lib.  The tool should provide a way to determine the
location of "munge_lib".  Two approaches are
	1.  environment variable
	2.  enclosing the tool in a shellscript and modifying the
shellscript at installation time.

     So, what I think should happen is that the installation script
should look something like the following (intented lines result from
answering 'n'):
	Install executable into /usr/bin (y/n)? 
		Enter the path for the executable: 
	Install library into /usr/lib (y/n)?
		Enter the path for the library:
	Perform installation now (y/n)?
		OK, not performing installation.  Writing
		installation commands to the file "./install.me".
		You may need to be the superuser to execute "./install.me".

     I've installed several Ada compilers on a Sun.  The best
installation script is Verdix, which requires root access ONLY to edit
a file in /etc.  However, you do have to add the path to
<compiler-directory>/bin to your path.  The script edits its internal
files to load path information.  Alsys requires you to log in as root,
and does a lot of messing around in /usr/bin and /usr/lib.  I tried to
run the installation using our 3rd party software account (which is
NOT root), and had lots of problems.  Finally I had to tear apart the
script and do it by hand.  I've had to do similar things with other
3rd party tools, but not with Verdix.

				dave emery
				emery at aries.mitre.org



More information about the Comp.unix.admin mailing list