John Quigley jmquigs at
Thu Apr 3 12:00:10 EST 2003

The current script tries to launch setup.gtk, and if that program 
fails and returns 2, it runs the console setup program.  However, if setup.gtk 
fails because a dynamic library (e.g.: gtk) is missing, it will set $? to 127 
(on my system).  Thus the console program won't run and the install will fail.
This can happen if, for instance, you are running the installer 
on a machine without a complete windowing system.

I changed it as listed below, and it seems to work.  Setup will return 3 if it is
aborted, in that case we don't want to run console installer.  
I guess I could instead add a check for 127, but I'm not sure if all dynamic 
loaders will return that...


RCS file: /cvs/cvsroot/loki_setup/image/,v
retrieving revision 1.13
diff -u -w -r1.13
---	2002/12/07 00:57:32	1.13
+++	2003/04/03 16:54:44
@@ -249,7 +249,8 @@
 # Try to run the setup program
 try_run setup.gtk $args $*
-if [ $status -eq 2 ]; then  # setup.gtk couldn't connect to X11 server - ignore
+if [ ! $status -eq 0 ] && [ ! $status -eq 3 ]; then 
+        # setup.gtk failed to run (it returns 3 if aborted)
 	try_run -fatal setup $args $* || {
 		# NOTE TTimo: with -fatal working correctly, this never happens
 		echo "The setup program seems to have failed on $arch/$libc"

More information about the Lokisetup mailing list