Bekijk de volledige versie : Building kernel modules

12-05-2007, 12:53
I just bought a wl500gp, and installed Oleg's firmware. It works fine, a really good work! My only problem is that it's a bit short on kernel modules.

First it need a reiserfs module. Unfortunately migrating all my data to ext3 is currently not an option.
The question is: what is THE recommended toolchain and kernel source to build modules. If I get a _stock_ buildroot, generate a MIPS little endian toolchain and compile a _stock_ 2.4.20 kernel modules, will that work?
I'm just asking because I don't want "play" around for days trying useless solutions.

Second question (not that important right now): What is THE recommended way of building userspace applications? I see that this firmware has a nice ipkg based package system. So if I cross-compile an application it fits into the current layout. By this I mean configuration management, linking against shared libs on the system (not static linked apps). Eventually the package could land in the ipkg repository.

Third: does this project has a wiki? Something like wiki.gp2x.org?


08-10-2007, 11:48
Hi again!
I've managed to build kernel modules (reiserfs :) ). Drop me a note here if you're interested.

08-10-2007, 23:10
Sounds pretty good, it would allow me to use all my hdds from my outdated freenas server!
How can I get the module and a short how to?


21-01-2008, 20:53
Well, if you manage to build the NTFS-3G modules, then would be a damn big THANK YOU!

Also, would be nice if you can write a guide for newbies about compiling modules.

22-01-2008, 21:42
Well, if you manage to build the NTFS-3G modules, then would be a damn big THANK YOU!

NTFS-3G needs FUSE and FUSE needs atleast a 2.4.21 kernel (instead of 2.4.20). Oleg already tried to port it, but didn't succeed...

24-01-2008, 15:11
At now OpentWRT kamikaze 7.09 based on 2.4.34 linux kernel only. In future, Oleg also has plan to migrate to 2.4.36 kernel, but this task is really hard.

24-07-2008, 01:05
I need to compile a kernel module for a 3G-modem called Option Icon 225. I've found the instructions for Ubuntu, http://www.pharscape.org/content/view/66/53/, but how would you do it on an Asus running Oleg or the Koppel image (native build)?

I've installed the optware devel package and the build root, but all the guides I've found presumes that there is a configure script. This is however not the case here and another difference may be that I actually want to build a kernel module. Can anyone give me a clue on how to proceed?

05-08-2008, 14:15
Nothing new on this ?

05-08-2008, 17:14
Not much, I'm afraid. I'm about to give up.

About my modem problem:
In Ubuntu, this didn't involve any Linux kernel compilation using menuconfig or something like that. Will I need to do something like that on Oleg/Koppel? I realize that Ubuntu is a 2.6 kernel and Oleg/Koppel is 2.4.

14-08-2008, 15:24
Hello I'am interest in compiling modules too. I'm interested in http://incentivespro.com/downloads.html, because I would like to connect usb tv box to my windows computer over lan. Could you give me some hint hot to compile module, did you use cross compiling or did you did compile it on the router? THANKS!
This module can't be compiled because it needs Kernel 2.6.15 version and higher. My mistake, sorry!

25-08-2008, 23:44
I need to compile a kernel module for a 3G-modem called Option Icon 225.

Most kernel modules need to build inside the kernel tree (i.e. the sources need to be somewhere in the kernel-source directory, and you need to select the desired modules with menu-config)
I don't know if that's possible natively... Only way I know is cross-compile...
You can use this Tutorial (http://wl500g.info/showthread.php?p=107309#post107309) (Haven't tried that particular tutorial myself, but i guess it should work.

However, if I look at the makefile of the driver, it can also be build outside the kernel tree. (i.e unzip the sources somewhere, cd to that location, make && make install)
This method can only be used natively, cause it's using uname to get the kernel-version.

The only catch I can see so far, is that the makefile expects to find the kernel-sources in /lib/modules/{kernelversion}/build and ofcourse that doesn't exist. Also that location is read-only so you can't copy the sources there.
So you need to edit the makefile, so it seeks the kernelsources in another location and place the sources there. (f.e. change /lib/modules/.... in /opt/lib/modules/.....)

In this case I'd first try the second option, cause I have no experience in adding thirdparty drivers to a kernel-source..

11-11-2008, 20:17
...available here:


I compiled them from the GPL source ASUS released (GPL_1927.zip), the list of modules in the tar:

cramfs.o ext3.o isofs.o minix.o nfs.o reiserfs.o udf.o vfat.o
ext2.o fat.o jffs2.o msdos.o nfsd.o smbfs.o umsdos.o