diff options
author | Wolfram Schlich <wschlich@gentoo.org> | 2003-10-23 10:03:25 +0000 |
---|---|---|
committer | Wolfram Schlich <wschlich@gentoo.org> | 2003-10-23 10:03:25 +0000 |
commit | be08540095bf3f664298233f22f64fd2175f4b93 (patch) | |
tree | 7f1a263b4daab0e82191f694c8772efff2534fdf /net-wireless | |
parent | Makefile fix (#31801) (diff) | |
download | gentoo-2-be08540095bf3f664298233f22f64fd2175f4b93.tar.gz gentoo-2-be08540095bf3f664298233f22f64fd2175f4b93.tar.bz2 gentoo-2-be08540095bf3f664298233f22f64fd2175f4b93.zip |
HostAPD init script was missing - added
Diffstat (limited to 'net-wireless')
-rw-r--r-- | net-wireless/hostapd/Manifest | 5 | ||||
-rw-r--r-- | net-wireless/hostapd/files/hostapd.init.d | 44 |
2 files changed, 47 insertions, 2 deletions
diff --git a/net-wireless/hostapd/Manifest b/net-wireless/hostapd/Manifest index a87c2313803c..a7e88906319a 100644 --- a/net-wireless/hostapd/Manifest +++ b/net-wireless/hostapd/Manifest @@ -1,4 +1,5 @@ -MD5 2c7374804e416ce15c40a9623c031d1f metadata.xml 462 -MD5 127f9ab6fcde19362c667d4653bf3e49 hostapd-0.1.0.ebuild 1080 MD5 f6a67e02632302791715e8897b683793 ChangeLog 363 +MD5 127f9ab6fcde19362c667d4653bf3e49 hostapd-0.1.0.ebuild 1080 +MD5 2c7374804e416ce15c40a9623c031d1f metadata.xml 462 +MD5 cf287b50f0ccd832a08fb3031281cd4f files/hostapd.init.d 858 MD5 ebaf0a97df860deb10127e44d8c9f4de files/digest-hostapd-0.1.0 64 diff --git a/net-wireless/hostapd/files/hostapd.init.d b/net-wireless/hostapd/files/hostapd.init.d new file mode 100644 index 000000000000..994942ee3e8a --- /dev/null +++ b/net-wireless/hostapd/files/hostapd.init.d @@ -0,0 +1,44 @@ +#!/sbin/runscript + +svc_name="HostAPD" + +hostapd="/usr/sbin/hostapd" +hostapd_cfg="/etc/hostapd/hostapd.conf" + +opts="${opts} reload" + +depend() { + ## if necessary change net.wlan0 to your wlan device + need net.wlan0 logger +} + +checkconfig() { + if [ ! -x "${hostapd}" ]; then + eerror "HostAPD binary [${hostapd}] missing" + fi + if [ ! -r "${hostapd_cfg}" ] ; then + eerror "HostAPD config [${hostapd_cfg}] missing" + return 1 + fi +} + +start() { + checkconfig || return 1 + ebegin "Starting ${svc_name}" + start-stop-daemon --start --quiet --exec "${hostapd}" -- -B "${hostapd_cfg}" + eend $? +} + +stop() { + checkconfig || return 1 + ebegin "Stopping ${svc_name}" + start-stop-daemon --stop --quiet --exec "${hostapd}" + eend $? +} + +reload() { + checkconfig || return 1 + ebegin "Reloading ${svc_name}" + start-stop-daemon --stop --signal 1 --quiet --exec "${hostapd}" + eend $? +} |