diff options
author | Joe Marcus Clarke <marcus@FreeBSD.org> | 2017-10-08 17:58:52 +0000 |
---|---|---|
committer | Joe Marcus Clarke <marcus@FreeBSD.org> | 2017-10-08 17:58:52 +0000 |
commit | de70d0d05c0bec1c27815095541b226cb7207ced (patch) | |
tree | d2c41f4b358fca2843c7bb421ed330da363a29e2 /ports-mgmt/portlint | |
parent | b37eef008ae0aa91b5420f69f80714d695ed1e26 (diff) | |
download | ports-de70d0d05c0bec1c27815095541b226cb7207ced.tar.gz ports-de70d0d05c0bec1c27815095541b226cb7207ced.zip |
Notes
Diffstat (limited to 'ports-mgmt/portlint')
-rw-r--r-- | ports-mgmt/portlint/Makefile | 2 | ||||
-rw-r--r-- | ports-mgmt/portlint/src/portlint.pl | 25 |
2 files changed, 14 insertions, 13 deletions
diff --git a/ports-mgmt/portlint/Makefile b/ports-mgmt/portlint/Makefile index 7f6e52df3117..9a3abc4a84d2 100644 --- a/ports-mgmt/portlint/Makefile +++ b/ports-mgmt/portlint/Makefile @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= portlint -PORTVERSION= 2.17.12 +PORTVERSION= 2.17.13 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 41ea730e5d04..4043796b0816 100644 --- a/ports-mgmt/portlint/src/portlint.pl +++ b/ports-mgmt/portlint/src/portlint.pl @@ -15,7 +15,7 @@ # was removed. # # $FreeBSD$ -# $MCom: portlint/portlint.pl,v 1.424 2017/08/15 12:38:42 jclarke Exp $ +# $MCom: portlint/portlint.pl,v 1.430 2017/10/08 17:56:03 jclarke Exp $ # use strict; @@ -50,7 +50,7 @@ $portdir = '.'; # version variables my $major = 2; my $minor = 17; -my $micro = 12; +my $micro = 13; # default setting - for FreeBSD my $portsdir = '/usr/ports'; @@ -218,7 +218,7 @@ my $ulineno = -1; my $uulineno = -1; my @muses = (); while (my $mline = <MK>) { - if ($uulineno == -1 && $mline =~ /^USE_/) { + if ($uulineno == -1 && $mline =~ /^USE_/ && $mline !~ /^USE_GITHUB/) { $uulineno = $.; } if ($mline =~ /^USES[?+]?=\s*(.*)/) { @@ -1104,14 +1104,13 @@ sub check_depends_syntax { my %depmvars = (); foreach my $dv ($m{'dep'}, $m{'dir'}, $m{'tgt'}) { foreach my $mv ($dv =~ /\$\{([^}]+)\}/g) { - my $mvar = $1; - if (defined($depmvars{$mvar})) { + if (defined($depmvars{$mv})) { next; } - if (defined($makevar{$mvar})) { - $depmvars{$mvar} = $makevar{$mvar}; + if (defined($makevar{$mv})) { + $depmvars{$mv} = $makevar{$mv}; } else { - $depmvars{$mvar} = &get_makevar($mvar); + $depmvars{$mv} = &get_makevar($mv); } } } @@ -1173,7 +1172,6 @@ sub check_depends_syntax { my %udeps = ( 'bison' => 'bison', 'fmake' => 'fmake', - 'libexecinfo.so' => 'execinfo', ); foreach my $udep (keys %udeps) { if ($m{'dep'} =~ /^$udep/) { @@ -2969,7 +2967,7 @@ MAINTAINER COMMENT # print "OK: checking fourth section of $file (LICENSE).\n" if ($verbose); - $tmp = $sections[$idx]; + $tmp = $sections[$idx] // ''; if ($makevar{LICENSE}) { &checkorder('LICENSE', $tmp, $file, qw( @@ -3022,6 +3020,10 @@ NOT_FOR_ARCHS NOT_FOR_ARCHS_REASON(_\w+)? $idx++; } + foreach my $i (@linestocheck) { + $tmp =~ s/$i[?+:]?=[^\n]+\n//g; + } + push(@varnames, @linestocheck); &checkearlier($file, $tmp, @varnames); @@ -3388,11 +3390,10 @@ sub checkorder { sub checkearlier { my($file, $str, @varnames) = @_; - my($i); $str //= ''; - print "OK: checking items that has to appear earlier.\n" if ($verbose); + print "OK: checking items that have to appear earlier.\n" if ($verbose); foreach my $i (@varnames) { if ($str =~ /\n($i)\??=/) { &perror("WARN", $file, -1, "\"$1\" has to appear earlier."); |