Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 22 Sep 2001 00:32:43 +1000 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        Ruslan Ermilov <ru@FreeBSD.ORG>
Cc:        Peter Wemm <peter@wemm.org>, Warner Losh <imp@FreeBSD.ORG>, Steve Kargl <sgk@troutmask.apl.washington.edu>, <freebsd-current@FreeBSD.ORG>
Subject:   Re: stdin/out/err changes kill world
Message-ID:  <20010922002628.I76524-100000@delplex.bde.org>
In-Reply-To: <20010921102207.H27714@sunbay.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 21 Sep 2001, Ruslan Ermilov wrote:

> This is because BMAKEENV has DESTDIR=${WORLDTMP}, and
> bsd.{prog,lib}.mk have the magic of adding the
> -I${DESTDIR}/usr/include to CFLAGS if DESTDIR is set.
>
> I'm currently testing the following patch with the
> -CURRENT build on a -STABLE box.
>
> Index: bsd.prog.mk
> ===================================================================
> RCS file: /home/ncvs/src/share/mk/bsd.prog.mk,v
> retrieving revision 1.100
> diff -u -r1.100 bsd.prog.mk
> --- bsd.prog.mk	2001/06/14 06:08:02	1.100
> +++ bsd.prog.mk	2001/09/21 07:23:14
> @@ -11,7 +11,7 @@
>  .SUFFIXES: .out .o .c .cc .cpp .cxx .C .m .y .l .s .S
>
>  CFLAGS+=${COPTS} ${DEBUG_FLAGS}
> -.if defined(DESTDIR)
> +.if defined(DESTDIR) && !defined(BOOTSTRAPPING)
>  CFLAGS+= -I${DESTDIR}/usr/include
>  CXXINCLUDES+= -I${DESTDIR}/usr/include/g++
>  .endif
> Index: bsd.lib.mk
> ===================================================================
> RCS file: /home/ncvs/src/share/mk/bsd.lib.mk,v
> retrieving revision 1.97
> diff -u -r1.97 bsd.lib.mk
> --- bsd.lib.mk	2001/05/19 23:24:17	1.97
> +++ bsd.lib.mk	2001/09/21 07:23:15
> @@ -37,7 +37,7 @@
>  .endif
>  .endif
>
> -.if defined(DESTDIR)
> +.if defined(DESTDIR) && !defined(BOOTSTRAPPING)
>  CFLAGS+= -I${DESTDIR}/usr/include
>  CXXINCLUDES+= -I${DESTDIR}/usr/include/g++
>  .endif

This CFLAGS adjustment should be moved to src/Makefile.inc1 someday.
Using the includes in DESTDIR can only be right if you have just
installed them there, but if you did that you can adjust CFLAGS too.

Bruce


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?20010922002628.I76524-100000>