summaryrefslogtreecommitdiff
path: root/network
diff options
context:
space:
mode:
Diffstat (limited to 'network')
-rw-r--r--network/rt3xxx/README3
-rw-r--r--network/rt3xxx/doinst.sh15
-rw-r--r--network/rt3xxx/patches/Makefile.6.diff37
-rw-r--r--network/rt3xxx/patches/Makefile.diff35
-rw-r--r--network/rt3xxx/patches/config.mk.diff28
-rw-r--r--network/rt3xxx/patches/kill_tftpboot_creation.diff69
-rw-r--r--network/rt3xxx/rt3xxx.SlackBuild83
-rw-r--r--network/rt3xxx/rt3xxx.info10
-rw-r--r--network/rt3xxx/slack-desc19
9 files changed, 299 insertions, 0 deletions
diff --git a/network/rt3xxx/README b/network/rt3xxx/README
new file mode 100644
index 0000000000..ce7f142c1d
--- /dev/null
+++ b/network/rt3xxx/README
@@ -0,0 +1,3 @@
+rt3xxx is the driver for RT3xxxPCI/mPCI/CB/PCIe.
+It's a development version and supports only
+infrastructure and ad-hoc modes for now.
diff --git a/network/rt3xxx/doinst.sh b/network/rt3xxx/doinst.sh
new file mode 100644
index 0000000000..cf9b4e4735
--- /dev/null
+++ b/network/rt3xxx/doinst.sh
@@ -0,0 +1,15 @@
+config() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ # If there's no config file by that name, mv it over:
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
+ # toss the redundant copy
+ rm $NEW
+ fi
+ # Otherwise, we leave the .new copy for the admin to consider...
+}
+
+depmod -a
+
diff --git a/network/rt3xxx/patches/Makefile.6.diff b/network/rt3xxx/patches/Makefile.6.diff
new file mode 100644
index 0000000000..70660351e7
--- /dev/null
+++ b/network/rt3xxx/patches/Makefile.6.diff
@@ -0,0 +1,37 @@
+diff -Naur a/os/linux/Makefile.6 b/os/linux/Makefile.6
+--- a/os/linux/Makefile.6 2010-12-17 20:44:47.000000000 +0900
++++ b/os/linux/Makefile.6 2011-01-27 04:45:02.828981820 +0900
+@@ -4,7 +4,7 @@
+ #ifdef CONFIG_STA_SUPPORT
+ ifeq ($(RT28xx_MODE), STA)
+ MOD_NAME = rt$(CHIPSET)sta
+-DAT_PATH = /etc/Wireless/RT$(CHIPSET_DAT)STA
++DAT_PATH = /etc/rt3xxx/RT$(CHIPSET_DAT)STA
+ DAT_FILE_NAME = RT$(CHIPSET_DAT)STA.dat
+ endif
+ #endif // CONFIG_STA_SUPPORT //
+@@ -255,18 +255,14 @@
+ endif
+
+ install:
+- rm -rf $(DAT_PATH)
+- $(shell [ ! -f /etc/Wireless ] && mkdir /etc/Wireless)
+- mkdir $(DAT_PATH)
+- cp $(RT28xx_DIR)/$(DAT_FILE_NAME) $(DAT_PATH)/.
+- install -d $(LINUX_SRC_MODULE)
+- install -m 644 -c $(addsuffix .ko,$(MOD_NAME)) $(LINUX_SRC_MODULE)
+- /sbin/depmod -a ${shell uname -r}
++ mkdir -p $(DESTDIR)/$(DAT_PATH)
++ cp $(RT28xx_DIR)/$(DAT_FILE_NAME) $(DESTDIR)/$(DAT_PATH)
++ install -d $(DESTDIR)/$(LINUX_SRC_MODULE)
++ install -m 644 -c $(addsuffix .ko,$(MOD_NAME)) $(DESTDIR)/$(LINUX_SRC_MODULE)
+
+ uninstall:
+ # rm -rf $(DAT_PATH)
+- rm -rf $(addprefix $(LINUX_SRC_MODULE),$(addsuffix .ko,$(MOD_NAME)))
+- /sbin/depmod -a ${shell uname -r}
++ rm -rf $(addprefix $(DESTDIR)/$(LINUX_SRC_MODULE),$(addsuffix .ko,$(MOD_NAME)))
+
+ # Declare the contents of the .PHONY variable as phony. We keep that
+ # information in a variable so we can use it in if_changed and friends.
+
diff --git a/network/rt3xxx/patches/Makefile.diff b/network/rt3xxx/patches/Makefile.diff
new file mode 100644
index 0000000000..53723f8cad
--- /dev/null
+++ b/network/rt3xxx/patches/Makefile.diff
@@ -0,0 +1,35 @@
+diff -Naur a/Makefile b/Makefile
+--- a/Makefile 2010-12-17 20:44:47.000000000 +0900
++++ b/Makefile 2011-01-27 04:39:12.732361523 +0900
+@@ -1,8 +1,7 @@
+ RT28xx_MODE = STA
+
+ TARGET = LINUX
+-
+-CHIPSET = 3562
++MODE = STA
+
+ #OS ABL - YES or NO
+ OSABL = NO
+@@ -139,10 +138,10 @@
+
+ ifeq ($(PLATFORM),PC)
+ # Linux 2.6
+-LINUX_SRC = /lib/modules/$(shell uname -r)/build
++LINUX_SRC = /lib/modules/$(KERNEL)/build
+ # Linux 2.4 Change to your local setting
+ #LINUX_SRC = /usr/src/linux-2.4
+-LINUX_SRC_MODULE = /lib/modules/$(shell uname -r)/kernel/drivers/net/wireless/
++LINUX_SRC_MODULE = /lib/modules/$(KERNEL)/kernel/drivers/net/wireless
+ CROSS_COMPILE =
+ endif
+
+@@ -239,7 +238,7 @@
+ CROSS_COMPILE = /opt/montavista/pro/devkit/arm/v5t_le_mvl5/bin/arm_v5t_le-
+ endif
+
+-export OSABL RT28xx_DIR RT28xx_MODE LINUX_SRC CROSS_COMPILE CROSS_COMPILE_INCLUDE PLATFORM RELEASE CHIPSET RTMP_SRC_DIR LINUX_SRC_MODULE TARGET
++export OSABL RT28xx_DIR RT28xx_MODE CROSS_COMPILE CROSS_COMPILE_INCLUDE PLATFORM RELEASE LINUX_SRC RTMP_SRC_DIR LINUX_SRC_MODULE TARGET
+
+ # The targets that may be used.
+ PHONY += all build_tools test UCOS THREADX LINUX release prerelease clean uninstall install libwapi osabl
diff --git a/network/rt3xxx/patches/config.mk.diff b/network/rt3xxx/patches/config.mk.diff
new file mode 100644
index 0000000000..95eb577e77
--- /dev/null
+++ b/network/rt3xxx/patches/config.mk.diff
@@ -0,0 +1,28 @@
+diff -Naur a/os/linux/config.mk b/os/linux/config.mk
+--- a/os/linux/config.mk 2010-12-17 20:44:47.000000000 +0900
++++ b/os/linux/config.mk 2011-01-27 04:52:05.753313553 +0900
+@@ -1,18 +1,18 @@
+ # Support ATE function
+-HAS_ATE=n
++HAS_ATE=y
+
+ # Support QA ATE function
+-HAS_QA_SUPPORT=n
++HAS_QA_SUPPORT=y
+
+ # Support XLINK mode
+-HAS_XLINK=n
++HAS_XLINK=y
+
+
+ # Support Wpa_Supplicant
+-HAS_WPA_SUPPLICANT=n
++HAS_WPA_SUPPLICANT=y
+
+ # Support Native WpaSupplicant for Network Maganger
+-HAS_NATIVE_WPA_SUPPLICANT_SUPPORT=n
++HAS_NATIVE_WPA_SUPPLICANT_SUPPORT=y
+
+ #Support Net interface block while Tx-Sw queue full
+ HAS_BLOCK_NET_IF=n
+
diff --git a/network/rt3xxx/patches/kill_tftpboot_creation.diff b/network/rt3xxx/patches/kill_tftpboot_creation.diff
new file mode 100644
index 0000000000..3eca73d1e4
--- /dev/null
+++ b/network/rt3xxx/patches/kill_tftpboot_creation.diff
@@ -0,0 +1,69 @@
+diff -Nur DPO_RT3562_3592_3062_LinuxSTA_V2.4.1.1_20101217.orig//Makefile DPO_RT3562_3592_3062_LinuxSTA_V2.4.1.1_20101217/Makefile
+--- DPO_RT3562_3592_3062_LinuxSTA_V2.4.1.1_20101217.orig//Makefile 2010-12-17 05:44:47.000000000 -0600
++++ DPO_RT3562_3592_3062_LinuxSTA_V2.4.1.1_20101217/Makefile 2011-01-29 22:54:25.684219265 -0600
+@@ -284,26 +284,23 @@
+ endif
+
+ ifeq ($(RT28xx_MODE),AP)
+- cp -f $(RT28xx_DIR)/os/linux/rt$(CHIPSET)ap.o /tftpboot
++ true
+ ifeq ($(OSABL),YES)
+- cp -f $(RT28xx_DIR)/os/linux/rtutil$(CHIPSET)ap.o /tftpboot
+- cp -f $(RT28xx_DIR)/os/linux/rtnet$(CHIPSET)ap.o /tftpboot
++ true
+ endif
+ ifeq ($(PLATFORM),INF_AMAZON_SE)
+- cp -f /tftpboot/rt2870ap.o /backup/ifx/build/root_filesystem/lib/modules/2.4.31-Amazon_SE-3.6.2.2-R0416_Ralink/kernel/drivers/net
++ true
+ endif
+ else
+ ifeq ($(RT28xx_MODE),APSTA)
+- cp -f $(RT28xx_DIR)/os/linux/rt$(CHIPSET)apsta.o /tftpboot
++ true
+ ifeq ($(OSABL),YES)
+- cp -f $(RT28xx_DIR)/os/linux/rtutil$(CHIPSET)apsta.o /tftpboot
+- cp -f $(RT28xx_DIR)/os/linux/rtnet$(CHIPSET)apsta.o /tftpboot
++ true
+ endif
+ else
+- cp -f $(RT28xx_DIR)/os/linux/rt$(CHIPSET)sta.o /tftpboot
++ true
+ ifeq ($(OSABL),YES)
+- cp -f $(RT28xx_DIR)/os/linux/rtutil$(CHIPSET)sta.o /tftpboot
+- cp -f $(RT28xx_DIR)/os/linux/rtnet$(CHIPSET)sta.o /tftpboot
++ true
+ endif
+ endif
+ endif
+@@ -331,25 +328,22 @@
+ endif
+
+ ifeq ($(RT28xx_MODE),AP)
+- cp -f $(RT28xx_DIR)/os/linux/rt$(CHIPSET)ap.ko /tftpboot
++ true
+ ifeq ($(OSABL),YES)
+- cp -f $(RT28xx_DIR)/os/linux/rtutil$(CHIPSET)ap.ko /tftpboot
+- cp -f $(RT28xx_DIR)/os/linux/rtnet$(CHIPSET)ap.ko /tftpboot
++ true
+ endif
+ rm -f os/linux/rt$(CHIPSET)ap.ko.lzma
+ /root/bin/lzma e os/linux/rt$(CHIPSET)ap.ko os/linux/rt$(CHIPSET)ap.ko.lzma
+ else
+ ifeq ($(RT28xx_MODE),APSTA)
+- cp -f $(RT28xx_DIR)/os/linux/rt$(CHIPSET)apsta.ko /tftpboot
++ true
+ ifeq ($(OSABL),YES)
+- cp -f $(RT28xx_DIR)/os/linux/rtutil$(CHIPSET)apsta.ko /tftpboot
+- cp -f $(RT28xx_DIR)/os/linux/rtnet$(CHIPSET)apsta.ko /tftpboot
++ true
+ endif
+ else
+- cp -f $(RT28xx_DIR)/os/linux/rt$(CHIPSET)sta.ko /tftpboot
++ true
+ ifeq ($(OSABL),YES)
+- cp -f $(RT28xx_DIR)/os/linux/rtutil$(CHIPSET)sta.ko /tftpboot
+- cp -f $(RT28xx_DIR)/os/linux/rtnet$(CHIPSET)sta.ko /tftpboot
++ true
+ endif
+ endif
+ endif
diff --git a/network/rt3xxx/rt3xxx.SlackBuild b/network/rt3xxx/rt3xxx.SlackBuild
new file mode 100644
index 0000000000..a81b8f34d5
--- /dev/null
+++ b/network/rt3xxx/rt3xxx.SlackBuild
@@ -0,0 +1,83 @@
+#!/bin/sh
+
+# Slackware build script for rt3xxx
+
+# Written by crocket (crockabiscuit@yahoo.com)
+
+PRGNAM=rt3xxx
+VERSION=2.4.1.1_20101217
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+SRCNAM=DPO_RT3562_3592_3062_LinuxSTA_V
+
+KERNEL=${KERNEL:-$(uname -r)}
+
+CHIPSETS=${CHIPSETS:-"3062,3562"} # Not available currently : 3572 2860 3593
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i486 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+# Environment variables that aren't exported never survive recursive make calls.
+export KERNEL
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $SRCNAM$VERSION
+tar xvf $CWD/$SRCNAM$VERSION.tgz
+cd $SRCNAM$VERSION
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \;
+
+# Fixup a few things in various places
+patch -p1 < $CWD/patches/config.mk.diff
+patch -p1 < $CWD/patches/Makefile.diff
+patch -p1 < $CWD/patches/kill_tftpboot_creation.diff
+patch -p1 < $CWD/patches/Makefile.6.diff
+
+for CHIPSET in $(printf $CHIPSETS | tr , \ ); do
+ echo "Working on $CHIPSET" ; sleep 5
+ export CHIPSET=$CHIPSET
+ make
+ make install DESTDIR=$PKG
+ unset CHIPSET
+done
+
+find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a \
+ README_STA_pci iwpriv_usage.txt sta_ate_iwpriv_usage.txt \
+ $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+cat $CWD/doinst.sh > $PKG/install/doinst.sh
+
+for FILE in $(find $PKG/etc/rt3xxx -name "*.dat"); do
+ mv $FILE $FILE.new
+ printf "config $(printf $FILE | sed "s,$PKG/,,").new\n" >> $PKG/install/doinst.sh
+done
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-${VERSION}_linux${KERNEL}-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+
diff --git a/network/rt3xxx/rt3xxx.info b/network/rt3xxx/rt3xxx.info
new file mode 100644
index 0000000000..e1064b2caf
--- /dev/null
+++ b/network/rt3xxx/rt3xxx.info
@@ -0,0 +1,10 @@
+PRGNAM="rt3xxx"
+VERSION="2.4.1.1"
+HOMEPAGE="http://www.ralinktech.com/support.php?s=2"
+DOWNLOAD="http://crocket-slackbuilds.googlecode.com/files/DPO_RT3562_3592_3062_LinuxSTA_V2.4.1.1_20101217.tgz"
+MD5SUM="a5e9af70abccdb7b86d1ef605bb34491"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+MAINTAINER="crocket"
+EMAIL="crockabiscuit@yahoo.com"
+APPROVED="rworkman"
diff --git a/network/rt3xxx/slack-desc b/network/rt3xxx/slack-desc
new file mode 100644
index 0000000000..f6241cf804
--- /dev/null
+++ b/network/rt3xxx/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in. You must
+# make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+rt3xxx: rt3xxx (driver for rt3xxx chipsets)
+rt3xxx:
+rt3xxx: This is the driver for RT3xxxPCI/mPCI/CB/PCIe.
+rt3xxx:
+rt3xxx: It's a development version and supports only
+rt3xxx: infrastructure mode and ad-hoc mode for now.
+rt3xxx:
+rt3xxx: Homepage: http://www.ralinktech.com/support.php?s=2
+rt3xxx:
+rt3xxx:
+rt3xxx: