Re: Compiling RTL82139 module?


Subject: Re: Compiling RTL82139 module?
From: Aake Svensson (aakesve@algonet.se)
Date: Mon Jul 16 2001 - 13:06:34 MDT


Bare with me, Newbie as I am, neither the compile commands at the end
of the file rtl8139.c, nor the commands you suggested works. Both
alternatives produce the "members missing" warning.

In rtl8139.c it is written:
gcc -DMODULE -Wall -Wstrict-prototypes -O6 -c rtl8139.c
but without the command: "-I usr/src/linux-2.2.4/include/ "
pointing to were the source kernel rpm installed the header files,
gcc don't find them at all. And with your suggestion about
-DMODVERSIONS it complains about "no file DMODVERSIONS".

>% gcc -DMODULE -D__KERNEL__ -Wall -Wstrict-prototypes -O6 \
>-c rtl8139.c '[ -f /usr/include/linux/modversions.h ] && echo \
-DMODVERSIONS'

I left out the slashes and used my path to the header files, hope that was OK?

Best Regards,

Åke Svensson, still learning, still curious

>Open the rtl8139.c file and scroll to the very bottom. There should
>be instructions on the exact command to gcc, but the one in my email
>below should work. Also, where it says -O6, the O is like Oscar not
>Zero. So, follow my instructions and you shouldn't have any problems.
>
>--- Sean
>
>On Sun, 15 Jul 2001, Aake Svensson wrote:
>
>> Thanks for the help with kernel problem!
>>
>> But now there are new problems with the compiling. Using the command:
>>
> > "gcc -DMODULE -D__KERNEL__ -I /usr/src/linux-2.2.4/include/ -Wall
>> -Wstrict-prototypes -O6 -c rtl8139.c"
>>
>> will get these warnings:
>>
>> "In function 'rtl8139_open'
>> 675: structure has no member 'tbusy' "
>>
>> and many more (the members missing are tbusy, interrupt, start)
>> When using the command "head 675 rtl8139.c" it goes to line 675 in
>> the file rtl8139.c which reads "dev->tbusy=0;" ( the line before is:
>> "rtl_hw.start (dev);" ).
>>
>> Whats wrong? Are there any packages I need to install from the YDL
>> 2.0 CD's? (First time I installed YDL I tried the complete full
>> install (without caffeine) and it failed, so went for the Home Office
>> install instead which installed smoothly.) Or have I given the wrong
>> commands to gcc?
>>
>> Best regards,
>>
>> ‰ke Svensson, Sweden (first time compiling, ever)
>>
>>
>>
>>
>>
>> >I believe the 2.2.19 kernel source is on the Tasty Morsels CD. For
>> >some reason the 2.4 kernel and the 2.2.19 source wound up together and
>> >vs. vrs.
>> >
>> >--- Sean
>> >
>> >On Fri, 13 Jul 2001, Aake Svensson wrote:
>> >
>> >> Thanks!
>> >>
>> >> Although i need more help - I can't find the source kernel for
>> >> 2.2.19-1k on any of the YDL three CD's. The source for kernel 2.4.4
>> >> is there though, but
>> >> i suppose using one source for compiling and then run under another
>> >> kernel invites problems? I found though 2.2.19 header rpm that I
>> >> installed but it didn't do any good, still missing *.h files!
>> >>
>> >> Could I install the kernel source from kernel.org, where they have
>> >> them all? Are those kernels compatible with mac? And how do i install
>> >> them when there not rpm's?
>> >>
>> >> best regards,
>> >>
>> >> âke Svensson
>> >>
>> >>
>> >> >First of all, make sure that you installed the kernel-source RPMS.
>> >> >Secondly, make sure that /usr/include/linux/version.h exists. If not,
>> >> >do the following:
>> >> >
>> >> >% cd /usr/src/linux ; make include/linux/version.h
>> >> >
>> >> >Then
>> >> >
>> >> >%cd /usr/src/modules
>> >> >
>> >> >You may have to mkdir the modules directory. Once you are inside that
>> >> >directory, copy the rtl8139.c file to /usr/src/modules. Then
>> >> >
> > >> >% gcc -DMODULE -D__KERNEL__ -Wall -Wstrict-prototypes -O6 \
>> >> >-c rtl8139.c '[ -f /usr/include/linux/modversions.h ] && echo \
> > >> >-DMODVERSIONS'
>> >> >
>> >> >% install -m 644 rtl8139.o /lib/modules/'uname -r'/net/
>> >> >
>> >> >Then edit /etc/conf.modules and add
>> >> >
>> >> >alias eth0 rtl8139
>> >> >
>> >> >Then reboot the machine. To activate the NIC card:
>> >> >
>> >> >% ifconfig eth0 up
>> >> >
>> >> >Then use netconfig to set up the DNS, IP, etc. (You can also use
>> >> >DHCP).
>> >> >
>> >> >--- Sean
> > >> >
>> >> >On Fri, 13 Jul 2001, Aake Svensson wrote:
>> >> >
>> >> >> I have a problem compiling a new ethernet card driver, rtl8139.c.
>> >> >> With YDL version 1.0.9 was installed but i got version 1.13 of
>> >> >> rtl8139.c from the internet (same author - D. Becker). But trying to
>> >> >> compile it with the command:
>> >> >>
>> >> >> gcc -DMODULE -Wall -Wstrict-prototypes -O6 -c rtl8139.c
>> >> >>
>> >> >> i get the following missing files:
>> >> >> linux/config.h
>> >> >> version.h
>> >> >> string.h
>> >> >> asm/processor.h
>> >> >> bitops.h
>> >> >> io.h
>> >> >> and 11 more!
>> >> >>
>> >> >> I gather that some include library files are missing but how can I
>> >> >> install them and are they compatible with Mac PPC? Also
>>how do I give
>> >> >> GCC the right include command? No clues for me in the GCC man page.
>> >> > >
>> >> > > I'm a newbie, happy that I could install GCC on my "Home Office"
>> >> > > installation of YDL 2.0.
>> >>
>> >>
>> >>
>>
>>
>>



This archive was generated by hypermail 2a24 : Mon Jul 16 2001 - 12:19:24 MDT