summaryrefslogtreecommitdiff
path: root/pkgtools
diff options
context:
space:
mode:
authorwiz <wiz@pkgsrc.org>2003-07-24 07:54:45 +0000
committerwiz <wiz@pkgsrc.org>2003-07-24 07:54:45 +0000
commita17567376914a545560f4f0e6304b9b019e6d742 (patch)
tree08e3d14ca6ffd6b6094158fc9b1356d25b0ddb2e /pkgtools
parent002af730c0a36825bc93bba507bbd9f7b8054965 (diff)
downloadpkgsrc-a17567376914a545560f4f0e6304b9b019e6d742.tar.gz
Check if HOMEPAGE URL has a trailing slash if it only consists of a hostname.
From Ben Collver in PR 22215. Bump to 3.57.
Diffstat (limited to 'pkgtools')
-rw-r--r--pkgtools/pkglint/Makefile4
-rw-r--r--pkgtools/pkglint/files/pkglint.pl14
2 files changed, 13 insertions, 5 deletions
diff --git a/pkgtools/pkglint/Makefile b/pkgtools/pkglint/Makefile
index 476b2f533fd..e60dbb8b45e 100644
--- a/pkgtools/pkglint/Makefile
+++ b/pkgtools/pkglint/Makefile
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.163 2003/07/17 22:52:18 grant Exp $
+# $NetBSD: Makefile,v 1.164 2003/07/24 07:54:45 wiz Exp $
#
-DISTNAME= pkglint-3.56
+DISTNAME= pkglint-3.57
WRKSRC= ${WRKDIR}
CATEGORIES= pkgtools devel
MASTER_SITES= # empty
diff --git a/pkgtools/pkglint/files/pkglint.pl b/pkgtools/pkglint/files/pkglint.pl
index e63da83aab8..c0f46d0fd72 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.89 2003/07/14 15:36:29 martti Exp $
+# $NetBSD: pkglint.pl,v 1.90 2003/07/24 07:54:46 wiz Exp $
#
# This version contains lots of changes necessary for NetBSD packages
# done by Hubert Feyrer <hubertf@netbsd.org>,
@@ -1225,10 +1225,18 @@ EOF
&checkorder('MAINTAINER', $tmp, @tocheck);
- # warnings for missing HOMEPAGE
+ # warnings for missing or incorrect HOMEPAGE
$tmp = "\n" . $tmp;
- if ($tmp !~ /\nHOMEPAGE=/) {
+ if ($tmp !~ /\nHOMEPAGE[+?]?=[ \t]*([^\n]*)\n/ || $1 =~ /^[ \t]*$/) {
&perror("WARN: please add HOMEPAGE if the package has one.");
+ } else {
+ $i = $1;
+ if ($i =~ m#^\w+://#) {
+ if ($i !~ m#^\w+://[^\n/]+/#) {
+ &perror("WARN: URL \"$i\" does not ".
+ "end with \"/\".");
+ }
+ }
}
# warnings for missing COMMENT