#! /bin/sh set -e set -x # Set up the ethernet. cat >/etc/sysconfig/network-scripts/ifcfg-eth0 </etc/sysconfig/network </etc/hosts <) { $in = 1 if /^Section "Device"/; $in = 0 if /^EndSection/; if ($in == 1) { s/VendorName\s.*/VendorName "Cirrus Logic"/; s/BoardName\s.*/BoardName "Cirrus Logic GD544x"/; s/Driver\s.*/Driver "cirrus"/; }; print; }' -i /etc/X11/xorg.conf /etc/init.d/dm restart echo set +e # Wait for vncviewer. count=20 while test $count -gt 0; do pid="`/sbin/pidof vncviewer`" if test "x$pid" = x; then sleep 1 else break fi count=`expr $count - 1` done if test $count -eq 0; then echo 'vncviewer did not start' exit 1 fi exit 0