I have an issue on my router (debian testing) with kernel 2.6.21.3 when compiling ndiswrapper. Although the same version compiles fine on my laptop (debian sid). I finally got the router up to date on apt-get update && apt-get dist-upgrade just a while ago. But I'm having trouble compiling ndiswrapper. My laptop is still six months behind in updates.
I get this terminal compile error:
Code:
/usr/src/wireless/ndiswrapper-1.46/driver/crt_exports.h:50: error: expected identifier or '(' before '/' token
make[3]: *** [/usr/src/wireless/ndiswrapper-1.46/driver/crt.o] Error 1
make[2]: *** [_module_/usr/src/wireless/ndiswrapper-1.46/driver] Error 2
make[2]: Leaving directory `/usr/src/linux-2.6.21.3'
make[1]: *** [default] Error 2
make[1]: Leaving directory `/usr/src/wireless/ndiswrapper-1.46/driver'
make: *** [install] Error 2
I did apt-get install build-essential which wasn't installed, but that didn't help or fix it. I tried with gcc-4.0 and gcc-4.1 with the same end result. I've been using ndiswrapper on the machine in question since 0.10 so I'm not sure why it's an issue now.
The difference between the two is some path on line 50 in crt_exports.h. For struct wrap_export [/path/.../] crt_exports[] = { on line 50. The Makefile shows some $basename for that field.
Not that this is your issue. I have the same kernel and ndiswrapper running on my not updated laptop. So it's probably more of a compiler/configuration/versioning issue than an ndiswrapper issue. Besides you might want to be using ndiswrapper 1.46 as 1.45 has a pretty noticeable bug. My own issue might go away if I update again tomorrow.