diff options
author | rillig <rillig@pkgsrc.org> | 2005-09-22 11:56:37 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2005-09-22 11:56:37 +0000 |
commit | 5ed3de4dcc3363b8b25ec2a7d117cb212663a69d (patch) | |
tree | 890a5400b7b04cefb981d3378f45fda20a420766 /pkgtools | |
parent | dd6e480708491d71c9c12764cda8f02f2ba9e506 (diff) | |
download | pkgsrc-5ed3de4dcc3363b8b25ec2a7d117cb212663a69d.tar.gz |
Updated pkglint to 4.21.2.
Changed the file name pattern for patch files to avoid false positives
for DISTFILES that start with "patch-" (requested by salo). Added a
warning for invalid patch file names.
Diffstat (limited to 'pkgtools')
-rw-r--r-- | pkgtools/pkglint/Makefile | 4 | ||||
-rw-r--r-- | pkgtools/pkglint/files/pkglint.pl | 11 |
2 files changed, 9 insertions, 6 deletions
diff --git a/pkgtools/pkglint/Makefile b/pkgtools/pkglint/Makefile index dd0cbae0b76..54c499ed658 100644 --- a/pkgtools/pkglint/Makefile +++ b/pkgtools/pkglint/Makefile @@ -1,7 +1,7 @@ -# $NetBSD: Makefile,v 1.250 2005/09/22 01:46:46 rillig Exp $ +# $NetBSD: Makefile,v 1.251 2005/09/22 11:56:37 rillig Exp $ # -DISTNAME= pkglint-4.21.1 +DISTNAME= pkglint-4.21.2 CATEGORIES= pkgtools devel MASTER_SITES= # empty DISTFILES= # empty diff --git a/pkgtools/pkglint/files/pkglint.pl b/pkgtools/pkglint/files/pkglint.pl index 77bfb7e4949..09916afc708 100644 --- a/pkgtools/pkglint/files/pkglint.pl +++ b/pkgtools/pkglint/files/pkglint.pl @@ -11,7 +11,7 @@ # Freely redistributable. Absolutely no warranty. # # From Id: portlint.pl,v 1.64 1998/02/28 02:34:05 itojun Exp -# $NetBSD: pkglint.pl,v 1.284 2005/09/22 01:46:46 rillig Exp $ +# $NetBSD: pkglint.pl,v 1.285 2005/09/22 11:56:37 rillig Exp $ # # This version contains lots of changes necessary for NetBSD packages # done by: @@ -832,7 +832,7 @@ sub checkfile_distinfo($$) { next unless $line->text =~ /^(MD5|SHA1|RMD160) \(([^)]+)\) = (.*)$/; my ($alg, $patch, $sum) = ($1, $2, $3); - if ($patch =~ /^patch-[-A-Za-z0-9_.]+$/) { + if ($patch =~ /^patch-[A-Za-z0-9]+$/) { if (-f "${dir}/$patchdir/$patch") { my $chksum = `sed -e '/\$NetBSD.*/d' $dir/$patchdir/$patch | digest $alg`; $chksum =~ s/\r*\n*\z//; @@ -842,8 +842,8 @@ sub checkfile_distinfo($$) { } else { $line->log_error("$patch does not exist."); } - $in_distinfo{$patch} = true; } + $in_distinfo{$patch} = true; } checklines_trailing_empty_lines($distinfo); @@ -2491,10 +2491,13 @@ sub checkdir_package($) { } elsif ($f =~ qr"/PLIST[^/]*$") { $opt_check_PLIST and checkfile_PLIST($dir, $f); - } elsif ($f =~ qr"/patches/patch-[-A-Za-z0-9]*$") { + } elsif ($f =~ qr"/patches/patch-[A-Za-z0-9]*$") { $have_patches = true; $opt_check_patches and checkfile_patches_patch($dir, $f); + } elsif ($f =~ qr"/patches/[^/]*$") { + log_warning($f, NO_LINE_NUMBER, "Patch files should be named \"patch-\", followed by letters and digits only."); + } elsif (-T $f) { $opt_check_extra and checkfile_extra($dir, $f); |