diff options
author | jkh <jkh@FreeBSD.org> | 1997-03-10 21:11:57 +0000 |
---|---|---|
committer | jkh <jkh@FreeBSD.org> | 1997-03-10 21:11:57 +0000 |
commit | d293740501a8d0e0849a257a9409d6187ce6fab5 (patch) | |
tree | 62d8475e39f33fb606271cdfe9074f0cb715e182 /usr.sbin/sysinstall/dist.c | |
parent | 130c16d5a4cb465550121172c4267dc2ee19e59d (diff) | |
download | FreeBSD-src-d293740501a8d0e0849a257a9409d6187ce6fab5.zip FreeBSD-src-d293740501a8d0e0849a257a9409d6187ce6fab5.tar.gz |
Sync with 2.2.
Diffstat (limited to 'usr.sbin/sysinstall/dist.c')
-rw-r--r-- | usr.sbin/sysinstall/dist.c | 35 |
1 files changed, 28 insertions, 7 deletions
diff --git a/usr.sbin/sysinstall/dist.c b/usr.sbin/sysinstall/dist.c index f05b3f7..acecddc 100644 --- a/usr.sbin/sysinstall/dist.c +++ b/usr.sbin/sysinstall/dist.c @@ -4,7 +4,7 @@ * This is probably the last program in the `sysinstall' line - the next * generation being essentially a complete rewrite. * - * $Id: dist.c,v 1.99 1997/02/22 14:11:31 peter Exp $ + * $Id: dist.c,v 1.100 1997/03/08 12:57:41 jkh Exp $ * * Copyright (c) 1995 * Jordan Hubbard. All rights reserved. @@ -175,6 +175,7 @@ static Distribution XF86FontDistTable[] = { }; static int distMaybeSetDES(dialogMenuItem *self); +static int distMaybeSetPorts(dialogMenuItem *self); int distReset(dialogMenuItem *self) @@ -194,7 +195,7 @@ distSetDeveloper(dialogMenuItem *self) distReset(NULL); Dists = _DIST_DEVELOPER; SrcDists = DIST_SRC_ALL; - return distMaybeSetDES(self); + return distMaybeSetDES(self) | distMaybeSetPorts(self); } int @@ -206,7 +207,7 @@ distSetXDeveloper(dialogMenuItem *self) XF86Dists = DIST_XF86_BIN | DIST_COMPAT21 | DIST_XF86_SET | DIST_XF86_CFG | DIST_XF86_LIB | DIST_XF86_PROG | DIST_XF86_MAN | DIST_XF86_SERVER | DIST_XF86_FONTS; XF86ServerDists = DIST_XF86_SERVER_SVGA | DIST_XF86_SERVER_VGA16; XF86FontDists = DIST_XF86_FONTS_MISC; - return distSetXF86(NULL) | distMaybeSetDES(self); + return distSetXF86(NULL) | distMaybeSetDES(self) | distMaybeSetPorts(self); } int @@ -215,7 +216,7 @@ distSetKernDeveloper(dialogMenuItem *self) distReset(NULL); Dists = _DIST_DEVELOPER; SrcDists = DIST_SRC_SYS; - return distMaybeSetDES(self); + return distMaybeSetDES(self) | distMaybeSetPorts(self); } int @@ -223,7 +224,7 @@ distSetUser(dialogMenuItem *self) { distReset(NULL); Dists = _DIST_USER; - return distMaybeSetDES(self); + return distMaybeSetDES(self) | distMaybeSetPorts(self); } int @@ -234,7 +235,7 @@ distSetXUser(dialogMenuItem *self) XF86Dists = DIST_XF86_BIN | DIST_COMPAT21 | DIST_XF86_SET | DIST_XF86_CFG | DIST_XF86_LIB | DIST_XF86_MAN | DIST_XF86_SERVER | DIST_XF86_FONTS; XF86ServerDists = DIST_XF86_SERVER_SVGA | DIST_XF86_SERVER_VGA16; XF86FontDists = DIST_XF86_FONTS_MISC; - return distSetXF86(NULL) | distMaybeSetDES(self); + return distSetXF86(NULL) | distMaybeSetDES(self) | distMaybeSetPorts(self); } int @@ -253,7 +254,7 @@ distSetEverything(dialogMenuItem *self) XF86Dists = DIST_XF86_ALL; XF86ServerDists = DIST_XF86_SERVER_ALL; XF86FontDists = DIST_XF86_FONTS_ALL; - return distMaybeSetDES(self); + return distMaybeSetDES(self) | distMaybeSetPorts(self); } int @@ -305,6 +306,26 @@ distMaybeSetDES(dialogMenuItem *self) return i | DITEM_RECREATE; } +static int +distMaybeSetPorts(dialogMenuItem *self) +{ + dialog_clear_norefresh(); + if (!msgYesNo("Would you like to install the FreeBSD ports collection?\n\n" + "This will give you ready access to over 800 ported software\n" + "packages, though at the cost of around 35MB of space when \"clean\"\n" + "and possibly much more than that if a lot of the distribution tarballs\n" + "are loaded (unless you have the 2nd CD from a FreeBSD CDROM distribution\n" + "available and can mount it on /cdrom, of course, in which case this is far\n" + "less of a problem).\n\n" + "The ports collection is a very valuable resource and, if you have at least\n" + "100MB to spare in your /usr partition, well worth having around.\n\n" + "For more information on the ports collection, see http://www.freebsd.org/ports\n")) + Dists |= DIST_PORTS; + else + Dists &= ~DIST_PORTS; + return DITEM_SUCCESS | DITEM_RESTORE; +} + int distSetSrc(dialogMenuItem *self) { |