summaryrefslogtreecommitdiffstats
path: root/xserver.py
diff options
context:
space:
mode:
authorbfox <bfox>2000-11-20 15:23:26 +0000
committerbfox <bfox>2000-11-20 15:23:26 +0000
commit191867a14bd6de2a9bdb385741fc4308a539d17b (patch)
tree8e7339b88b1fe937ebf27fd3fe71982a6bd77e2e /xserver.py
parent3a95635fc82cfca64545d362a6118f9d1ec19b24 (diff)
downloadanaconda-191867a14bd6de2a9bdb385741fc4308a539d17b.tar.gz
anaconda-191867a14bd6de2a9bdb385741fc4308a539d17b.tar.xz
anaconda-191867a14bd6de2a9bdb385741fc4308a539d17b.zip
Fixed nagging syntax error
Diffstat (limited to 'xserver.py')
-rw-r--r--xserver.py128
1 files changed, 1 insertions, 127 deletions
diff --git a/xserver.py b/xserver.py
index 7e52dfd28..d164c63f8 100644
--- a/xserver.py
+++ b/xserver.py
@@ -84,11 +84,7 @@ def startX():
if x.server:
serverPath = '/usr/X11R6/bin/' + x.server
-# serverPath = '/usr/X11R6/bin/XF86_FBDev'
print "Using X server", serverPath
-# print "Sleeping 4 seconds"
-# time.sleep(4)
-
elif iutil.getArch() == "sparc":
raise RuntimeError, "Unknown card"
@@ -102,144 +98,28 @@ def startX():
x.server = probedServer
print "Frame buffer didn't work...trying ", x.server
serverPath = '/usr/X11R6/bin/' + x.server
-# print "Sleeping 4 seconds"
-# time.sleep(4)
+
if not os.access (serverPath, os.X_OK): #--If original server isn't there...send them to text mode
print serverPath, "missing. Falling back to text mode"
raise RuntimeError, "No X server binaries found to run"
-# print "Sleeping 4 seconds"
-# time.sleep(4)
-
-
-
-
-
-
-# if not os.access (serverPath, os.X_OK):
-# if iutil.getArch() == "sparc":
-# raise RuntimeError, "Missing X server"
-# print serverPath, "missing. Falling back to VGA16"
-# x.server = "XF86_VGA16"
-# serverPath = '/usr/X11R6/bin/XF86_VGA16'
-
-# if not os.access (serverPath, os.X_OK):
-# print serverPath, "missing. Falling back to text mode"
-# print "Sleeping 7 seconds"
-# time.sleep(7)
-# raise RuntimeError, "No X server binaries found to run"
-
-# print x.test
-# print "Sleeping 7 seconds"
-# time.sleep(7)
-
-
-# server = x.test ([':1', 'vt7', '-s', '1440', '-terminate'], spawn=1)
-
-
try:
fbdevice = open("/dev/fb0", "r") #-- If can't access /dev/fb0, we're not in framebuffer mode
fbdevice.close()
-# print "About to test frame buffer mode"
-# print "Currently x.server is ", x.server
-# print "Sleeping 5 seconds"
-# time.sleep(5)
testx(mouse, x)
except:
try:
-# print "Framebuffer test didn't work"
-# print "Trying original probed server ", probedServer
x.server = probedServer
-
-# print "Currently x.server is ", x.server
-# print "Sleeping 5 seconds"
-# time.sleep(5)
-
testx(mouse, x)
-# print "Sleeping 10 seconds"
-# time.sleep(10)
- except:
- pass
-# try:
-# print "Skipping VGA16"
-
- #XXX - VGA16 can't do 800x600, so don't even try. Fall back to text instead
-# print "Original probed server ", probedServer, " didn't work."
-# print "Trying XF86_VGA16"
-# x.server = "XF86_VGA16"
-# server = test(mouse, x)
-
-# print "Currently x.server is ", x.server
-# print "Sleeping 5 seconds"
-# time.sleep(5)
-
-# testx(mouse, x)
-# print "Sleeping 15 seconds"
-# time.sleep(15)
-# except:
-# pass
-# print x.server, "didn't work...falling back to text mode"
-# print "Sleeping 30 seconds"
-# time.sleep(30)
-
-
-
- # give time for the server to fail (if it is going to fail...)
- # FIXME: Should find out if X server is already running
- # otherwise with NFS installs the X server may be still being
- # fetched from the network while we already continue to run
-# time.sleep (4)
-# count = 0
-
-# print "Sleeping 3 seconds"
-# time.sleep(3)
-
-
-# sys.stdout.write("Waiting for X server to start")
-# sys.stdout.flush()
-# while count < 60:
-# sys.stdout.write(".")
-# sys.stdout.flush()
-# pid, status = os.waitpid (server, os.WNOHANG)
-# if status:
-# raise RuntimeError, "X server failed to start"
-# try:
-# os.stat ("/tmp/.X11-unix/X1")
-# print
-# break
-# except OSError:
-# pass
-# time.sleep(1)
-# count = count + 1
-
-# child = os.fork()
-# if (child):
-# try:
-# pid, status = os.waitpid(child, 0)
-# except:
-# sys.exit (-1)
-# try:
-# sys.kill(server, 15)
-# pid, status = os.waitpid(server, 0)
-# except:
-# sys.exit(0)
-
-# sys.exit((status >> 8) & 0xf)
return (mouse, x)
def testx(mouse, x):
try:
-# print "Inisde testx...trying with server: ", x.server
-
-# print "Sleeping 5 seconds"
-# time.sleep(5)
-
server = x.test ([':1', 'vt7', '-s', '1440', '-terminate'], spawn=1)
-# return server
# give time for the server to fail (if it is going to fail...)
# FIXME: Should find out if X server is already running
@@ -249,10 +129,6 @@ def testx(mouse, x):
time.sleep (4)
count = 0
-# print "Sleeping 3 seconds"
-# time.sleep(3)
-
-
sys.stdout.write("Waiting for X server to start")
sys.stdout.flush()
while count < 60:
@@ -285,8 +161,6 @@ def testx(mouse, x):
sys.exit((status >> 8) & 0xf)
-# return (mouse, x)
-
except:
raise RuntimeError, "X server failed to start"