Date: Sun, 30 Jun 2002 22:38:19 -0700 From: Doug Barton <DougB@FreeBSD.org> To: Anton Berezin <tobez@tobez.org> Cc: ports@FreeBSD.ORG Subject: Re: can't override CFLAGS in port makefile Message-ID: <3D1FEACB.B5C814AB@FreeBSD.org> References: <3D1FD83E.3C95470D@FreeBSD.org> <20020701051458.GA84241@heechee.tobez.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Anton Berezin wrote: > > Hi, > > On Sun, Jun 30, 2002 at 09:19:10PM -0700, Doug Barton wrote: > > > Workin' on some stuff this week, I got tripped up again by a problem > > I've run into before... namely that if a user has CFLAGS defined in > > /etc/make.conf, I can't twiddle it in my port's Makefile. Specifically, > > I'd like to be able to add: > > > > CFLAGS+= -static > > > > under certain circumstances. If I don't define anything for CFLAGS in > > /etc/make.conf, it works. However, it doesn't if the user has it > > defined. > > > > Any ideas? > > That's because ordinarily CFLAGS is passed to the sub-make in the > environment, which gets overwritten by make.conf. If you define No joy. I tried both: CFLAGS+= -static MAKE_ARGS+= CFLAGS="${CFLAGS}" and: MAKE_ARGS+= CFLAGS="${CFLAGS} -static" In both cases CFLAGS got written back to what it's defined as in /etc/make.conf. Doug To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3D1FEACB.B5C814AB>