--- rt73-k2wrlz-3.0.3.orig/debian/rules +++ rt73-k2wrlz-3.0.3/debian/rules @@ -0,0 +1,66 @@ +#!/usr/bin/make -f +# -*- makefile -*- + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +include /usr/share/dpatch/dpatch.make + +DEB_NAME=rt73-k2wrlz +NAME=rt73-k2wrlz +VERSION=3.0.3 + +configure: configure-stamp +configure-stamp: + dh_testdir + touch configure-stamp + + +build: build-stamp + +build-stamp: patch-stamp #configure-stamp + dh_testdir + mkdir dkms_main_tree dkms_source_tree; \ + cp Module/Makefile Module/*.c Module/*.h debian/dkms.conf dkms_source_tree; \ + cp debian/dkms_dbversion dkms_main_tree; \ + tar -czf $(DEB_NAME)-$(VERSION).dkms.tar.gz dkms_main_tree dkms_source_tree; \ + touch $@ + +clean: unpatch + dh_testdir + dh_testroot + rm -f build-stamp configure-stamp + rm -rf dkms_main_tree dkms_source_tree $(DEB_NAME)-$(VERSION).dkms.tar.gz + dh_clean + +install: build + dh_testdir + dh_testroot + #dh_clean -k # deprercated, use dh_prep instead + dh_prep + dh_installdirs + dh_install $(DEB_NAME)-$(VERSION).dkms.tar.gz usr/src/ + cp $(CURDIR)/debian/blacklist-rt73.conf $(CURDIR)/debian/$(DEB_NAME)-source/etc/modprobe.d/; \ + cp $(CURDIR)/debian/rt73.conf $(CURDIR)/debian/$(DEB_NAME)-source/etc/modprobe.d/; \ + mkdir $(CURDIR)/debian/$(DEB_NAME)-source/usr/share/doc/rt73-k2wrlz-source/; \ + cp $(CURDIR)/debian/wireless-configuration.txt $(CURDIR)/debian/$(DEB_NAME)-source/usr/share/doc/rt73-k2wrlz-source/ + +binary-arch: build install + +binary-indep: build install + dh_testdir + dh_testroot + dh_installchangelogs + dh_installdocs + #dh_link + #dh_strip + dh_compress + dh_fixperms + dh_installdeb + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +binary: binary-indep binary-arch +.PHONY: build clean binary-indep binary-arch binary install configure --- rt73-k2wrlz-3.0.3.orig/debian/changelog +++ rt73-k2wrlz-3.0.3/debian/changelog @@ -0,0 +1,12 @@ +rt73-k2wrlz (3.0.3-1~ppa1~jaunty) jaunty; urgency=low + + * Fixed "error code 2" when reinstall the package + + -- Marco Giorgi Sun, 30 Aug 2009 11:36:05 +0100 + +rt73-k2wrlz (3.0.3-1~ppa0~jaunty) jaunty; urgency=low + + * Initial release + * Added Edimax EW-7318USg support + + -- Marco Giorgi Thu, 06 Aug 2009 10:00:34 +0100 --- rt73-k2wrlz-3.0.3.orig/debian/dirs +++ rt73-k2wrlz-3.0.3/debian/dirs @@ -0,0 +1,3 @@ +usr/src +etc/modprobe.d +usr/share/doc --- rt73-k2wrlz-3.0.3.orig/debian/README.Debian +++ rt73-k2wrlz-3.0.3/debian/README.Debian @@ -0,0 +1,12 @@ +rt73-k2wrlz DKMS module for Debian +----------------------------- + +Please see ./README for a description of the rt73-k2wrlz software. + +The Debian rt73-k2wrlz DKMS source package provides: + + * rt73-k2wrlz-source, which provides the source for the kernel modules + - rt73-k2wrlz use rausb0 as interface, uncomment "/etc/modprobe.d/rt73.conf" + for edit alias + + -- Marco Giorgi Thu, 06 Aug 2009 10:00:34 +0100 --- rt73-k2wrlz-3.0.3.orig/debian/control +++ rt73-k2wrlz-3.0.3/debian/control @@ -0,0 +1,27 @@ +Source: rt73-k2wrlz +Section: contrib/net +Priority: extra +Maintainer: Marco Giorgi +Build-Depends: debhelper (>= 7), dpatch +Standards-Version: 3.8.0 +Homepage: http://homepages.tu-darmstadt.de/~p_larbig/wlan/ + +Package: rt73-k2wrlz-source +Architecture: all +Depends: ${shlibs:Depends}, ${misc:Depends}, dkms (>= 1.95), bash (>> 1.99), linux-firmware, linux-headers-generic | linux-headers-server +Recommends: wireless-tools +Suggests: rutilt +Conflicts: rt73-source, rt73-common +Description: Ralink RT73 (RT2571W) Wireless Lan USB Enhanced Driver - kernel source + This is a Linux device driver for Ralink RT73 a/b/g WLAN USB Card based on + Legacy rt73 module (http://rt2x00.serialmonkey.com) with k2wrlz modifications: + - Monitor mode support + - Packet injection support + - Injection of fragments support + - Tx Power can be controlled with module parameter + - And other fixes + http://homepages.tu-darmstadt.de/~p_larbig/wlan/ + . + This package provides the source code for the rt73-k2wrlz kernel modules in + DKMS format. + Kernel source or headers are required to compile these modules. --- rt73-k2wrlz-3.0.3.orig/debian/compat +++ rt73-k2wrlz-3.0.3/debian/compat @@ -0,0 +1 @@ +7 --- rt73-k2wrlz-3.0.3.orig/debian/dkms.conf +++ rt73-k2wrlz-3.0.3/debian/dkms.conf @@ -0,0 +1,7 @@ +PACKAGE_NAME="rt73-k2wrlz" +PACKAGE_VERSION="3.0.3" +CLEAN="make clean" +BUILT_MODULE_NAME[0]="rt73" +DEST_MODULE_LOCATION[0]="/kernel/drivers/net/wireless" +MAKE[0]="make" +AUTOINSTALL="yes" --- rt73-k2wrlz-3.0.3.orig/debian/docs +++ rt73-k2wrlz-3.0.3/debian/docs @@ -0,0 +1,4 @@ +FAQ +IWPRIV_USAGE +README +THANKS --- rt73-k2wrlz-3.0.3.orig/debian/postinst +++ rt73-k2wrlz-3.0.3/debian/postinst @@ -0,0 +1,74 @@ +#!/bin/sh + +set -e + +NAME=rt73-k2wrlz +VERSION=3.0.3 + +case "$1" in + configure) + # Determine current arch / kernel + c_arch=`uname -m` + c_kern=`uname -r` + + if [ -e "/var/lib/dkms/$NAME/$VERSION" ]; then + echo "Removing old $NAME-$VERSION DKMS files..." + dkms remove -m $NAME -v $VERSION --all + fi + + echo "Loading new $NAME-$VERSION DKMS files..." + if [ -f "/usr/src/$NAME-$VERSION.dkms.tar.gz" ]; then + dkms ldtarball --archive "/usr/src/$NAME-$VERSION.dkms.tar.gz" + else + dkms add -m $NAME -v $VERSION + fi + + echo "Installing prebuilt kernel module binaries (if any)" + set +e + IFS=' +' + for kern in `dkms status -m $NAME -v $VERSION -a $c_arch | grep ": built" | awk {'print $3'} | sed 's/,$//'`; do + echo "Trying kernel: $kern" + dkms install -m $NAME -v $VERSION -k $kern -a $c_arch + done + unset IFS + set -e + + # If none installed, install. + ##if [ `dkms status -m $NAME -v $VERSION -k $c_kern -a $c_arch | grep -c ": installed"` -eq 0 ]; then + dkms_status=`dkms status -m $NAME -v $VERSION -k $c_kern -a $c_arch` + if [ `echo $dkms_status | grep -c ": installed"` -eq 0 ]; then + if [ `echo $c_kern | grep -c "BOOT"` -eq 0 ] && [ -e "/lib/modules/$c_kern/build/include" ]; then + # Only build if we need to. + if [ `echo $dkms_status | grep -c ": built"` -eq 0 ]; then + echo "Building module..." + dkms build -m $NAME -v $VERSION + fi + echo "Installing module..." + dkms install -m $NAME -v $VERSION + modprobe rt73 + elif [ `echo $c_kern | grep -c "BOOT"` -gt 0 ]; then + echo "" + echo "Module build for the currently running kernel was skipped since you" + echo "are running a BOOT variant of the kernel." + else + echo "" + echo "Module build for the currently running kernel was skipped since the" + echo "kernel source for this kernel does not seem to be installed." + fi + fi + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 + --- rt73-k2wrlz-3.0.3.orig/debian/prerm +++ rt73-k2wrlz-3.0.3/debian/prerm @@ -0,0 +1,28 @@ +#!/bin/sh + +NAME=rt73-k2wrlz +VERSION=3.0.3 + +set -e + +case "$1" in + remove|upgrade|deconfigure) + if [ "`dkms status -m $NAME`" ]; then + dkms remove -m $NAME -v $VERSION --all + fi + ;; + + failed-upgrade) + ;; + + *) + echo "prerm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 + + --- rt73-k2wrlz-3.0.3.orig/debian/copyright +++ rt73-k2wrlz-3.0.3/debian/copyright @@ -0,0 +1,38 @@ +This package was debianized by Marco Giorgi on +Thu, 06 Aug 2009 10:00:34 +0100. + +It was downloaded from http://homepages.tu-darmstadt.de/~p_larbig/wlan/ + +More informations about RT73(RT2571W) Wireless Lan Linux Driver - kernel +module sources are available from http://rt2x00.serialmonkey.com/ and from +http://homepages.tu-darmstadt.de/~p_larbig/wlan/ + +Upstream Authors: + + Ivo van Doorn + Luis Correia + Mark Wallis + Robin Cornelius + Gertjan van Wingerde + Remco + Ibrahim Damlaj + Olivier Cornu + Pedro Larbig + Marco Giorgi + +Copyright: + + RT2x00 SourceForge Project - http://rt2x00.serialmonkey.com + RaLink RT73 USB Enhanced Driver - http://homepages.tu-darmstadt.de/~p_larbig/wlan/ + +License: + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + Licensed under the GNU GPL + +The Debian packaging is copyright 2009, Marco Giorgi and +is licensed under the GPL, see `/usr/share/common-licenses/GPL'. --- rt73-k2wrlz-3.0.3.orig/debian/postrm +++ rt73-k2wrlz-3.0.3/debian/postrm @@ -0,0 +1,27 @@ +#!/bin/sh + +NAME=rt73-k2wrlz +VERSION=3.0.3 + +set -e + +case "$1" in + purge|remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + moddir="/lib/modules/`uname -r`/kernel/" + depmod + if [ -d "/usr/src/$NAME-$VERSION" ]; then + echo "Removing old module source..." + rm -rf "/usr/src/$NAME-$VERSION" + fi + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 + --- rt73-k2wrlz-3.0.3.orig/debian/blacklist-rt73.conf +++ rt73-k2wrlz-3.0.3/debian/blacklist-rt73.conf @@ -0,0 +1,6 @@ +# Blacklist modules that conflict with rt73 +# +blacklist rt73usb +blacklist rt2500usb +blacklist rt2x00lib +blacklist rt2x00usb --- rt73-k2wrlz-3.0.3.orig/debian/rt73.conf +++ rt73-k2wrlz-3.0.3/debian/rt73.conf @@ -0,0 +1,3 @@ +# RT73 driver - alias for rausb0 interface +# +# alias wlan0 rt73 --- rt73-k2wrlz-3.0.3.orig/debian/wireless-configuration.txt +++ rt73-k2wrlz-3.0.3/debian/wireless-configuration.txt @@ -0,0 +1,89 @@ +-- Network Configuration -- + + +Edit the "/etc/network/interfaces" file with one of the configuration settings listed below. +Replace "NetworkName", "Your-WEP-Key", "Your-WPA-Key", "Your-WPA2-Key", channel number and +also other configuration parameters with the values related with your configuration. + +NOTE: +If your network is configured in dhcp mode, replace "iface rausb0 inet static" +with "iface rausb0 inet dhcp" and remove "address", "netmask", "network", "gateway" lines. + + + + +# Without WEP/WPA/WPA2 (Unprotected network): + + auto rausb0 + iface rausb0 inet static + address 192.168.1.3 + netmask 255.255.255.0 + network 192.168.1.0 + gateway 192.168.1.1 + pre-up ifconfig rausb0 up + pre-up iwconfig rausb0 essid "NetworkName" + pre-up iwconfig rausb0 mode Managed + pre-up iwconfig rausb0 channel 6 + pre-up iwpriv rausb0 set SSID="NetworkName" + + + +# For WEP protocol: + + auto rausb0 + iface rausb0 inet static + address 192.168.1.3 + netmask 255.255.255.0 + network 192.168.1.0 + gateway 192.168.1.1 + pre-up ifconfig rausb0 up + pre-up iwconfig rausb0 essid "NetworkName" + pre-up iwconfig rausb0 mode Managed + pre-up iwconfig rausb0 channel 6 + pre-up iwpriv rausb0 set AuthMode=WEPAUTO + pre-up iwpriv rausb0 set EncrypType=WEP + pre-up iwpriv rausb0 set Key1="Your-WEP-Key" + pre-up iwpriv rausb0 set SSID="NetworkName" + + + +# For WPA protocol: + + auto rausb0 + iface rausb0 inet static + address 192.168.1.3 + netmask 255.255.255.0 + network 192.168.1.0 + gateway 192.168.1.1 + pre-up ifconfig rausb0 up + pre-up iwconfig rausb0 essid "NetworkName" + pre-up iwconfig rausb0 mode Managed + pre-up iwconfig rausb0 channel 6 + pre-up iwpriv rausb0 set AuthMode=WPAPSK + pre-up iwpriv rausb0 set EncrypType=TKIP + pre-up iwpriv rausb0 set WPAPSK="Your-WPA-Key" + pre-up iwpriv rausb0 set SSID="NetworkName" + + + +# For WPA2 protocol: + + auto rausb0 + iface rausb0 inet static + address 192.168.1.3 + netmask 255.255.255.0 + network 192.168.1.0 + gateway 192.168.1.1 + pre-up ifconfig rausb0 up + pre-up iwconfig rausb0 essid "NetworkName" + pre-up iwconfig rausb0 mode Managed + pre-up iwconfig rausb0 channel 6 + pre-up iwpriv rausb0 set AuthMode=WPA2PSK + pre-up iwpriv rausb0 set EncrypType=AES + pre-up iwpriv rausb0 set WPAPSK="Your-WPA2-Key" + pre-up iwpriv rausb0 set SSID="NetworkName" + + + +Reboot and check if it work properly. + --- rt73-k2wrlz-3.0.3.orig/debian/dkms_dbversion +++ rt73-k2wrlz-3.0.3/debian/dkms_dbversion @@ -0,0 +1 @@ +2.0.0 --- rt73-k2wrlz-3.0.3.orig/debian/patches/00list +++ rt73-k2wrlz-3.0.3/debian/patches/00list @@ -0,0 +1,2 @@ +01_remove-firmware-installation.dpatch +02_add-edimax-support.dpatch --- rt73-k2wrlz-3.0.3.orig/debian/patches/02_add-edimax-support.dpatch +++ rt73-k2wrlz-3.0.3/debian/patches/02_add-edimax-support.dpatch @@ -0,0 +1,28 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 02_add-edimax-support.dpatch by Marco Giorgi +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Add Edimax EW-7318USg support + + +@DPATCH@ +diff -urNad rt73-k2wrlz-3.0.3~/Module/rtmp_def.h rt73-k2wrlz-3.0.3/Module/rtmp_def.h +--- rt73-k2wrlz-3.0.3~/Module/rtmp_def.h 2008-06-23 01:21:34.000000000 +0200 ++++ rt73-k2wrlz-3.0.3/Module/rtmp_def.h 2009-07-16 23:13:16.712889776 +0200 +@@ -31,6 +31,7 @@ + * Paul Lin 08-01-2002 created + * John Chang 08-05-2003 add definition for 11g & other drafts + * idamlaj 04-10-2006 Add extra devices ++ * Marco Giorgi 16-07-2009 add Edimax device + * + ***************************************************************************/ + +@@ -837,6 +838,8 @@ + {USB_DEVICE(0x07d1,0x3c04)},\ + {USB_DEVICE(0x07d1,0x3c06)}, /* D-Link DWA111 - thanks to zenon_666 */ \ + {USB_DEVICE(0x07d1,0x3c07)},\ ++ /* Edimax */\ ++ {USB_DEVICE(0x7392,0x7318)},\ + /* Gemtek*/\ + {USB_DEVICE(0x15a9,0x0004)},\ + /* Gigabyte */\ --- rt73-k2wrlz-3.0.3.orig/debian/patches/01_remove-firmware-installation.dpatch +++ rt73-k2wrlz-3.0.3/debian/patches/01_remove-firmware-installation.dpatch @@ -0,0 +1,51 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 01_remove-firmware-installation.dpatch by Marco Giorgi +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Remove firmware installation from Makefile + + +@DPATCH@ +diff -urNad rt73-k2wrlz-3.0.3~/Module/Makefile rt73-k2wrlz-3.0.3/Module/Makefile +--- rt73-k2wrlz-3.0.3~/Module/Makefile 2009-05-14 17:22:37.000000000 +0200 ++++ rt73-k2wrlz-3.0.3/Module/Makefile 2009-08-17 16:25:25.806105494 +0200 +@@ -33,7 +33,6 @@ + # MarkW (rt2500) 3rd Feb 06 Fixed permissions on directory + # MichaIL(rt2500) 13th Feb 06 Module installation fixes + # MarkW (rt2500) 13th Feb 06 Allow install dir override +-# OlivierC 14th May 07 Install firmware file + # OlivierC 14th May 07 Check old config + ########################################################################### + +@@ -42,9 +41,6 @@ + MODULE_NAME := rt73 + IF_NAME := wlan* + +-FIRMWARES := rt73.bin +-FIRM_DIR := /lib/firmware +- + OLD_IF_NAME := ra0 + CONFIG_DIR := /etc/Wireless/RT73STA + CONFIG_FILE := rt73sta.dat +@@ -186,11 +182,6 @@ + else \ + echo "*** Config dir `dirname $(MODULE_CONF)` not found" >&2; \ + fi +- @echo "*** Install firmware in $(FIRM_DIR) ..."; \ +- if ! [ -d $(FIRM_DIR) ]; then \ +- mkdir $(FIRM_DIR); \ +- fi; \ +- cp -f $(FIRMWARES) $(FIRM_DIR) + @echo "*** Check old config ..."; \ + if [ -d $(CONFIG_DIR) ]; then \ + echo "!!!"; \ +@@ -201,9 +192,6 @@ + echo "!!! -> $(CONFIG_FILE) file is deprecated:" \ + "use iwconfig/iwpriv instead"; \ + fi; \ +- if [ -f $(CONFIG_DIR)/$(FIRMWARES) ]; then \ +- echo "!!! -> $(FIRMWARES) firmware has moved to $(FIRM_DIR)"; \ +- fi; \ + fi + + ifeq ($(PATCHLEVEL), 4)