summaryrefslogtreecommitdiffstats
path: root/release
diff options
context:
space:
mode:
authorobrien <obrien@FreeBSD.org>2000-01-18 15:50:23 +0000
committerobrien <obrien@FreeBSD.org>2000-01-18 15:50:23 +0000
commit3005c00a64df52d1c5d631814a99d0c94d7cfee6 (patch)
tree18769371737ce8d99b03509c9081fd93dee80203 /release
parentb6aa8ae2646523b92baa2172c59b27169a90a146 (diff)
downloadFreeBSD-src-3005c00a64df52d1c5d631814a99d0c94d7cfee6.zip
FreeBSD-src-3005c00a64df52d1c5d631814a99d0c94d7cfee6.tar.gz
* add SVR4 and OSF/1 enabling in the Start Up config menu
* deals with X11 install when all we have is the Port (such as on the Alpha) Ok'ed by: JKH
Diffstat (limited to 'release')
-rw-r--r--release/sysinstall/Makefile3
-rw-r--r--release/sysinstall/dist.c18
-rw-r--r--release/sysinstall/install.c17
-rw-r--r--release/sysinstall/menus.c9
-rw-r--r--release/sysinstall/sysinstall.h1
5 files changed, 47 insertions, 1 deletions
diff --git a/release/sysinstall/Makefile b/release/sysinstall/Makefile
index 00c3be2..83ee350 100644
--- a/release/sysinstall/Makefile
+++ b/release/sysinstall/Makefile
@@ -19,6 +19,9 @@ SRCS= anonFTP.c cdrom.c command.c config.c devices.c dhcp.c kget.c \
CFLAGS+= -Wall -I${.CURDIR}/../../gnu/lib/libdialog -I${.OBJDIR}
CFLAGS+= -I${.CURDIR}/../../sys
+.if ${MACHINE_ARCH} != "i386"
+CFLAGS+= -DX_AS_PKG
+.endif
DPADD= ${LIBDIALOG} ${LIBNCURSES} ${LIBMYTINFO} ${LIBUTIL} ${LIBDISK} ${LIBFTPIO}
LDADD= -ldialog -lncurses -lmytinfo -lutil -ldisk -lftpio
diff --git a/release/sysinstall/dist.c b/release/sysinstall/dist.c
index f8639e7..6e4abe2 100644
--- a/release/sysinstall/dist.c
+++ b/release/sysinstall/dist.c
@@ -271,7 +271,10 @@ distSetX(void)
XF86Dists = DIST_XF86_BIN | 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;
+#ifndef X_AS_PKG
return distSetXF86(NULL);
+#endif
+ return DITEM_SUCCESS;
}
int
@@ -850,7 +853,7 @@ printSelected(char *buf, int selected, Distribution *me, int *col)
int
distExtractAll(dialogMenuItem *self)
{
- int old_dists, retries = 0, status = DITEM_SUCCESS;
+ int old_dists, retries = 0, status = DITEM_SUCCESS, want_x_package = 0;
char buf[512];
WINDOW *w;
@@ -869,11 +872,24 @@ distExtractAll(dialogMenuItem *self)
dialog_clear_norefresh();
w = savescr();
msgNotify("Attempting to install all selected distributions..");
+
+#ifdef X_AS_PKG
+ /* Clear any XFree86 dist flags, but remember they were present. */
+ if(Dists & DIST_XF86)
+ want_x_package = 1;
+ Dists &= ~DIST_XF86;
+ /*Dists &= ~(DIST_XF86 | XF86Dists | XF86ServerDists | XF86FontDists);*/
+#endif
/* Try for 3 times around the loop, then give up. */
while (Dists && ++retries < 3)
distExtract(NULL, DistTable);
+#ifdef X_AS_PKG
+ if (want_x_package)
+ status |= installX11package(NULL);
+#endif
+
dialog_clear_norefresh();
/* Only do bin fixup if bin dist was successfully extracted */
if ((old_dists & DIST_BIN) && !(Dists & DIST_BIN))
diff --git a/release/sysinstall/install.c b/release/sysinstall/install.c
index ec508e1..5f187b7 100644
--- a/release/sysinstall/install.c
+++ b/release/sysinstall/install.c
@@ -797,6 +797,21 @@ installFixupBin(dialogMenuItem *self)
return DITEM_SUCCESS | DITEM_RESTORE;
}
+#ifdef X_AS_PKG
+int
+installX11package(dialogMenuItem *self)
+{
+ WINDOW *w = savescr();
+ int i;
+
+ dialog_clear_norefresh();
+ msgNotify("Installing XFree86 package...");
+ i = package_add("XFree86");
+ restorescr(w);
+ return i;
+}
+#endif
+
/* Fix side-effects from the the XFree86 installation */
int
installFixupXFree(dialogMenuItem *self)
@@ -808,12 +823,14 @@ installFixupXFree(dialogMenuItem *self)
vsystem("chmod -R a+r /usr/X11R6");
vsystem("find /usr/X11R6 -type d | xargs chmod a+x");
+#ifndef X_AS_PKG
/* Also do bogus minimal package registration so ports don't whine */
if (file_readable("/usr/X11R6/lib/X11/pkgreg.tar.gz")) {
dialog_clear_norefresh();
msgNotify("Installing package metainfo..");
vsystem("tar xpzf /usr/X11R6/lib/X11/pkgreg.tar.gz -C / && rm /usr/X11R6/lib/X11/pkgreg.tar.gz");
}
+#endif
}
return DITEM_SUCCESS | DITEM_RESTORE;
}
diff --git a/release/sysinstall/menus.c b/release/sysinstall/menus.c
index 47ebafe..55ed712 100644
--- a/release/sysinstall/menus.c
+++ b/release/sysinstall/menus.c
@@ -871,7 +871,11 @@ DMenu MenuSubDistributions = {
{ " local", "Local additions collection",
dmenuFlagCheck, dmenuSetFlag, NULL, &Dists, '[', 'X', ']', DIST_LOCAL},
{ " XFree86", "The XFree86 3.3.6 distribution",
+#ifdef X_AS_PKG
+ dmenuFlagCheck, dmenuSetFlag, NULL, &Dists, '[', 'X', ']', DIST_XF86 },
+#else
x11FlagCheck, distSetXF86 },
+#endif
{ NULL } },
};
@@ -1304,8 +1308,13 @@ DMenu MenuStartup = {
#ifdef __i386__
{ " linux", "This host wants to be able to run linux binaries.",
dmenuVarCheck, configLinux, NULL, VAR_LINUX_ENABLE "=YES" },
+ { " SVR4", "This host wants to be able to run SVR4 binaries.",
+ dmenuVarCheck, dmenuToggleVariable, NULL, "svr4_enable=YES" },
{ " SCO", "This host wants to be able to run IBCS2 binaries.",
dmenuVarCheck, dmenuToggleVariable, NULL, "ibcs2_enable=YES" },
+#elif __alpha__
+ { " OSF/1", "This host wants to be able to run DEC OSF/1 binaries.",
+ dmenuVarCheck, dmenuToggleVariable, NULL, "osf1_enable=YES" },
#endif
{ " quotas", "This host wishes to check quotas on startup.",
dmenuVarCheck, dmenuToggleVariable, NULL, "check_quotas=YES" },
diff --git a/release/sysinstall/sysinstall.h b/release/sysinstall/sysinstall.h
index 43eeab0..c395785 100644
--- a/release/sysinstall/sysinstall.h
+++ b/release/sysinstall/sysinstall.h
@@ -568,6 +568,7 @@ extern int installUpgrade(dialogMenuItem *self);
extern int installFilesystems(dialogMenuItem *self);
extern int installVarDefaults(dialogMenuItem *self);
extern void installEnvironment(void);
+extern int installX11package(dialogMenuItem *self);
extern Boolean copySelf(void);
/* kget.c */
OpenPOWER on IntegriCloud