summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGwenolé Beauchesne <gbeauchesne@mandriva.org>2002-10-09 13:23:04 +0000
committerGwenolé Beauchesne <gbeauchesne@mandriva.org>2002-10-09 13:23:04 +0000
commitf8c790f01aa82ff97814e3abf6acde146f1312fd (patch)
treef17fc34a8d2910bb82cb05f5f76508ff0dc5aa6d
parent67b2399796a1fd5e2b7301a7a2c844ed76cb7252 (diff)
downloaddrakx-f8c790f01aa82ff97814e3abf6acde146f1312fd.tar
drakx-f8c790f01aa82ff97814e3abf6acde146f1312fd.tar.gz
drakx-f8c790f01aa82ff97814e3abf6acde146f1312fd.tar.bz2
drakx-f8c790f01aa82ff97814e3abf6acde146f1312fd.tar.xz
drakx-f8c790f01aa82ff97814e3abf6acde146f1312fd.zip
lib64 support
-rw-r--r--mdk-stage1/rescue-gui.c18
1 files changed, 14 insertions, 4 deletions
diff --git a/mdk-stage1/rescue-gui.c b/mdk-stage1/rescue-gui.c
index 240d7ccba..dbe12cb4a 100644
--- a/mdk-stage1/rescue-gui.c
+++ b/mdk-stage1/rescue-gui.c
@@ -34,14 +34,24 @@
char * env[] = {
"PATH=/usr/bin:/bin:/sbin:/usr/sbin:/mnt/sbin:/mnt/usr/sbin:/mnt/bin:/mnt/usr/bin",
- "LD_LIBRARY_PATH=/lib:/usr/lib:/mnt/lib:/mnt/usr/lib:/usr/X11R6/lib:/mnt/usr/X11R6/lib",
+ "LD_LIBRARY_PATH=/lib:/usr/lib:/mnt/lib:/mnt/usr/lib:/usr/X11R6/lib:/mnt/usr/X11R6/lib"
+#if defined(__x86_64__) || defined(__ppc64__)
+ ":/lib64:/usr/lib64:/usr/X11R6/lib64:/mnt/lib64:/mnt/usr/lib64:/mnt/usr/X11R6/lib64"
+#endif
+ ,
"HOME=/",
"TERM=linux",
"TERMINFO=/etc/terminfo",
NULL
};
-void pause(void) { unsigned char t; fflush(stdout); read(0, &t, 1); }
+/* pause() already exists and causes the invoking process to sleep
+ until a signal is received */
+static void PAUSE(void) {
+ unsigned char t;
+ fflush(stdout);
+ read(0, &t, 1);
+}
/* ------ UUURGH this is duplicated from `init.c', don't edit here........ */
@@ -202,13 +212,13 @@ int main(int argc __attribute__ ((unused)), char **argv __attribute__ ((unused))
execve(child_argv[0], child_argv, env);
printf("Can't execute binary (%s)\n<press Enter>\n", binary);
- pause();
+ PAUSE();
return 33;
}
while (wait4(-1, &wait_status, 0, NULL) != pid) {};
printf("<press Enter to return to Rescue GUI>");
- pause();
+ PAUSE();
resume_from_suspend();
if (!WIFEXITED(wait_status) || WEXITSTATUS(wait_status) != 0) {
error_message("Program exited abnormally (return code %d).", WEXITSTATUS(wait_status));