From owner-freebsd-ports Sat Jan 13 17:54:54 2001 Delivered-To: freebsd-ports@freebsd.org Received: from puck.firepipe.net (mcut-b-167.resnet.purdue.edu [128.211.209.167]) by hub.freebsd.org (Postfix) with ESMTP id 7961B37B400 for ; Sat, 13 Jan 2001 17:54:37 -0800 (PST) Received: by puck.firepipe.net (Postfix, from userid 1000) id 98D4A19AB; Sat, 13 Jan 2001 20:54:34 -0500 (EST) Date: Sat, 13 Jan 2001 20:54:34 -0500 From: Will Andrews To: "Donald J . Maddox" Cc: ports@FreeBSD.ORG Subject: Re: How can I make GNU configure respect $CFLAGS? Message-ID: <20010113205434.A24382@puck.firepipe.net> Reply-To: Will Andrews Mail-Followup-To: Will Andrews , "Donald J . Maddox" , ports@FreeBSD.ORG References: <20010113204921.A54960@cae88-102-101.sc.rr.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010113204921.A54960@cae88-102-101.sc.rr.com>; from dmaddox@sc.rr.com on Sat, Jan 13, 2001 at 08:49:21PM -0500 X-Operating-System: FreeBSD 4.2-STABLE i386 Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On Sat, Jan 13, 2001 at 08:49:21PM -0500, Donald J . Maddox wrote: > TSIA... I would like to make a port of a program that uses a GNU > configure script. Problem is, it is bound and determined to set > $CFLAGS (or actually $CXXFLAGS in this case) to '-g -O2', no matter > what. Surely some of you experienced porters out there have run > into this one before... How can I make the port respect $CFLAGS > (or $CXXFLAGS)? Depends on the distribution's (ab)use of GNU configure. Usually, you can make bsd.port.mk export the CFLAGS value in CONFIGURE_ENV. Sometimes, however, you will have to use a perl regex on either the configure script itself or the configure.in autoconf script, to substitute '-g -O2' for ${CFLAGS}. -- wca To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message