PDA

View Full Version : HOWTO: compile & install madwifi-old/ng without breaking linux-restricted-modules


stanwebber
January 6th, 2006, 11:20 AM
for breezy this howto assumes you have the following packages installed:
build-essential
linux-headers-`uname -r`
gcc-3.4
sharutils (thanks to enodr for reminder)

1. cd /usr/local/src

2. sudo wget http://snapshots.madwifi.org/madwifi-old-current.tar.gz
or for madwifi-ng
sudo wget http://snapshots.madwifi.org/madwifi-ng-current.tar.gz

3. sudo tar -zxvf madwifi-XX-current.tar.gz
cd madwifi-XX-current
replace XX with old or ng

4. EXPORT CC=gcc-3.4
or for madwifi-ng edit madwifi-ng-current/hal/public/i386-elf.inc & change this line:
CC= ${TOOLPREFIX}gcc
to this:
CC= ${TOOLPREFIX}gcc-3.4

5. sudo make clean
sudo make

6. sudo make install
answer [r]emove to all questions

7. cd ath_hal
sudo cp ah_osdep.o /lib/linux-restricted-modules/`uname -r`/ath_hal
sudo cp ath_hal.mod.o /lib/linux-restricted-modules/`uname -r`/ath_hal
sudo cp hal.o /lib/linux-restricted-modules/`uname -r`/ath_hal

8. cd /lib/modules/`uname -r`
sudo rm -r madwifi
sudo mv net madwifi
sudo rm madwifi/ath_hal.ko

finish

to undo all of the above:
sudo apt-get --reinstall linux-restricted-modules-`uname -r`

kk_davey
February 19th, 2006, 03:22 AM
The Makefile's in madwifi-old releases have accompanying Makefile.kernel's in some directories (e.g. ath/, ath_hal/ etc). These files have commented out lines for both kernel versions 2.4.x & 2.6.x. I assume it's necessary to uncomment the line specific to your kernel version?

Thanks,
Katie

enodr
March 18th, 2006, 09:43 AM
In order to build the driver you also need the uudecode tool which in the sharutils package. So if you get this error:
# make
Checking requirements... FAILED
The 'uudecode' tool was not found on your system. Please make sure
it is installed in your PATH, then try again.
make: *** [sanitycheck] Erreur 1
Do:
# sudo apt-get install sharutils

stanwebber
March 29th, 2006, 12:55 PM
I assume it's necessary to uncomment the line specific to your kernel version?

i know from practical experience it's not necessary to edit anything for 2.6 kernel...no idea for 2.4 kernel

bl3s5in
September 26th, 2007, 11:27 AM
I tried this with the ng version and
ah_osdep.o
hal.o

Do not exist.