Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-1-5]: src/usr.sbin/pkg_install/info Pull up revisions 1.25-1.27 (...
details: https://anonhg.NetBSD.org/src/rev/53dfec589344
branches: netbsd-1-5
changeset: 492838:53dfec589344
user: he <he%NetBSD.org@localhost>
date: Sat Feb 23 18:08:23 2002 +0000
description:
Pull up revisions 1.25-1.27 (requested by seb):
Synchronize with recent developments:
o Fix pkg_info to not FTP unneccessarily; fixes PR#13397
o Various internal cleanups, bugfixes, and API tweaks
diffstat:
usr.sbin/pkg_install/info/main.c | 18 ++++++++++++++----
1 files changed, 14 insertions(+), 4 deletions(-)
diffs (59 lines):
diff -r b3f63cedcd19 -r 53dfec589344 usr.sbin/pkg_install/info/main.c
--- a/usr.sbin/pkg_install/info/main.c Sat Feb 23 18:07:50 2002 +0000
+++ b/usr.sbin/pkg_install/info/main.c Sat Feb 23 18:08:23 2002 +0000
@@ -1,11 +1,11 @@
-/* $NetBSD: main.c,v 1.23.2.1 2001/03/20 18:04:00 he Exp $ */
+/* $NetBSD: main.c,v 1.23.2.2 2002/02/23 18:08:23 he Exp $ */
#include <sys/cdefs.h>
#ifndef lint
#if 0
static char *rcsid = "from FreeBSD Id: main.c,v 1.14 1997/10/08 07:47:26 charnier Exp";
#else
-__RCSID("$NetBSD: main.c,v 1.23.2.1 2001/03/20 18:04:00 he Exp $");
+__RCSID("$NetBSD: main.c,v 1.23.2.2 2002/02/23 18:08:23 he Exp $");
#endif
#endif
@@ -38,7 +38,7 @@
#include "lib.h"
#include "info.h"
-static char Options[] = "aBbcDde:fFhIikLl:mpqRrsSvV";
+static char Options[] = "aBbcDde:fFhIikLl:mnpqRrsSvV";
int Flags = 0;
Boolean AllInstalled = FALSE;
@@ -55,7 +55,7 @@
usage(void)
{
fprintf(stderr, "%s\n%s\n%s\n",
- "usage: pkg_info [-BbcDdFfIikLmpqRrSsVvh] [-e package] [-l prefix]",
+ "usage: pkg_info [-BbcDdFfIikLmnpqRrSsVvh] [-e package] [-l prefix]",
" pkg-name [pkg-name ...]",
" pkg_info -a [flags]");
exit(1);
@@ -144,6 +144,10 @@
Flags |= SHOW_MTREE;
break;
+ case 'n':
+ Flags |= SHOW_DEPENDS;
+ break;
+
case 'p':
Flags |= SHOW_PREFIX;
break;
@@ -196,6 +200,12 @@
AllInstalled = TRUE;
}
+ /* Don't do FTP stuff when operating on all pkgs */
+ if (AllInstalled && getenv("PKG_PATH") != 0) {
+ warnx("disabling PKG_PATH when operating on all packages.");
+ unsetenv("PKG_PATH");
+ }
+
/* Set some reasonable defaults */
if (!Flags)
Flags = SHOW_COMMENT | SHOW_DESC | SHOW_REQBY | SHOW_DEPENDS;
Home |
Main Index |
Thread Index |
Old Index