Subject: Re: avoiding install death
To: None <current-users@NetBSD.ORG>
From: der Mouse <mouse@collatz.mcrcim.mcgill.edu>
List: current-users
Date: 02/03/1996 06:29:43
>> Isn't this what mtree is for ?
> Perhaps. It would be useful then if the top level Makefile used it.
You haven't looked recently, have you? /usr/src/Makefile says
beforeinstall:
.ifndef DESTDIR
(cd ${.CURDIR}/etc && ${MAKE} DESTDIR=/ distrib-dirs)
.endif
which causes etc/Makefile to do an mtree run.
Unfortunately, it uses 4.4BSD.dist as the mtree driving file, which
causes it to create things that are fine for a distribution system but
which are gratuitous and often unwanted clutter for "make install". I
have a PR (#1956) open on this; I solved it by changing Makefile to
make install-dirs isntead of distrib-dirs, and then having etc/Makefile
take that to run mtree with mtree/installdirs instead of
mtree/4.4BSD.dist; mtree/installdirs is then a copy of 4.4BSD.dist with
the unnecessary junk removed and some directory modes fixed to match
what "make install" sets them to, so that I don't get mtree whining and
"fixing" the modes every time 'cause the make install changed them
after mtree "fixed" them.
> Personally I prefer my approach as it is more generally useful.
Matter of opinion. I usually prefer that make install just install
things, without trying to be smart about creating directories where it
thinks things should go. In particular, I would _really_ hate it if it
gets an incorrect idea of where I want to install things and goes wild
making directories all over my filesystem as a result.
der Mouse
mouse@collatz.mcrcim.mcgill.edu