summaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/wireless-tools
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@linux.intel.com>2010-08-27 14:14:24 (GMT)
committerRichard Purdie <rpurdie@linux.intel.com>2010-08-27 14:29:45 (GMT)
commit29d6678fd546377459ef75cf54abeef5b969b5cf (patch)
tree8edd65790e37a00d01c3f203f773fe4b5012db18 /meta/recipes-connectivity/wireless-tools
parentda49de6885ee1bc424e70bc02f21f6ab920efb55 (diff)
downloadpoky-29d6678fd546377459ef75cf54abeef5b969b5cf.tar.gz
Major layout change to the packages directory
Having one monolithic packages directory makes it hard to find things and is generally overwhelming. This commit splits it into several logical sections roughly based on function, recipes.txt gives more information about the classifications used. The opportunity is also used to switch from "packages" to "recipes" as used in OpenEmbedded as the term "packages" can be confusing to people and has many different meanings. Not all recipes have been classified yet, this is just a first pass at separating things out. Some packages are moved to meta-extras as they're no longer actively used or maintained. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'meta/recipes-connectivity/wireless-tools')
-rw-r--r--meta/recipes-connectivity/wireless-tools/wireless-tools/man.patch13
-rwxr-xr-xmeta/recipes-connectivity/wireless-tools/wireless-tools/wireless-tools.if-pre-up122
-rw-r--r--meta/recipes-connectivity/wireless-tools/wireless-tools/zzz-wireless.if-pre-up34
-rw-r--r--meta/recipes-connectivity/wireless-tools/wireless-tools_29.bb51
4 files changed, 220 insertions, 0 deletions
diff --git a/meta/recipes-connectivity/wireless-tools/wireless-tools/man.patch b/meta/recipes-connectivity/wireless-tools/wireless-tools/man.patch
new file mode 100644
index 0000000..fd8cf42
--- /dev/null
+++ b/meta/recipes-connectivity/wireless-tools/wireless-tools/man.patch
@@ -0,0 +1,13 @@
1--- wireless_tools.26/Makefile.orig 2003-06-18 03:38:58.000000000 +0200
2+++ wireless_tools.26/Makefile 2004-07-03 23:35:29.000000000 +0200
3@@ -57,8 +57,8 @@
4 # Install directories
5 INSTALL_DIR= $(PREFIX)/sbin/
6 INSTALL_LIB= $(PREFIX)/lib/
7-INSTALL_INC= $(PREFIX)/include/
8-INSTALL_MAN= $(PREFIX)/man/
9+INSTALL_INC= $(PREFIX)/usr/include/
10+INSTALL_MAN= $(PREFIX)/usr/share/man/
11
12 # Use local header if the version of wireless extensions is specified
13 ifdef FORCE_WEXT_VERSION
diff --git a/meta/recipes-connectivity/wireless-tools/wireless-tools/wireless-tools.if-pre-up b/meta/recipes-connectivity/wireless-tools/wireless-tools/wireless-tools.if-pre-up
new file mode 100755
index 0000000..2518a5c
--- /dev/null
+++ b/meta/recipes-connectivity/wireless-tools/wireless-tools/wireless-tools.if-pre-up
@@ -0,0 +1,122 @@
1#!/bin/sh
2
3case "$METHOD" in loopback) exit 0 ;; esac
4
5IWCONFIG=/sbin/iwconfig
6IWPRIV=/sbin/iwpriv
7
8if [ ! -x $IWCONFIG ]; then
9 exit 0
10fi
11
12# Detect and do nothing for linux-wlan-ng interfaces;
13# which are configured by thier own if-pre-up script.
14if [ -n "$IF_WIRELESS_TYPE" -a "$IF_WIRELESS_TYPE" = "wlan-ng" ]; then
15 exit 0
16fi
17
18if [ -n "$IF_NEEDS_RESET" ]; then
19 $IWPRIV "$IFACE" reset 1
20 sleep 1
21fi
22
23if [ -n "$IF_NEEDS_FIRMWARE" ]; then
24 $IF_NEEDS_FIRMWARE "$IFACE"
25fi
26
27if [ -n "$IF_WIRELESS_SENS" ]; then
28 $IWCONFIG "$IFACE" sens $IF_WIRELESS_SENS
29fi
30
31if [ -n "$IF_WIRELESS_RATE" ]; then
32 $IWCONFIG "$IFACE" rate $IF_WIRELESS_RATE
33fi
34
35if [ -n "$IF_WIRELESS_RTS" ]; then
36 $IWCONFIG "$IFACE" rts $IF_WIRELESS_RTS
37fi
38
39if [ -n "$IF_WIRELESS_FRAG" ]; then
40 $IWCONFIG "$IFACE" frag $IF_WIRELESS_FRAG
41fi
42
43if [ -n "$IF_WIRELESS_POWER" ]; then
44 $IWCONFIG "$IFACE" power $IF_WIRELESS_POWER
45fi
46
47if [ -n "$IF_WIRELESS_POWERPERIOD" ]; then
48 $IWCONFIG "$IFACE" power period $IF_WIRELESS_POWERPERIOD
49fi
50
51if [ -n "$IF_WIRELESS_POWERTIMEOUT" ]; then
52 $IWCONFIG "$IFACE" power timeout $IF_WIRELESS_POWERTIMEOUT
53fi
54
55if [ -n "$IF_WIRELESS_TXPOWER" ]; then
56 $IWCONFIG "$IFACE" txpower $IF_WIRELESS_TXPOWER
57fi
58
59if [ -n "$IF_WIRELESS_RETRY" ]; then
60 $IWCONFIG "$IFACE" retry $IF_WIRELESS_RETRY
61fi
62
63if [ -n "$IF_WIRELESS_NICK" ]; then
64 $IWCONFIG "$IFACE" nick "$IF_WIRELESS_NICK"
65fi
66
67if [ -n "$IF_WIRELESS_NWID" ]; then
68 $IWCONFIG "$IFACE" nwid "$IF_WIRELESS_NWID"
69fi
70
71if [ -n "$IF_WIRELESS_ENC" ]; then
72 eval $IWCONFIG "$IFACE" enc $IF_WIRELESS_ENC
73fi
74
75if [ -n "$IF_WIRELESS_KEY" ]; then
76 eval $IWCONFIG "$IFACE" key $IF_WIRELESS_KEY
77fi
78
79if [ -n "$IF_WIRELESS_KEY1" ]; then
80 $IWCONFIG "$IFACE" key [1] "$IF_WIRELESS_KEY1"
81fi
82
83if [ -n "$IF_WIRELESS_KEY2" ]; then
84 $IWCONFIG "$IFACE" key [2] "$IF_WIRELESS_KEY2"
85fi
86
87if [ -n "$IF_WIRELESS_KEY3" ]; then
88 $IWCONFIG "$IFACE" key [3] "$IF_WIRELESS_KEY3"
89fi
90
91if [ -n "$IF_WIRELESS_KEY4" ]; then
92 $IWCONFIG "$IFACE" key [4] "$IF_WIRELESS_KEY4"
93fi
94
95if [ -n "$IF_WIRELESS_DEFAULTKEY" ]; then
96 $IWCONFIG "$IFACE" key ["$IF_WIRELESS_DEFAULTKEY"]
97fi
98
99if [ -n "$IF_WIRELESS_KEYMODE" ]; then
100 $IWCONFIG "$IFACE" key "$IF_WIRELESS_KEYMODE"
101fi
102
103if [ -n "$IF_WIRELESS_MODE" ]; then
104 $IWCONFIG "$IFACE" mode $IF_WIRELESS_MODE
105fi
106
107if [ -n "$IF_WIRELESS_FREQ" ]; then
108 $IWCONFIG "$IFACE" freq $IF_WIRELESS_FREQ
109fi
110
111if [ -n "$IF_WIRELESS_CHANNEL" ]; then
112 $IWCONFIG "$IFACE" channel $IF_WIRELESS_CHANNEL
113fi
114
115if [ -n "$IF_WIRELESS_ESSID" ]; then
116 $IWCONFIG "$IFACE" essid "$IF_WIRELESS_ESSID"
117fi
118
119if [ -n "$IF_WIRELESS_COMMIT" ]; then
120 $IWCONFIG "$IFACE" commit
121fi
122
diff --git a/meta/recipes-connectivity/wireless-tools/wireless-tools/zzz-wireless.if-pre-up b/meta/recipes-connectivity/wireless-tools/wireless-tools/zzz-wireless.if-pre-up
new file mode 100644
index 0000000..4c8e95b
--- /dev/null
+++ b/meta/recipes-connectivity/wireless-tools/wireless-tools/zzz-wireless.if-pre-up
@@ -0,0 +1,34 @@
1#!/bin/sh
2#
3# /etc/network/if-pre-up.d/zzz-wireless
4# by Stefan Tomanek (stefan@pico.ruhr.de)
5
6
7IWCONFIG=/sbin/iwconfig
8IFCONFIG=/sbin/ifconfig
9GREP=/bin/grep
10LOGGER=/usr/bin/logger
11SLEEP=/bin/sleep
12
13# How long do we wait for association?
14RETRIES=15
15SLEEPTIME=1
16
17# Only sleep if we use DHCP (add others methods seperated by spaces)
18ONLY_FOR="static dhcp"
19
20if [ -z "$IF_WIRELESS_TYPE" ] && echo "$ONLY_FOR" | grep -q "$METHOD" ; then
21 $IFCONFIG $IFACE up
22 $LOGGER Checking for WLAN association...
23 while ( [ $RETRIES -gt 0 ] && ($IWCONFIG "$IFACE" | $GREP -q "Access Point: Not-Associated") ); do
24 $LOGGER No association yet, $RETRIES retries until timeout
25 RETRIES=$(($RETRIES-1))
26 $SLEEP $SLEEPTIME
27 done
28
29 if [ $RETRIES -eq 0 ]; then
30 $LOGGER Timeout waiting for association, continuing anyway...
31 else
32 $LOGGER Found association!
33 fi
34fi
diff --git a/meta/recipes-connectivity/wireless-tools/wireless-tools_29.bb b/meta/recipes-connectivity/wireless-tools/wireless-tools_29.bb
new file mode 100644
index 0000000..6bb1193
--- /dev/null
+++ b/meta/recipes-connectivity/wireless-tools/wireless-tools_29.bb
@@ -0,0 +1,51 @@
1DESCRIPTION = "Tools for the Linux Standard Wireless Extension Subsystem"
2HOMEPAGE = "http://www.hpl.hp.com/personal/Jean_Tourrilhes/Linux/Tools.html"
3LICENSE = "GPLv2 & (LGPL | MPL | BSD)"
4LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
5 file://iwconfig.c;beginline=1;endline=12;md5=cf710eb1795c376eb10ea4ff04649caf \
6 file://iwevent.c;beginline=59;endline=72;md5=d66a10026d4394f0a5b1c5587bce4537 \
7 file://sample_enc.c;beginline=1;endline=4;md5=838372be07874260b566bae2f6ed33b6"
8SECTION = "base"
9PRIORITY = "optional"
10PE = "1"
11PR = "r1"
12
13SRC_URI = "http://www.hpl.hp.com/personal/Jean_Tourrilhes/Linux/wireless_tools.29.tar.gz \
14 file://man.patch;apply=yes \
15 file://wireless-tools.if-pre-up \
16 file://zzz-wireless.if-pre-up"
17S = "${WORKDIR}/wireless_tools.29"
18
19CFLAGS =+ "-I${S}"
20EXTRA_OEMAKE = "-e 'BUILD_SHARED=y' \
21 'INSTALL_DIR=${D}${base_sbindir}' \
22 'INSTALL_LIB=${D}${libdir}' \
23 'INSTALL_INC=${D}${includedir}' \
24 'INSTALL_MAN=${D}${mandir}'"
25
26do_compile() {
27 oe_runmake all libiw.a
28}
29
30do_install() {
31 oe_runmake PREFIX=${D} install-iwmulticall install-dynamic install-man install-hdr
32 install -d ${D}${sbindir}
33 install -m 0755 ifrename ${D}${sbindir}/ifrename
34 # Disabled by RP - 20/8/08 - We don't seem to need/use these
35 #install -d ${D}${sysconfdir}/network/if-pre-up.d
36 #install ${WORKDIR}/wireless-tools.if-pre-up ${D}${sysconfdir}/network/if-pre-up.d/wireless-tools
37 #install ${WORKDIR}/zzz-wireless.if-pre-up ${D}${sysconfdir}/network/if-pre-up.d/zzz-wireless
38}
39
40PACKAGES = "libiw-dbg ifrename-dbg ${PN}-dbg \
41libiw libiw-dev libiw-doc ifrename-doc ifrename ${PN} ${PN}-doc"
42
43FILES_libiw-dbg = "${libdir}/.debug/*.so.*"
44FILES_ifrename-dbg = "${sbindir}/.debug/ifrename"
45FILES_libiw = "${libdir}/*.so.*"
46FILES_libiw-dev = "${libdir}/*.a ${libdir}/*.so ${includedir}"
47FILES_libiw-doc = "${mandir}/man7"
48FILES_ifrename = "${sbindir}/ifrename"
49FILES_ifrename-doc = "${mandir}/man8/ifrename.8 ${mandir}/man5/iftab.5"
50FILES_${PN} = "${bindir} ${sbindir}/iw* ${base_sbindir} ${base_bindir} ${sysconfdir}/network"
51FILES_${PN}-doc = "${mandir}"