Date: Thu, 4 Oct 2012 15:35:43 -0400 (EDT) From: Greg Larkin <glarkin@FreeBSD.org> To: FreeBSD-gnats-submit@FreeBSD.org Cc: marcus@FreeBSD.org Subject: ports/172335: [PATCH] ports-mgmt/portlint: Remove spurious warning about *_CPPFLAGS/*_LDFLAGS variables Message-ID: <201210041935.q94JZhRP086127@portsdev.shn.prv> Resent-Message-ID: <201210041940.q94Je3lj008180@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 172335 >Category: ports >Synopsis: [PATCH] ports-mgmt/portlint: Remove spurious warning about *_CPPFLAGS/*_LDFLAGS variables >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Thu Oct 04 19:40:03 UTC 2012 >Closed-Date: >Last-Modified: >Originator: Greg Larkin >Release: FreeBSD 8.3-RELEASE-p3 amd64 >Organization: The FreeBSD Project >Environment: System: FreeBSD portsdev.shn.prv 8.3-RELEASE-p3 FreeBSD 8.3-RELEASE-p3 #0: Tue Jun 12 00:39:29 UTC 2012 >Description: portlint tests if the port Makefile adds CPPFLAGS and LDFLAGS to the CONFIGURE_ENV variable and warns against it since it's already done in bsd.port.mk. The regexp used in the test also matches variables such as FOO_CPPFLAGS and FOO_LDFLAGS, as in this example from devel/gearmand/Makefile: CONFIGURE_ENV+= LIBTOKYOCABINET_CPPFLAGS=-I${LOCALBASE}/include \ LIBTOKYOCABINET_LDFLAGS=-L${LOCALBASE}/lib The patch adds a word boundary check to the beginning of each regexp to avoid warning about constructs like the one above. Port maintainer (marcus@FreeBSD.org) is cc'd. Generated with FreeBSD Port Tools 0.99_6 (mode: change, diff: ports) >How-To-Repeat: Run "portlint -C" in /usr/ports/devel/gearmand >Fix: --- portlint-2.13.12.patch begins here --- --- /usr/ports/ports-mgmt/portlint/src/portlint.pl 2012-08-05 18:56:23.000000000 -0400 +++ ./src/portlint.pl 2012-10-04 15:27:26.000000000 -0400 @@ -16,7 +16,7 @@ # This code now mainly supports FreeBSD, but patches to update support for # OpenBSD and NetBSD will be accepted. # # $FreeBSD: ports/ports-mgmt/portlint/src/portlint.pl,v 1.130 2012/08/05 22:56:23 marcus Exp $ # $MCom: portlint/portlint.pl,v 1.252 2012/08/05 22:18:57 marcus Exp $ # @@ -2186,14 +2186,14 @@ "instead with $1=..."); } - if ($configure_env =~ /(CPPFLAGS)=/) { + if ($configure_env =~ /(\bCPPFLAGS)=/) { &perror("FATAL", $file, -1, "$1 is already ". "passed in CONFIGURE_ENV via bsd.port.mk. If you need to ". "override the default value, alter $1 in the Makefile ". "instead with $1+=..."); } - if ($configure_env =~ /(LDFLAGS)=/) { + if ($configure_env =~ /(\bLDFLAGS)=/) { &perror("FATAL", $file, -1, "$1 is already passed in ". "CONFIGURE_ENV via bsd.port.mk. If you need to ". "override the default value, alter $1 in the Makefile ". --- portlint-2.13.12.patch ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201210041935.q94JZhRP086127>