Subject: Re: Build error (Re: CVS commit: src) (fwd)
To: Bill Studenmund <skippy@macro.Stanford.EDU>
From: Skeelo <skeelo@white-dwarf.dyn.ml.org>
List: current-users
Date: 11/02/1998 18:46:39
I was infact using a DESTDIR, and I've made a few changes to my local
/src/Makefile that could use some input. Let me know if these
changes look decent. They should work fine, I've used these changes to
build gnu/usr.bin/gcc/common. Thanks.
Patch follows...
*** /usr/src/Makefile Mon Oct 19 07:04:35 1998
--- /usr/src/Makefile.destdir Thu Oct 29 09:43:44 1998
***************
*** 4,9 ****
--- 4,13 ----
HAVE_GCC28!= ${CXX} --version | egrep "^(2\.8|egcs)" ; echo
+ .if defined(DESTDIR)
+ MOPTS+= -m ${.CURDIR}/share/mk
+ .endif
+
# NOTE THAT etc *DOES NOT* BELONG IN THE LIST BELOW
SUBDIR+= lib include bin libexec sbin usr.bin usr.sbin share sys
***************
*** 20,25 ****
--- 24,31 ----
SUBDIR+= domestic
.endif
+ MAKE+= ${MOPTS}
+
.if exists(regress)
.ifmake !(install)
SUBDIR+= regress
***************
*** 47,57 ****
.endif
build: beforeinstall
! .if !defined(NOSHARE)
(cd ${.CURDIR}/share/mk && ${MAKE} install)
(cd ${.CURDIR}/share/tmac && ${MAKE} && ${MAKE} install)
.endif
.if !defined(UPDATE)
${MAKE} cleandir
.endif
.if defined(USE_EGCS) && empty(HAVE_GCC28)
--- 53,63 ----
.endif
build: beforeinstall
! .if !defined(NOSHARE) || defined(DESTDIR)
(cd ${.CURDIR}/share/mk && ${MAKE} install)
(cd ${.CURDIR}/share/tmac && ${MAKE} && ${MAKE} install)
.endif
.if !defined(UPDATE)
${MAKE} cleandir
.endif
.if defined(USE_EGCS) && empty(HAVE_GCC28)
On Mon, 26 Oct 1998, Bill Studenmund wrote:
> I sent this messge to Skeelo, but decided to send it to the list so others
> won't get bitten by this problem.
>
> > depend ===> gnu/usr.bin/gcc
> > depend ===> gnu/usr.bin/gcc/common
> > yacc -d -b bi-parser bi-parser.y
> > mv bi-parser.tab.c bi-parser.c
> > mv bi-parser.tab.h bi-parser.h
> > cc -I/usr/sup/current/src/gnu/usr.bin/gcc/common -I/usr/sup/current/src/gnu/usr.bin/gcc/common/../arch -I/usr/sup/current/src/gnu/usr.bin/gcc/common/../arch/m68k -I/usr/sup/current/src/gnu/usr.bin/gcc/common -nostdinc -idirafter /current/usr/include -
> > o bi-arity bi-arity.lo bi-parser.lo bi-lexer.lo bi-reverse.lo obstack.lo
> > cc: bi-arity.lo: No such file or directory
> > cc: bi-parser.lo: No such file or directory
> > cc: bi-lexer.lo: No such file or directory
> > cc: bi-reverse.lo: No such file or directory
> > cc: obstack.lo: No such file or directory
> > cc: No input files
>
> Try doing a make -m /src/share/mk for your build.
>
> To test things out, cd directly to gcc/common and try "make depend -m
> /src/share/mk"
>
> This patch takes advantage of changes to the make system made just before
> it was committed, namely rules on how to make .lo files.
>
> Added for current-users: I've tested the make -m solution on my system.
> With old make files, I get Skeelo's error. With adding the -m, all works
> well.
>
> I'm puzzled as Skeelo doesn't seem to be using a DESTDIR (AFAICT from the
> post), and one of the first things make build does is install new make
> files. ??
>
> Take care,
>
> Bill
>