Help needed with Linux network software compile error

jbhtexas

Well-Known Member
Oct 20, 2006
14,327
4,377
113
Arlington, TX
Well, I know there are alot of computer gurus out there on CF, so maybe one of you can shed some light on this problem. It seems to be stumping those on the other forums I've posted to.

I'm trying to compile the Basilisk II 1.0 JIT Macintosh 680x0 emulator on Ubuntu 8.04 (uname -r reports 2.6.24-23-generic). I've also tried on Fedora, but am ending up with the same errors...

I have the basic emulator program working fine, but for networking in the emulator, I need to get a driver called sheep_net compiled. When trying to do that I get the following errors:

make -C /lib/modules/2.6.24-23-generic/build M=$PWD modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.24-23-generic'
sheep_net.c:283: error: ‘struct sk_buff’ has no member named ‘mac’
sheep_net.c:400: error: ‘struct sk_buff’ has no member named ‘nh’
sheep_net.c:400: error: ‘struct sk_buff’ has no member named ‘h’
sheep_net.c:487: warning: passing argument 1
sheep_net.c:487: error: too few arguments to function ‘dev_get_by_name’

After searching the web, there are many, many pages where these these same errors with sk_buff and dev_get_by_name are reported when trying to compile network-related code. However, I haven't really found a good explanation of what the problem is. Some of the posts suggest that something has changed in the kernel header files along the way, or there may be some out of date headers, or that the code needs to be rewritten.

Supposedly, the code has been compiled in the past and is working in Linux installations, so I am just looking for some hints as to what might be wrong.

Thanks!
 

cloneluke80

Well-Known Member
Apr 11, 2006
1,772
52
48
West Des Moines, IA
Well, I know there are alot of computer gurus out there on CF, so maybe one of you can shed some light on this problem. It seems to be stumping those on the other forums I've posted to.

I'm trying to compile the Basilisk II 1.0 JIT Macintosh 680x0 emulator on Ubuntu 8.04 (uname -r reports 2.6.24-23-generic). I've also tried on Fedora, but am ending up with the same errors...

I have the basic emulator program working fine, but for networking in the emulator, I need to get a driver called sheep_net compiled. When trying to do that I get the following errors:

make -C /lib/modules/2.6.24-23-generic/build M=$PWD modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.24-23-generic'
sheep_net.c:283: error: ‘struct sk_buff’ has no member named ‘mac’
sheep_net.c:400: error: ‘struct sk_buff’ has no member named ‘nh’
sheep_net.c:400: error: ‘struct sk_buff’ has no member named ‘h’
sheep_net.c:487: warning: passing argument 1
sheep_net.c:487: error: too few arguments to function ‘dev_get_by_name’

After searching the web, there are many, many pages where these these same errors with sk_buff and dev_get_by_name are reported when trying to compile network-related code. However, I haven't really found a good explanation of what the problem is. Some of the posts suggest that something has changed in the kernel header files along the way, or there may be some out of date headers, or that the code needs to be rewritten.

Supposedly, the code has been compiled in the past and is working in Linux installations, so I am just looking for some hints as to what might be wrong.

Thanks!


Looks like you need a new version of sheep_net.c

http://launchpadlibrarian.net/20302137/sheep_net.c

https://bugs.launchpad.net/ubuntu/+source/basilisk2/+bug/210876
 
  • Like
Reactions: jbhtexas

jbhtexas

Well-Known Member
Oct 20, 2006
14,327
4,377
113
Arlington, TX

Thank you!!!

I got the compile to work...unfortunately the sheep_net driver crashes the emulator, which I kind of expected might happen, since it was reported in the link you posted that networking changes again occurred again in the later kernel I am using. But, I did make some progress and now have another source for info on getting this thing to work.
 

cloneluke80

Well-Known Member
Apr 11, 2006
1,772
52
48
West Des Moines, IA
Thank you!!!

I got the compile to work...unfortunately the sheep_net driver crashes the emulator, which I kind of expected might happen, since it was reported in the link you posted that networking changes again occurred again in the later kernel I am using. But, I did make some progress and now have another source for info on getting this thing to work.


Glad to hear!

By the way Linux rules! Windows is garbage.