diff options
author | jlam <jlam@pkgsrc.org> | 2006-05-29 20:01:39 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2006-05-29 20:01:39 +0000 |
commit | 5ff73b27ca80d685dfd2d7616270682063bb7629 (patch) | |
tree | abdfc0bd43c2e3794567e9e3e1f5f1efd170a680 /mk/plist | |
parent | 4ecb4314aa6810a3d6834493b96df67278f9ff13 (diff) | |
download | pkgsrc-5ff73b27ca80d685dfd2d7616270682063bb7629.tar.gz |
When filtering out unrelated info files, only check the last bit of
the name instead of the whole name. This avoids some problems where
the file name contains awk-special characters, e.g. +.
Diffstat (limited to 'mk/plist')
-rw-r--r-- | mk/plist/plist-info.awk | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/mk/plist/plist-info.awk b/mk/plist/plist-info.awk index 79f8b81224d..9934c104de6 100644 --- a/mk/plist/plist-info.awk +++ b/mk/plist/plist-info.awk @@ -1,4 +1,4 @@ -# $NetBSD: plist-info.awk,v 1.12 2006/04/14 13:23:42 jlam Exp $ +# $NetBSD: plist-info.awk,v 1.13 2006/05/29 20:01:39 jlam Exp $ # # Copyright (c) 2006 The NetBSD Foundation, Inc. # All rights reserved. @@ -108,11 +108,11 @@ BEGIN { sub("^info/", PKGINFODIR "/") cmd = TEST " -f " PREFIX "/" $0 " -o -f " PREFIX "/" $0 ".gz" if (system(cmd) == 0) { - base = $0 - cmd = "cd " PREFIX " && " LS " -1 " base "*" + len = length + cmd = "cd " PREFIX " && " LS " -1 " $0 "*" while (cmd | getline) { # Filter out unrelated info files - if ($0 !~ "^" base "(-[0-9]+)?(\.gz)?$") { + if (substr($0, len + 1) !~ "^(-[0-9]+)?(\.gz)?$") { continue } #if ((MANZ ~ /[yY][eE][sS]/) && ($0 !~ /\.gz$/)) { |