Skip to Content.
Sympa Menu

baslinux - Compiling kernel module (Was Re: [BL] ethernet problem)

baslinux AT lists.ibiblio.org

Subject: Baslinux mailing list

List archive

Chronological Thread  
  • From: Sindi Keesan <keesan AT iamjlamb.com>
  • To: baslinux AT lists.ibiblio.org
  • Subject: Compiling kernel module (Was Re: [BL] ethernet problem)
  • Date: Thu, 17 Jun 2004 15:42:41 -0400 (EDT)

Perhaps I really do need a makefile, not just the gcc line provided at the
end of the winbond-840.c file. I could not find any place to put this
line in the Makefile so proceeded on the assumption that Makefile would
find it in the .c file.


I added the two lines below to Makefile, which I put in /usr/src/modules
along with kern_compat.h and pci-scan.h and pci-scan.c (they should
probably go somewhere else - with the other .h files? - but I wanted to
see how far I could get using Makefile) and then typed make all.

A lot of error messages went by on the screen.
Pages and pages of them. stray '\' in program (many times)
nondigits in number and not hexadecimal (once)
storage size of atomic_read isn't known (and many more like that)
Then a couple of warnings about bad code (?) in pci-scan.c
Fatal error: Symbol vide already defined.

What is the correct procedure for using the Makefile as modified above,
kern_compat.h pci-scan.h pci-scan.c, and winbond-840.c? Obviously I am
not doing this correctly and it does not seem to be the same as compiling
a program (with or without configure).

I tried to follow the instructions from scyld. I have version.h and I put
the driver source code in /usr/src/modules (not pci-scan.c tho). 'Compile
the file using the compile-command at the bottom of the driver source
file' (gcc .....). I tried just typing that line (with -I switch) and got
one set of error messages. I tried make all and got another set.

I mistyped the scyld download link: try ftp.scyld.com/pub/network (not
www). Makefile, winbond.c and the others are there.

I may give up on all this for a while and fix a couple of other problems
(this computer does not recognize the CD-ROM drive or 360K B: drive) but
it would be really nice to know how to compile kernel modules since BL2
(SW71) is likely to be missing other ones for not-all-that-new devices.
My ethernet cards are 1999, which I think counts as old equipment by now.
All the instructiosn I have found assume you already know how to compile
kernel modules and just need a few specific changes.


On Mon, 14 Jun 2004 3aoo-cvfd AT dea.spamcon.org wrote:

> Sindi Keesan wrote:
> >
> > I have attached the Makefile. I welcome any helpful
> > suggestions as to just what to do with it.
> >
> ># You may specify a kernel with the following variables.
> ># KERN_INCLUDE The include directory for the target kernel.
> ># MODULEDIR The directory where netdriver modules should be installed.
>
> KERN_INCLUDE=/usr/src/linux-2.2.16/include
> MODULEDIR=/lib/modules/2.2.16/misc
>
> Cheers,
> Steven
>





Archive powered by MHonArc 2.6.24.

Top of Page