Date: Wed, 15 Aug 2001 09:54:24 +0300 From: Ruslan Ermilov <ru@FreeBSD.ORG> To: Bruce Evans <bde@zeta.org.au> Cc: current@FreeBSD.ORG, Mark Peek <mark@whistle.com>, Warner Losh <imp@harmony.village.org> Subject: Re: Cross builds and upgrade path from 4.x are broken in usr.bin/file Message-ID: <20010815095424.A47417@sunbay.com> In-Reply-To: <20010815120844.C17139-100000@besplex.bde.org>; from bde@zeta.org.au on Wed, Aug 15, 2001 at 12:40:19PM %2B1000 References: <20010814203045.A60765@sunbay.com> <20010815120844.C17139-100000@besplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Aug 15, 2001 at 12:40:19PM +1000, Bruce Evans wrote: [...] > > > +mkmagic: apprentice.c print-hacked.c > > > + ${HOST_CC} -o mkmagic -DHAVE_CONFIG_H -DCOMPILE_ONLY \ > > > + -I${.CURDIR} -I${SRCDIR} ${.ALLSRC} > > > > > Whoa, cool! > > > > That's what I wanted from the very beginning (-DCOMPILE_ONLY knob). > > It then fits just nicely into the `build-tools' concept. And we > > don't need this ugly HOST_CC hack for Makefile.inc1, as ${CC} is > > set correctly during the `build-tools' stage. Let's don't reinvent > > the wheel, and please try the attached patch instead. > > I agree (except the build-tools concept is a hack to work around > build-tools binaries not being buildable and installable in the usual > way (with 1 binary per Makefile)). > It seems pretty easy to add src/tools/build-tools/, and move all the build-tools there. What do you say? [...] > See sh/Makefile for other tweaks (depend on .o instead of .c ...). Other > probems with this (generally shared with all build-tools binaries): > - CFLAGS for the main binary may be inappropriate for the tools > - missing dependencies on headers. > Dependency of a build-tool on .o instead of .c is bad if: 1) build-tools are built in the same ${.OBJDIR} as the main ${PROG} (this is always true) 2) objects for a build-tool are created for the host arch 3) objects for a ${PROG} are created for a different arch 4) ${PROG} and build-tool share one or more object files This is not the case for bin/sh, but it's true for usr.bin/file. Cheers, -- Ruslan Ermilov Oracle Developer/DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010815095424.A47417>