building makefiles/modules in 2.6.0

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



dear list,

i was compiling/booting the new 2.6.0 stable kernel release.
everything worked fine, i am able to load modules etc.

one problem remains unsolved:
i was working on a module for the 2.4.20 kernel, that i previously used.

compilation flags for that module:
"gcc -c -O2 -W -I/mnt/src/linux-2.4.20/include -fomit-frame-pointer bleh.c"
__KERNEL__ and MODULE were defined in the source file directly.

when i am compiling that module under the 2.6.0 kernel, i cannot insmod it because
it is an 'invalid module format'. i've read a dozen articles about that the modules are
named .ko since 2.6.0 or 2.5.0; but obviously, simply renaming the object file doesnt fix that.

i've also read, that it is required to link the module, against the current
source tree of the configured and compiled kernel tree.

my question is now, how am i able to build my module in a simple way so that i can insmod it?
there has to be a way to write a simple makefile that will build your module, no?

thanks for your time
threadhead

PS: yes i read
http://lwn.net/Articles/21823/
http://lwn.net/Articles/driver-porting/

i tried the makefile posted in one of the articles, but it doesnt work because:
"no rule to make bleh.c".

______________________________________________________________________________
Nachrichten, Musik und Spiele schnell und einfach per Quickstart im 
WEB.DE Screensaver - Gratis downloaden: http://screensaver.web.de/?mc=021110

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux