Bruce Evans wrote: > On Sat, 12 Jul 2003, Tim Kientzle wrote: >>In particular, newvers.sh is being run with the >>current directory being ${.OBJDIR}, and ${.OBJDIR} >>doesn't contain a Makefile, ... > > ... `make -V FOO' doesn't require a Makefile in -current. ... A-HA! >>I don't know the "right" way to fix this ... > > I think splitting it or making it exit after just setting variables > in the userland case is the right fix. ... I think you're right, but don't see a very simple way to make that work, especially given the surprising number of places that newvers.sh is used. However, the following one-line patch does work; it simply creates enough of a Makefile to silence make's warnings. Needs testing under -CURRENT, but I'm pretty confident it will work there as well. If someone could test this under -CURRENT and commit it, those of us doing 4.x->CURRENT cross-builds would greatly appreciate it. Tim Index: include/Makefile =================================================================== RCS file: /usr/cvs/FreeBSD-CVS/src/include/Makefile,v retrieving revision 1.204 diff -u -r1.204 Makefile --- include/Makefile 4 Jul 2003 19:54:06 -0000 1.204 +++ include/Makefile 13 Jul 2003 05:43:33 -0000 _at__at_ -51,11 +51,17 _at__at_ INCS+= osreldate.h +# The use of 'newvers.sh' here is kind of bogus, because +# it creates some additional files and does a few other odd +# things. The 'touch Makefile' here allows newvers.sh to +# run on 4.x, whose 'make' requires a Makefile for '-V KERN_IDENT' +# osreldate.h: ${.CURDIR}/../sys/conf/newvers.sh \ ${.CURDIR}/../sys/sys/param.h \ ${.CURDIR}/Makefile _at_${ECHO} creating osreldate.h from newvers.sh _at_setvar PARAMFILE ${.CURDIR}/../sys/sys/param.h; \ + echo default: > Makefile; \ . ${.CURDIR}/../sys/conf/newvers.sh; \ echo "$$COPYRIGHT" > osreldate.h; \ echo "#ifdef _KERNEL" >> osreldate.h; \Received on Sun Jul 13 2003 - 06:32:43 UTC
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:14 UTC