Installing oss2jack
From Arnout Engelen
Used directions at http://fort.xdas.com/~kor/oss2jack/install.html
- need to use newest version of kfusd
- had to use full path to .ko file for 'insmod', modprobe doesn't find it yet
[edit] Make errors
With 1.10-11, I had the following problems:
[edit] make.include:149: obj.i686-linux/libfusd.d: No such file or directory
It's created afterwards, just run 'make' again.
[edit] dereferencing type-punned pointer will break strict-aliasing rules
gcc -Werror -fPIC -Wall -O2 -g -I. -Iinclude -I././include -L././obj.i686-linux ././libfusd/libfusd.c -c -o obj.i686-linux/libfusd.o cc1: warnings being treated as errors ././libfusd/libfusd.c: In function ‘fusd_dispatch_one’: ././libfusd/libfusd.c:444: warning: dereferencing type-punned pointer will break strict-aliasing rules make: *** [obj.i686-linux/libfusd.o] Error 1
Solution: adding '-fno-strict-aliasing' to the CCFLAGS on line 67 of make.include
[edit] Entering an unknown directory
make -C /lib/modules/2.6.20-5-lowlatency/build SUBDIRS=/home/arnouten/progs/fusd-kor-1.10-11/kfusd EXTRA_CFLAGS=-I/home/arnouten/progs/fusd-kor-1.10-11/kfusd/../include modules make: Entering an unknown directory make: *** /lib/modules/2.6.20-5-lowlatency/build: No such file or directory. Stop. make: Leaving an unknown directory
Solution: installing the linux-headers-2.6.20-5-lowlatency kernel headers package
[edit] linux/config.h not found
make[2]: Entering directory `/usr/src/linux-headers-2.6.20-5-lowlatency' CC [M] /home/arnouten/progs/fusd-kor-1.10-11/kfusd/kfusd.o /home/arnouten/progs/fusd-kor-1.10-11/kfusd/kfusd.c:60:26: error: linux/config.h: No such file or directory
linux/config.h was removed in the 2.6.20 kernel series, looks like kfusd wasn't yet updated to reflect that change.
Solution: (for now): remove the #include from kfusd/kfusd.c and see what breaks ;)
[edit] linux/devfs_fs_kernel.h not found
devfs has also been removed: has been deprecated for a while. Even though most devfs code has been enclosed by #ifdef CONFIG_DEVFS_FS, not all.
Solution: add #ifdef CONFIG_DEVFS_FS in a couple of places:
- around the devfs_remove calls, ~2960 kfusd.c
- around the register_failed2:-label ~2973
[edit] unknown field ‘writev’ specified in initializer
make[2]: Entering directory `/usr/src/linux-headers-2.6.20-5-lowlatency' CC [M] /home/arnouten/progs/fusd-kor-1.10-11/kfusd/kfusd.o /home/arnouten/progs/fusd-kor-1.10-11/kfusd/kfusd.c:2517: error: unknown field ‘writev’ specified in initializer /home/arnouten/progs/fusd-kor-1.10-11/kfusd/kfusd.c:2517: warning: initialization from incompatible pointer type
Solution: not sure,commented writev out.
[edit] expected ‘)’ before string constant
make[2]: Entering directory `/usr/src/linux-headers-2.6.20-5-lowlatency'
CC [M] /home/arnouten/progs/fusd-kor-1.10-11/kfusd/kfusd.o
/home/arnouten/progs/fusd-kor-1.10-11/kfusd/kfusd.c:181: error: expected ‘)’ before string constant
That line reads:
MODULE_PARM(fusd_debug_level, "i");
Which seems to be deprecated.
Solution: Since I'm not using that parameter anyway, I just removed the line declaring the parameter.
[edit] udev stuff
The fusd.rules rules I had success with are:
# fusd devices KERNEL="control", NAME="fusd/control", GROUP="audio" KERNEL="status", NAME="fusd/status", GROUP="audio"
[edit] usage problems
$ sudo insmod /lib/modules/2.6.20-5-lowlatency/misc/kfusd.ko $ oss2jack libfusd: /dev/fusd/control does not exist; ensure FUSD's kernel module is installed Could not create DSP device : Package not installed
Indeed /dev/fusd is not there.
