Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Sep 1997 22:57:18 +0800
From:      Peter Wemm <peter@netplex.com.au>
To:        Stephen McKay <syssgm@dtir.qld.gov.au>
Cc:        Bruce Evans <bde@zeta.org.au>, freebsd-stable@FreeBSD.ORG, peter@FreeBSD.ORG
Subject:   Re: No-go with read-only src tree 
Message-ID:  <199709221457.WAA25252@spinner.netplex.com.au>
In-Reply-To: Your message of "Tue, 23 Sep 1997 00:05:32 %2B1000." <199709221405.AAA17411@troll.dtir.qld.gov.au> 

next in thread | previous in thread | raw e-mail | index | archive | help
Stephen McKay wrote:
> On Monday, 22nd September 1997, Bruce Evans wrote:
> 
> >>If this fixes all my problems, -DNOLIB will go.  If not, I'll have to add a
> >>little extra cruft to specifically rebuild the lex/lib obj directory.
> >>
> >>If you know why there was a -DNOLIB there in the first place, speak up!
> >
> >See the revision log.
> 
> I see you haven't become unnecessarily verbose, or succumbed to the temptatio
    n
> to spoon feed people. :-)
> 
> Yes, I came to my senses shortly after posting, and read the log:
> 
> >revision 1.6
> >date: 1996/08/07 13:25:59;  author: peter;  state: Exp;  lines: +3 -2
> >Move tsort back to lib-tools where it belongs, and add a "specially
> >for bootstrap" tweak to the lex Makefile to stop it building the library
> >too early.
> >
> >This untangles things a bit more, it stops new bootstraps failing because
> >libl/libfl uses 'ld -O' before ld is updated.
> 
> So, if we still care about 'make world' bootstrapping from 2.1.x, which
> I expect we do, then the -DNOLIB has to stay.  I'll have to tweak around
> it since without -DNOLIB my compile breezed past the usual trouble spot
> to die messily with:
> 
>     /usr/src/lib/libc/i386/DEFS.h: No such file or directory
> 
> But we know all about that one already.  I'm thinking of adding a warning
> early in the build process.  Just idle thinking. :-)
> 
> Peter, if you have any insight you want to pass on, please chime in here.

``Urk''.

Perhaps change:
        cd ${.CURDIR}/usr.bin/lex && ${MAKE} bootstrap && ${MAKE} depend && \
                ${MAKE} ${MK_FLAGS} -DNOLIB all install ${CLEANDIR} ${OBJDIR}
To something like:
        cd ${.CURDIR}/usr.bin/lex && ${MAKE} bootstrap && ${MAKE} depend && \
                ${MAKE} ${MK_FLAGS} -DNOLIB all install ${CLEANDIR}
.if !defined(NOOBJDIR)
	cd ${.CURDIR}/usr.bin/lex && ${MAKE} obj
.endif

Or even:
        cd ${.CURDIR}/usr.bin/lex && ${MAKE} bootstrap && ${MAKE} depend && \
                ${MAKE} ${MK_FLAGS} -DNOLIB all install clean cleandepend

One of those might do it.  Otherwise, taking out the -DNOLIB makes lex 
descend into it's library, which causes ld -O to be used, and ld hasn't 
been built yet.  (And, incidently, ld in binutils-2.8 uses lex during the 
build :-]   /home/src/contrib/binutils/ld/ldlex.l )

> Stephen.

Cheers,
-Peter





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