summaryrefslogtreecommitdiff
path: root/pkgtools/pkglint/files
diff options
context:
space:
mode:
authorrillig <rillig>2005-12-01 16:11:27 +0000
committerrillig <rillig>2005-12-01 16:11:27 +0000
commitc5fdea2b14e3f3c76b4d140e697cebbe09ee78e4 (patch)
treea78538e9372fb6aec3b8acc8d916d2d7f3bd9942 /pkgtools/pkglint/files
parent48834dba0f93f4593bef85b577255fb192cf333d (diff)
downloadpkgsrc-c5fdea2b14e3f3c76b4d140e697cebbe09ee78e4.tar.gz
- In resolve_relative_path(), PKGSRCDIR is replaced with $pkgsrcdir.
- In checkline_relative_path(), an info message is generated if a filename could not be resolved completely.
Diffstat (limited to 'pkgtools/pkglint/files')
-rw-r--r--pkgtools/pkglint/files/pkglint.pl7
1 files changed, 5 insertions, 2 deletions
diff --git a/pkgtools/pkglint/files/pkglint.pl b/pkgtools/pkglint/files/pkglint.pl
index daf2630b4eb..045e08c2ef8 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.405 2005/12/01 15:21:56 rillig Exp $
+# $NetBSD: pkglint.pl,v 1.406 2005/12/01 16:11:27 rillig Exp $
#
# This version contains lots of changes necessary for NetBSD packages
# done by:
@@ -1082,6 +1082,7 @@ sub checkperms($) {
sub resolve_relative_path($) {
my ($relpath) = @_;
+ $relpath =~ s,\$\{PKGSRCDIR\},$pkgsrcdir,;
$relpath =~ s,\$\{\.CURDIR\},.,;
$relpath =~ s,\$\{PHPPKGSRCDIR\},../../lang/php5,;
$relpath =~ s,\$\{SUSE_DIR_PREFIX\},suse91,;
@@ -1168,7 +1169,9 @@ sub checkline_relative_path($$) {
$line->log_error("A pkgsrc package must not depend on any outside package.");
}
$path = resolve_relative_path($path);
- if ($path !~ regex_unresolved && !-e "${current_dir}/${path}") {
+ if ($path =~ regex_unresolved) {
+ $line->log_info("Unresolved path: \"${path}\".");
+ } elsif (!-e "${current_dir}/${path}") {
$line->log_error("\"${path}\" does not exist.");
}
}