Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 02 Feb 1996 14:44:24 +0800
From:      Peter Wemm <peter@jhome.DIALix.COM>
To:        Bruce Evans <bde@zeta.org.au>
Cc:        jdp@polstra.com, CVS-committers@FreeBSD.org, cvs-lib@FreeBSD.org, nate@sri.MT.net
Subject:   Re: cvs commit: src/lib/csu/i386 crt0.c 
Message-ID:  <199602020644.OAA18603@jhome.DIALix.COM>
In-Reply-To: Your message of "Fri, 02 Feb 1996 13:57:55 %2B1100." <199602020257.NAA23300@godzilla.zeta.org.au> 

next in thread | previous in thread | raw e-mail | index | archive | help
>>> >> I think this will solve the problem...
>>> >
>>> >I think it will, too.  But, why do you want to solve the problem by
>>> >adding 4 lines to the Makefile, when you could solve it instead by
>>> >removing 2 lines??
>>> 
>>> The only thing I was wondering about was if anything in "lib" had
>>> c++t0.o linked into it...  It doesn't look like it, but it nearly was
>>> a while ago...
>
>>Anyway, now I agree that we should use your solution in the top-level
>>Makefile, and not mine.
>
>I prefer John's solution together with fixing what it breaks.
>
>csu is built first to incorrectly fix `make world -DCLOBBER'.  See the
>log for rev.1.28.  The problem was that -DCLOBBER blows away the used
>library file crt0.o although it preserves the used library files
>`*.s[ao].*'.  If DESTDIR isn't set, then building and installing crt0.o
>early results in the build utilities being linked with the _new_ crt0.o
>and the _old_ shared libraries (or the link failing if someone sets
>NOSHARED globally).

IMHO, the "safest" thing to do is ensure that we do all the compiling of the
utility programs to generate library code first, before we even touch
anything in /usr/lib or /usr/include.  ie: (cd lib ; make depend) before
doing the CLOBBER in the libraries target.

Yes, we should take out the special step for csu/i386 and fix the "CLOBBER"
option so that it leaves c*rt*.o alone as well.

>Better quick fixes for this problem include:
>- don't remove any library files.  Little would be lost, because the
>  critical shared libraries aren't removed, so links that should fail
>  because the appropriate new library hasn't been installed may bogusly
>  succeed using an old shared library, and garbage shared libraries
>  aren't removed, so -DCLOBBER's main purpose of removing junk is
>  half defeated.
>- don't remove any library files if ${DESTDIR}==""; otherwise remove
>  all library files.
>- remove all library files except those required to link and run the
>  build utilities.
>
>Bruce

-DCLOBBER doesn't seem very useful to me...  We dont clean out any old
junk from /usr/bin or /usr/sbin for example.  -DCLOBBER should
be rm -rf ${DESTDIR} - but that's probably a bit brutal. :-) :-)

Cheers,
-Peter



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199602020644.OAA18603>