It sounds as though it's trying to use the kernel headers to compile. What happens if you boot the machine with the wired plugged in ? Normally Debian's device detection on boot is pretty good, especially with wired ethernet (very standard devices, lots of drivers). I'd suggest (if you can get wired connection) reading this:
http://regomodoslinux.blogspot.com/2007/11/complete-rt61-pcmcia-on-debian-guide.html
take particular note of the first things it wants you to install:
Install wireless-tools build-essential linux-headers (uname-r)
I would suggest you run "uname -r" first, and then do "apt-get install wireless-tools build-essential linux-headers-X.X.XX - where the X's are the numbers you got from "uname -r", and then try to compile it again.
If you can't get wired working / have problems with the Wireless please post back and I/we'll try and figure this out.