Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=setup.git;a=commitdiff;h=21f47974d8de4ea64c49c13f830d5b22cc4a198c

commit 21f47974d8de4ea64c49c13f830d5b22cc4a198c
Author: Elentir <elen...@mailoo.org>
Date:   Wed Mar 10 21:29:26 2010 +0100

use udhcpc for dhcp autodetection in gui initscript

diff --git a/gui/start.sh b/gui/start.sh
index af24d7c..4f7a666 100644
--- a/gui/start.sh
+++ b/gui/start.sh
@@ -177,8 +177,18 @@ export DISPLAY=:0
MOUSE=/dev/input/mice

## launch dhcpcd, if an interface is finded it'll be detected by fwife, so the 
user don't need to configure it
-echo " * Starting dhcpcd.."
-dhcpcd -b -L -t 15
+echo " * Starting dhcp.."
+mkdir -p /var/run/dhcpcd/resolv.conf/
+listiface=`ls /sys/class/net`
+for i in $listiface; do
+       ifconfig $i up
+       udhcpc -n -t 2 -i $i
+       if [[ "$?" == "0" ]]; then
+               # used by fwife to find working dhcp connection
+               touch /var/run/dhcpcd/resolv.conf/$i
+               break
+       fi
+done

echo " * Parsing kernel cmdline for Fwife options.."
_______________________________________________
Frugalware-git mailing list
Frugalware-git@frugalware.org
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to