From 70441c6f2c581cbd592048d2564d91253d38acb2 Mon Sep 17 00:00:00 2001 From: Joe Marcus Clarke Date: Sat, 23 May 2009 19:07:32 +0000 Subject: Update to 2.11.2. * Fix a warning when PKGINSTALLVER is not defined. [1] * Fix a false positive which can occur when install-info is used in sed expressions. [2] * Add depcrecation checks for Apache macros. [3] PR: 134000 [1] 134614 [2] 134610 [3] Submitted by: Eygene Ryabinkin [1] Lapo Luchini [2] pgollucci [3] --- ports-mgmt/portlint/Makefile | 2 +- ports-mgmt/portlint/src/portlint.pl | 38 ++++++++++++++++++++++++++++++++----- 2 files changed, 34 insertions(+), 6 deletions(-) (limited to 'ports-mgmt/portlint') diff --git a/ports-mgmt/portlint/Makefile b/ports-mgmt/portlint/Makefile index 82bbba99254b..b04db624a362 100644 --- a/ports-mgmt/portlint/Makefile +++ b/ports-mgmt/portlint/Makefile @@ -8,7 +8,7 @@ # PORTNAME= portlint -PORTVERSION= 2.11.1 +PORTVERSION= 2.11.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 895c2e98ec21..d5d85488977e 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.174 2009/04/13 01:54:37 marcus Exp $ +# $MCom: portlint/portlint.pl,v 1.178 2009/05/23 19:05:39 marcus Exp $ # use strict; @@ -50,7 +50,7 @@ $portdir = '.'; # version variables my $major = 2; my $minor = 11; -my $micro = 1; +my $micro = 2; sub l { '[{(]'; } sub r { '[)}]'; } @@ -1190,6 +1190,14 @@ sub check_depends_syntax { "\${X11BASE} instead."); } + # Check for direct dependency on apache. + if ($m{'dep'} =~ /apache/i) { + &perror("FATAL", $file, -1, "do not depend on any apache ". + "port in *_DEPENDS directly. ". + "Instead use USE_APACHE=VERSION, where VERSION can be ". + "found in \${PORTSDIR}/Mk/bsd.apache.mk."); + } + # check port dir existence $k = $m{'dir'}; $k =~ s/\${PORTSDIR}/$ENV{'PORTSDIR'}/; @@ -1643,6 +1651,7 @@ sub checkmakefile { USE_MESA => 'USE_GL', USE_RCORDER => 'USE_RC_SUBR', INSTALLS_SHLIB => 'USE_LDCONFIG', + APACHE_COMPAT => 'USE_APACHE', ); @deplist = (\%autotools_deprecated, \%deprecated); @@ -1899,6 +1908,24 @@ ruby sed sh sort sysctl touch tr which xargs xmkmf "and USE_GMAKE"); } + # + # whole file: check for USE_APACHE=yes + # + if ($whole =~ /^USE_APACHE[?:]?=\s*(yes)$/m) { + &perror("WARN", $file, -1, "Use USE_APACHE=VERSION ". + "(where version can be found in \${PORTSDIR}/Mk/bsd.apache.mk) ". + "instead of yes"); + } + + # + # whole file: check for WITH_APACHE2 + # + if ($whole =~ /^WITH_APACHE2[?:]?=/m) { + &perror("WARN", $file, -1, "Use WITH_APACHE=VERSION (where VERSION ". + "can be found in \${PORTSDIR}/Mk/bsd.apache.mk) instead to pull ". + "in APACHE_PORT"); + } + # # whole file: check for JAVA_BUILD and NO_BUILD # @@ -2375,7 +2402,8 @@ DIST_SUBDIR EXTRACT_ONLY print "OK: checking CONFLICTS.\n" if ($verbose); foreach my $conflict (split ' ', $makevar{CONFLICTS}) { my $selfconflict; - if ($makevar{PKGINSTALLVER} >= 20040125) { + if ($makevar{PKGINSTALLVER} ne "" && + $makevar{PKGINSTALLVER} >= 20040125) { $selfconflict = !system($pkg_version, '-T', $makevar{PKGNAME}, $conflict); } else { @@ -2780,7 +2808,7 @@ FETCH_DEPENDS DEPENDS_TARGET print "OK: checking INFO.\n" if ($verbose); if ($autoinfo && $tmp =~ /\nINFO=\s*([^\n]*)\n/) { my @minfo = grep($_ !~ /^\s*$/, split(/\s+/, $1)); - if ($tmp =~ /\binstall-info\b/) { + if ($tmp =~ /[\/|\s]install-info\s/) { &perror("FATAL", $file, -1, "install-info is automatically run ". "when INFO is defined."); } @@ -2790,7 +2818,7 @@ FETCH_DEPENDS DEPENDS_TARGET "on files listed in the INFO macro."); } } - } elsif ($autoinfo && $tmp =~ /\binstall-info\b/) { + } elsif ($autoinfo && $tmp =~ /[\/|\s]install-info\s/) { &perror("WARN", $file, -1, "do not call install-info directly. Use the ". "INFO macro instead."); } -- cgit v1.2.3