aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormarcus <marcus@FreeBSD.org>2009-01-19 02:49:58 +0800
committermarcus <marcus@FreeBSD.org>2009-01-19 02:49:58 +0800
commit0f7e79035ddd93b6921e4f6a1b669bcc9557b39d (patch)
tree4fc3da65cdd76b7a5d2941893cb8796857a252b7
parent0cca5a9b37c0a155a8e817dd643cfe754c5a0df0 (diff)
downloadfreebsd-ports-gnome-0f7e79035ddd93b6921e4f6a1b669bcc9557b39d.tar.gz
freebsd-ports-gnome-0f7e79035ddd93b6921e4f6a1b669bcc9557b39d.tar.zst
freebsd-ports-gnome-0f7e79035ddd93b6921e4f6a1b669bcc9557b39d.zip
Update to 2.10.2.
* Loosen the error around USE_ANT and do-build [1] * Add a check for CFLAGS and CXXFLAGS in CONFIGURE_ENV [2] * Add a check for Fortran flags in CONFIGURE_ENV [3] PR: 128482 [2] Requested by: Dominic Fandrey <kamikaze@bsdforen.de> [1] gerlad [3] Submitted by: amdmi3 [2]
-rw-r--r--ports-mgmt/portlint/Makefile3
-rw-r--r--ports-mgmt/portlint/src/portlint.pl67
2 files changed, 61 insertions, 9 deletions
diff --git a/ports-mgmt/portlint/Makefile b/ports-mgmt/portlint/Makefile
index b41b076740c6..071beec2ecca 100644
--- a/ports-mgmt/portlint/Makefile
+++ b/ports-mgmt/portlint/Makefile
@@ -8,8 +8,7 @@
#
PORTNAME= portlint
-PORTVERSION= 2.10.1
-PORTREVISION= 1
+PORTVERSION= 2.10.2
CATEGORIES= ports-mgmt
MASTER_SITES= # none
DISTFILES= # none
diff --git a/ports-mgmt/portlint/src/portlint.pl b/ports-mgmt/portlint/src/portlint.pl
index cbe1f9c99957..3cce0d33f58e 100644
--- a/ports-mgmt/portlint/src/portlint.pl
+++ b/ports-mgmt/portlint/src/portlint.pl
@@ -17,7 +17,7 @@
# OpenBSD and NetBSD will be accepted.
#
# $FreeBSD$
-# $MCom: portlint/portlint.pl,v 1.162 2008/10/22 22:04:38 marcus Exp $
+# $MCom: portlint/portlint.pl,v 1.163 2009/01/18 18:49:03 marcus Exp $
#
use vars qw/ $opt_a $opt_A $opt_b $opt_C $opt_c $opt_g $opt_h $opt_t $opt_v $opt_M $opt_N $opt_B $opt_V /;
@@ -46,7 +46,7 @@ $portdir = '.';
# version variables
my $major = 2;
my $minor = 10;
-my $micro = 1;
+my $micro = 2;
sub l { '[{(]'; }
sub r { '[)}]'; }
@@ -1720,7 +1720,7 @@ ruby sed sh sort sysctl touch tr which xargs xmkmf
}
#
- # while file: check for use of paths that have macro replacements
+ # whole file: check for use of paths that have macro replacements
#
my %pathnames = ();
print "OK: checking for paths that have macro replacements.\n"
@@ -1838,7 +1838,6 @@ ruby sed sh sort sysctl touch tr which xargs xmkmf
}
}
-
#
# whole file: USE_JAVA check
#
@@ -1893,6 +1892,60 @@ ruby sed sh sort sysctl touch tr which xargs xmkmf
}
#
+ # whole file: CONFIGURE_ENV
+ #
+ if ($whole =~ /\nCONFIGURE_ENV[?:]?=\s*([^\\\n]+(\\\n[^\\\n]+)*)/) {
+ my $configure_env = $1;
+ my $cflags = undef;
+ my $cxxflags = undef;
+ if ($configure_env =~ /\bCFLAGS="([^"]+)"/ ||
+ $configure_env =~ /\bCFLAGS='([^']+)'/ ||
+ $configure_env =~ /\bCFLAGS=(\S+)/) {
+ $cflags = $1;
+ }
+ if ($configure_env =~ /\bCXXFLAGS="([^"]+)"/ ||
+ $configure_env =~ /\bCXXFLAGS='([^']+)'/ ||
+ $configure_env =~ /\bCXXFLAGS=(\S+)/) {
+ $cxxflags = $1;
+ }
+
+ if (defined($cflags) || defined($cxxflags)) {
+ &perror("WARN", $file, -1, "CFLAGS/CXXFLAGS are not needed in ".
+ "CONFIGURE_ENV as they are already added there in bsd.port.mk.");
+ }
+
+ if ($makevar{GNU_CONFIGURE} ne '') {
+ if ((defined($cflags) && $cflags =~ /-I/) ||
+ (defined($cxxflags) && $cxxflags =~ /-I/)) {
+ &perror("WARN", $file, -1, "Consider passing include paths ".
+ "to configure via CPPFLAGS environment variable ".
+ "i.e. CPPFLAGS=\"-I...\" in CONFIGURE_ENV)");
+ }
+ }
+
+ if (defined($cflags) && $cflags !~ /\$\{CFLAGS/) {
+ &perror("FATAL", $file, -1, "CFLAGS are clobbered in ".
+ "CONFIGURE_ENV. Alter CFLAGS in the Makefile with ".
+ "CFLAGS+=... instead");
+ }
+
+ if (defined($cxxflags) && $cflags !~ /\$\{CXXFLAGS/) {
+ &perror("FATAL", $file, -1, "CXXFLAGS are clobbered in ".
+ "CONFIGURE_ENV. Alter CXXFLAGS in the Makefile with ".
+ "CXXFLAGS+=... instead");
+ }
+
+ if ($configure_env =~ /(FC)=/ ||
+ $configure_env =~ /(F77)=/ ||
+ $configure_env =~ /(FCFLAGS)=/) {
+ &perror("FATAL", $file, -1, "The Fortran flag, $1 is already ".
+ "passed in CONFIGURE_ENV via bsd.gcc.mk. If you need to ".
+ "override the the default value, alter $1 in the Makefile ".
+ "instead with $1=...");
+ }
+ }
+
+ #
# slave port check
#
my $masterdir = $makevar{MASTERDIR};
@@ -2747,9 +2800,9 @@ FETCH_DEPENDS DEPENDS_TARGET
}
if ($tmp =~ /^do-build:/m && $use_ant) {
- &perror("FATAL", $file, -1, "USE_ANT is intended only for ports that ".
- "build with Ant. You should not override ``do-build'' when ".
- "defining USE_ANT");
+ &perror("WARN", $file, -1, "USE_ANT is intended only for ports that ".
+ "build with Ant. It is recommended not to override the default ".
+ "'do-build:' target when defining USE_ANT");
}
#