Fix a couple of bogons in the X server/desktop setup menus.

This commit is contained in:
Jordan K. Hubbard 1999-05-12 04:52:41 +00:00
parent 4a79c0bea3
commit 703e69c29c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=47036
6 changed files with 60 additions and 27 deletions

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: config.c,v 1.128 1999/04/28 07:20:11 jkh Exp $
* $Id: config.c,v 1.129 1999/05/05 11:34:00 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -522,20 +522,28 @@ configXDesktop(dialogMenuItem *self)
int
configXSetup(dialogMenuItem *self)
{
char *config, *execfile;
char *config, *execfile, *style;
char *moused;
tryagain:
dialog_clear_norefresh();
variable_unset(VAR_DESKSTYLE);
variable_unset(VAR_XF86_CONFIG);
if (!dmenuOpenSimple(&MenuXF86Config, FALSE))
return DITEM_FAILURE | DITEM_RESTORE;
config = variable_get(VAR_XF86_CONFIG);
style = variable_get(VAR_DESKSTYLE);
if (!config) {
if (style)
goto config_desktop;
else
return DITEM_FAILURE | DITEM_RESTORE;
}
if (file_readable("/var/run/ld.so.hints"))
systemExecute("/sbin/ldconfig -m /usr/lib /usr/X11R6/lib /usr/local/lib /usr/lib/compat");
else
systemExecute("/sbin/ldconfig /usr/lib /usr/X11R6/lib /usr/local/lib /usr/lib/compat");
config = variable_get(VAR_XF86_CONFIG);
if (!config)
return DITEM_FAILURE | DITEM_RESTORE;
execfile = string_concat("/usr/X11R6/bin/", config);
if (file_executable(execfile)) {
dialog_clear_norefresh();
@ -564,6 +572,7 @@ tryagain:
else
return DITEM_FAILURE | DITEM_RESTORE;
}
config_desktop:
configXDesktop(self);
return DITEM_SUCCESS | DITEM_RESTORE;
}

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: menus.c,v 1.198 1999/05/05 11:34:03 jkh Exp $
* $Id: menus.c,v 1.199 1999/05/11 08:33:45 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -1189,10 +1189,12 @@ DMenu MenuConfigure = {
NULL, dmenuSubmenu, NULL, &MenuStartup },
{ "8 Options", "View/Set various installation options",
NULL, optionsEditor },
{ "D HTML Docs", "Go to the HTML documentation menu (post-install)",
NULL, docBrowser },
{ "X XFree86", "Configure XFree86",
{ "X XFree86", "Configure XFree86 Server",
NULL, configXSetup },
{ "X Desktop", "Configure XFree86 Desktop",
NULL, configXDesktop },
{ "H HTML Docs", "Go to the HTML documentation menu (post-install)",
NULL, docBrowser },
{ "E Exit", "Exit this menu (returning to previous)",
NULL, dmenuExit },
{ NULL } },

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: config.c,v 1.128 1999/04/28 07:20:11 jkh Exp $
* $Id: config.c,v 1.129 1999/05/05 11:34:00 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -522,20 +522,28 @@ configXDesktop(dialogMenuItem *self)
int
configXSetup(dialogMenuItem *self)
{
char *config, *execfile;
char *config, *execfile, *style;
char *moused;
tryagain:
dialog_clear_norefresh();
variable_unset(VAR_DESKSTYLE);
variable_unset(VAR_XF86_CONFIG);
if (!dmenuOpenSimple(&MenuXF86Config, FALSE))
return DITEM_FAILURE | DITEM_RESTORE;
config = variable_get(VAR_XF86_CONFIG);
style = variable_get(VAR_DESKSTYLE);
if (!config) {
if (style)
goto config_desktop;
else
return DITEM_FAILURE | DITEM_RESTORE;
}
if (file_readable("/var/run/ld.so.hints"))
systemExecute("/sbin/ldconfig -m /usr/lib /usr/X11R6/lib /usr/local/lib /usr/lib/compat");
else
systemExecute("/sbin/ldconfig /usr/lib /usr/X11R6/lib /usr/local/lib /usr/lib/compat");
config = variable_get(VAR_XF86_CONFIG);
if (!config)
return DITEM_FAILURE | DITEM_RESTORE;
execfile = string_concat("/usr/X11R6/bin/", config);
if (file_executable(execfile)) {
dialog_clear_norefresh();
@ -564,6 +572,7 @@ tryagain:
else
return DITEM_FAILURE | DITEM_RESTORE;
}
config_desktop:
configXDesktop(self);
return DITEM_SUCCESS | DITEM_RESTORE;
}

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: menus.c,v 1.198 1999/05/05 11:34:03 jkh Exp $
* $Id: menus.c,v 1.199 1999/05/11 08:33:45 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -1189,10 +1189,12 @@ DMenu MenuConfigure = {
NULL, dmenuSubmenu, NULL, &MenuStartup },
{ "8 Options", "View/Set various installation options",
NULL, optionsEditor },
{ "D HTML Docs", "Go to the HTML documentation menu (post-install)",
NULL, docBrowser },
{ "X XFree86", "Configure XFree86",
{ "X XFree86", "Configure XFree86 Server",
NULL, configXSetup },
{ "X Desktop", "Configure XFree86 Desktop",
NULL, configXDesktop },
{ "H HTML Docs", "Go to the HTML documentation menu (post-install)",
NULL, docBrowser },
{ "E Exit", "Exit this menu (returning to previous)",
NULL, dmenuExit },
{ NULL } },

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: config.c,v 1.128 1999/04/28 07:20:11 jkh Exp $
* $Id: config.c,v 1.129 1999/05/05 11:34:00 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -522,20 +522,28 @@ configXDesktop(dialogMenuItem *self)
int
configXSetup(dialogMenuItem *self)
{
char *config, *execfile;
char *config, *execfile, *style;
char *moused;
tryagain:
dialog_clear_norefresh();
variable_unset(VAR_DESKSTYLE);
variable_unset(VAR_XF86_CONFIG);
if (!dmenuOpenSimple(&MenuXF86Config, FALSE))
return DITEM_FAILURE | DITEM_RESTORE;
config = variable_get(VAR_XF86_CONFIG);
style = variable_get(VAR_DESKSTYLE);
if (!config) {
if (style)
goto config_desktop;
else
return DITEM_FAILURE | DITEM_RESTORE;
}
if (file_readable("/var/run/ld.so.hints"))
systemExecute("/sbin/ldconfig -m /usr/lib /usr/X11R6/lib /usr/local/lib /usr/lib/compat");
else
systemExecute("/sbin/ldconfig /usr/lib /usr/X11R6/lib /usr/local/lib /usr/lib/compat");
config = variable_get(VAR_XF86_CONFIG);
if (!config)
return DITEM_FAILURE | DITEM_RESTORE;
execfile = string_concat("/usr/X11R6/bin/", config);
if (file_executable(execfile)) {
dialog_clear_norefresh();
@ -564,6 +572,7 @@ tryagain:
else
return DITEM_FAILURE | DITEM_RESTORE;
}
config_desktop:
configXDesktop(self);
return DITEM_SUCCESS | DITEM_RESTORE;
}

View File

@ -4,7 +4,7 @@
* This is probably the last program in the `sysinstall' line - the next
* generation being essentially a complete rewrite.
*
* $Id: menus.c,v 1.198 1999/05/05 11:34:03 jkh Exp $
* $Id: menus.c,v 1.199 1999/05/11 08:33:45 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -1189,10 +1189,12 @@ DMenu MenuConfigure = {
NULL, dmenuSubmenu, NULL, &MenuStartup },
{ "8 Options", "View/Set various installation options",
NULL, optionsEditor },
{ "D HTML Docs", "Go to the HTML documentation menu (post-install)",
NULL, docBrowser },
{ "X XFree86", "Configure XFree86",
{ "X XFree86", "Configure XFree86 Server",
NULL, configXSetup },
{ "X Desktop", "Configure XFree86 Desktop",
NULL, configXDesktop },
{ "H HTML Docs", "Go to the HTML documentation menu (post-install)",
NULL, docBrowser },
{ "E Exit", "Exit this menu (returning to previous)",
NULL, dmenuExit },
{ NULL } },