diff options
author | Joe Marcus Clarke <marcus@FreeBSD.org> | 2004-05-01 02:25:00 +0000 |
---|---|---|
committer | Joe Marcus Clarke <marcus@FreeBSD.org> | 2004-05-01 02:25:00 +0000 |
commit | ce673392c8d0ac7f82233d093e7979dae8364c9f (patch) | |
tree | f807946a0ef4d84690968c6f3631e124c09e0cc9 /devel/portlint | |
parent | 986ee705a7534ffb20b25d1ca118b2c2db0b5e83 (diff) | |
download | ports-ce673392c8d0ac7f82233d093e7979dae8364c9f.tar.gz ports-ce673392c8d0ac7f82233d093e7979dae8364c9f.zip |
Notes
Diffstat (limited to 'devel/portlint')
-rw-r--r-- | devel/portlint/Makefile | 2 | ||||
-rw-r--r-- | devel/portlint/src/portlint.pl | 42 |
2 files changed, 38 insertions, 6 deletions
diff --git a/devel/portlint/Makefile b/devel/portlint/Makefile index ee68a6f92ed9..cd6b13d3647d 100644 --- a/devel/portlint/Makefile +++ b/devel/portlint/Makefile @@ -8,7 +8,7 @@ # PORTNAME= portlint -PORTVERSION= 2.6.0 +PORTVERSION= 2.6.1 CATEGORIES= devel MASTER_SITES= # none DISTFILES= # none diff --git a/devel/portlint/src/portlint.pl b/devel/portlint/src/portlint.pl index 74d0e4216c57..71b68db77a2a 100644 --- a/devel/portlint/src/portlint.pl +++ b/devel/portlint/src/portlint.pl @@ -17,7 +17,7 @@ # OpenBSD and NetBSD will be accepted. # # $FreeBSD$ -# $Id: portlint.pl,v 1.44 2004/03/26 20:42:32 marcus Exp $ +# $Id: portlint.pl,v 1.46 2004/05/01 02:22:20 marcus Exp $ # use vars qw/ $opt_a $opt_A $opt_b $opt_c $opt_h $opt_t $opt_v $opt_M $opt_N $opt_B $opt_V /; @@ -40,7 +40,7 @@ $portdir = '.'; # version variables my $major = 2; my $minor = 6; -my $micro = 0; +my $micro = 1; sub l { '[{(]'; } sub r { '[)}]'; } @@ -250,12 +250,11 @@ close(IN); # # check for files. # -my @checker = ($makevar{DESCR}, 'Makefile', 'distinfo', $makevar{MD5_FILE}); +my @checker = ($makevar{DESCR}, 'Makefile', $makevar{MD5_FILE}); my %checker = ( $makevar{DESCR} => 'checkdescr', 'Makefile' => 'checkmakefile', - $makevar{MD5_FILE} => 'TRUE', - 'distinfo' => 'checkdistinfo', + $makevar{MD5_FILE} => 'checkdistinfo', ); if ($extrafile) { my @files = ( @@ -584,6 +583,8 @@ sub checkplist { my(@omffile) = (); my(@infofile) = (); + my $seen_dirrm_docsdir; + open(IN, "< $file") || return 0; while (<IN>) { if ($_ =~ /[ \t]+\n?$/) { @@ -603,6 +604,7 @@ sub checkplist { &perror("WARN: $file [$.]: use \%\%SITE_PERL\%\% ". "instead of lib/perl5/site_perl/\%\%PERL_VER\%\%."); } + $seen_dirrm_docsdir++ if /^(\%\%PORTDOCS\%\%)?\@dirrm\s+\%\%DOCSDIR\%\%/; if ($_ =~ /^\@/) { if ($_ =~ /^\@(cwd|cd)[ \t]+(\S+)/) { $curdir = $2; @@ -766,6 +768,10 @@ sub checkplist { } } + if ($sharedocused && !$seen_dirrm_docsdir) { + &perror("WARN: $file: \%\%PORTDOCS\%\%\@dirrm \%\%DOCSDIR\%\% is missing"); + } + # Check that each OMF file has an install and deinstall line. my $omf_install = join(" ", @exec_omf); $omf_install .= ' '; @@ -1028,6 +1034,18 @@ sub checkmakefile { } # + # whole file: PLIST_FILES and PLIST_DIRS + # + print "OK: checking PLIST_FILES and PLIST_DIRS.\n" if ($verbose); + if ($whole =~ /\nPLIST_FILES.?=/ || $whole =~ /\nPLIST_DIRS.?=/) { + if (-f 'pkg-plist') { + my $lineno = &linenumber($`); + &perror("WARN: $file [$lineno]: You may remove pkg-plist ". + "if you use PLIST_FILES and/or PLIST_DIRS."); + } + } + + # # whole file: USE_* used too late # pos($whole) = 0; @@ -1847,6 +1865,20 @@ FETCH_DEPENDS DEPENDS DEPENDS_TARGET "USE_PERL5."); } + # check USE_ICONV + if ($m{'dep'} =~ /^(iconv\.\d+)$/) { + &perror("WARN: $file: dependency to $1 ". + "listed in $j. consider using ". + "USE_ICONV."); + } + + # check USE_GETTEXT + if ($m{'dep'} =~ /^(intl\.\d+)$/) { + &perror("WARN: $file: dependency to $1 ". + "listed in $j. consider using ". + "USE_GETTEXT."); + } + # check USE_GMAKE if ($m{'dep'} =~ /^(gmake|\${GMAKE})$/) { &perror("WARN: $file: dependency to $1 ". |