diff options
author | rillig <rillig@pkgsrc.org> | 2008-12-15 12:47:31 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2008-12-15 12:47:31 +0000 |
commit | 03b5233b74c5d85d4a6e6e45f5f08e57de40e463 (patch) | |
tree | b8074d2cad7440e534dc91c61e2136a3afd08154 /pkgtools/pkglint | |
parent | c448324760919dd8d89bcb07469572ad72236b06 (diff) | |
download | pkgsrc-03b5233b74c5d85d4a6e6e45f5f08e57de40e463.tar.gz |
TOOLS_DEPENDS.* names a dependency, and all the directories that are
mentioned in it must actually contain a Makefile.
Diffstat (limited to 'pkgtools/pkglint')
-rw-r--r-- | pkgtools/pkglint/files/makevars.map | 3 | ||||
-rw-r--r-- | pkgtools/pkglint/files/pkglint.pl | 10 |
2 files changed, 10 insertions, 3 deletions
diff --git a/pkgtools/pkglint/files/makevars.map b/pkgtools/pkglint/files/makevars.map index ff01296cb2b..fa7e84fc6f1 100644 --- a/pkgtools/pkglint/files/makevars.map +++ b/pkgtools/pkglint/files/makevars.map @@ -1,4 +1,4 @@ -# $NetBSD: makevars.map,v 1.187 2008/11/18 08:04:35 rillig Exp $ +# $NetBSD: makevars.map,v 1.188 2008/12/15 12:47:31 rillig Exp $ # # This file contains the guessed type of some variables, according to @@ -669,6 +669,7 @@ TEXINFO_REQD List of Version [$package_list] TOOLS_ALIASES List of Filename [$system] TOOLS_BROKEN List of Tool [$system] TOOLS_CREATE List of Tool [$system] +TOOLS_DEPENDS.* InternalList of DependencyWithPath [$system] TOOLS_GNU_MISSING List of Tool [$system] TOOLS_NOOP List of Tool [$system] TOOLS_PATH.* Pathname [$system] diff --git a/pkgtools/pkglint/files/pkglint.pl b/pkgtools/pkglint/files/pkglint.pl index 821cc8c4b50..7b82bdcd812 100644 --- a/pkgtools/pkglint/files/pkglint.pl +++ b/pkgtools/pkglint/files/pkglint.pl @@ -1,5 +1,5 @@ #! @PERL@ -# $NetBSD: pkglint.pl,v 1.795 2008/12/14 18:46:58 rillig Exp $ +# $NetBSD: pkglint.pl,v 1.796 2008/12/15 12:47:31 rillig Exp $ # # pkglint - static analyzer and checker for pkgsrc packages @@ -3650,7 +3650,13 @@ sub checkline_relative_pkgdir($$) { checkline_relative_path($line, $path, true); $path = resolve_relative_path($path, false); - if ($path !~ m"^(?:\./)?\.\./\.\./[^/]+/[^/]+$") { + if ($path =~ m"^(?:\./)?\.\./\.\./([^/]+/[^/]+)$") { + my $otherpkgpath = $1; + if (! -f "$cwd_pkgsrcdir/$otherpkgpath/Makefile") { + $line->log_error("There is no package in $otherpkgpath."); + } + + } else { $line->log_warning("\"${path}\" is not a valid relative package directory."); $line->explain_warning( "A relative pathname always starts with \"../../\", followed", |