pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mk/scripts allow spaces after the "=" in the .pkgcache...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/53c938b08db4
branches:  trunk
changeset: 494103:53c938b08db4
user:      dmcmahill <dmcmahill%pkgsrc.org@localhost>
date:      Thu May 19 11:46:40 2005 +0000

description:
allow spaces after the "=" in the .pkgcache files.  This was noted with
some of the older packages on ftp.netbsd.org.  For example,
pkg_info -B ftp://ftp.netbsd.org/pub/NetBSD/packages/1.5.2/vax/All/cascade-1.4.tgz
will give

OPSYS= NetBSD

instead of

OPSYS=NetBSD

diffstat:

 mk/scripts/genreadme.awk |  14 +++++++-------
 1 files changed, 7 insertions(+), 7 deletions(-)

diffs (31 lines):

diff -r 49f88894a329 -r 53c938b08db4 mk/scripts/genreadme.awk
--- a/mk/scripts/genreadme.awk  Thu May 19 11:37:47 2005 +0000
+++ b/mk/scripts/genreadme.awk  Thu May 19 11:46:40 2005 +0000
@@ -1,5 +1,5 @@
 #!/usr/bin/awk -f
-# $NetBSD: genreadme.awk,v 1.14 2005/05/19 03:50:39 dmcmahill Exp $
+# $NetBSD: genreadme.awk,v 1.15 2005/05/19 11:46:40 dmcmahill Exp $
 #
 # Copyright (c) 2002, 2003, 2005 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -816,14 +816,14 @@
       osver = "unknown";
       march = "unknown";
     } else if( $0 ~/^OPSYS=/ ) {
-      opsys = $1;
-      gsub(/OPSYS=/, "", opsys);
+      opsys = $0;
+      gsub(/OPSYS=[ \t]*/, "", opsys);
     } else if( $0 ~/^OS_VERSION=/ ) {
-      osver = $1;
-      gsub(/OS_VERSION=/, "", osver);
+      osver = $0;
+      gsub(/OS_VERSION=[ \t]*/, "", osver);
     } else if( $0 ~/^MACHINE_ARCH=/ ) {
-      march = $1;
-      gsub(/MACHINE_ARCH=/, "", march);
+      march = $0;
+      gsub(/MACHINE_ARCH=[ \t]*/, "", march);
     } else if( $0 ~/^pkgcache_end /) {
       if( debug ) printf("\t%s, OPSYS=%s, OS_VERSION=%s, MACHINE_ARCH=%s\n",
                         pkgfile, opsys, osver, march);



Home | Main Index | Thread Index | Old Index