diff options
author | kensmith <kensmith@FreeBSD.org> | 2005-03-24 23:03:39 +0000 |
---|---|---|
committer | kensmith <kensmith@FreeBSD.org> | 2005-03-24 23:03:39 +0000 |
commit | f1944299a8dede27779224f9a3826eef77ec0372 (patch) | |
tree | 128c58d7e890941bd6a5f991c07c930726d119ae | |
parent | 542b2a8123c6a0c336d8404f5cf12fe32df9ab69 (diff) | |
download | FreeBSD-src-f1944299a8dede27779224f9a3826eef77ec0372.zip FreeBSD-src-f1944299a8dede27779224f9a3826eef77ec0372.tar.gz |
Update parsing of the ports INDEX file to accomodate some new
fields that got added to it recently-ish. While here document
what each of the fields is based on discussion with portmgr@.
Patch from: murray (slightly adapted)
MFC after: 1 day
-rw-r--r-- | usr.sbin/sysinstall/index.c | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/usr.sbin/sysinstall/index.c b/usr.sbin/sysinstall/index.c index 4c94a52..ef68564 100644 --- a/usr.sbin/sysinstall/index.c +++ b/usr.sbin/sysinstall/index.c @@ -302,15 +302,15 @@ index_parse(FILE *fp, char *name, char *pathto, char *prefix, char *comment, cha if (i <= 0) return EOF; cp = line; - cp += copy_to_sep(name, cp, '|'); - cp += copy_to_sep(pathto, cp, '|'); - cp += copy_to_sep(prefix, cp, '|'); - cp += copy_to_sep(comment, cp, '|'); - cp += copy_to_sep(descr, cp, '|'); - cp += copy_to_sep(maint, cp, '|'); - cp += copy_to_sep(cats, cp, '|'); - cp += copy_to_sep(junk, cp, '|'); /* build deps - not used */ - cp += copy_to_sep(rdeps, cp, '|'); + cp += copy_to_sep(name, cp, '|'); /* package name */ + cp += copy_to_sep(pathto, cp, '|'); /* ports directory */ + cp += copy_to_sep(prefix, cp, '|'); /* prefix */ + cp += copy_to_sep(comment, cp, '|'); /* comment */ + cp += copy_to_sep(descr, cp, '|'); /* path to pkg-descr */ + cp += copy_to_sep(maint, cp, '|'); /* maintainer */ + cp += copy_to_sep(cats, cp, '|'); /* categories */ + cp += copy_to_sep(junk, cp, '|'); /* build deps - not used */ + cp += copy_to_sep(rdeps, cp, '|'); /* run deps */ if (index(cp, '|')) cp += copy_to_sep(junk, cp, '|'); /* url - not used */ else { @@ -319,6 +319,12 @@ index_parse(FILE *fp, char *name, char *pathto, char *prefix, char *comment, cha return 0; } if (index(cp, '|')) + cp += copy_to_sep(junk, cp, '|'); /* extract deps - not used */ + if (index(cp, '|')) + cp += copy_to_sep(junk, cp, '|'); /* patch deps - not used */ + if (index(cp, '|')) + cp += copy_to_sep(junk, cp, '|'); /* fetch deps - not used */ + if (index(cp, '|')) cp += copy_to_sep(volstr, cp, '|'); /* media volume */ else { strncpy(volstr, cp, 1023); |