recompiling kernel goes fine, problem with make modules
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
recompiling kernel goes fine, problem with make modules
I am recompiling my kernel since the one I have installed came with my distro (Red Hat 8.0) and it has a lot of options and modules I don't need.
So I ran make menuconfig, configured my kernel, saved it no problems, ran make dep, make clean, make bzImage (image was too big with zImage) and everything went without a hitch. The image file is there in directory /usr/src/linux/arch/i386/boot/ . Then I proceeded to run make modules, when I got the following errors (I ommitted a lot of it, since it was pretty long):
make -r -f tmp_include_depends all
make: Entering directory `/usr/src/linux-2.4.18-17.8.0'
make: Nothing to be done for `all'.
make: Leaving directory `/usr/src/linux-2.4.18-17.8.0'
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:184: warning: function declaration isn't a prototype
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:185: `inter_module_get_R_ver_str' declared as function returning a function
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:185: warning: parameter names (without types) in function declaration
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:186: `inter_module_get_request_R_ver_str' declared as function returning a function
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:186: warning: parameter names (without types) in function declaration
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:187: invalid suffix on integer constant
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:187: parse error before numeric constant
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:187: `inter_module_put_R_ver_str' declared as function returning a function
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:187: warning: function declaration isn't a prototype
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:196: `try_inc_mod_count_R_ver_str' declared as function returning a function
/usr/src/linux-2.4.18-17.8.0/include/linux/module.h:196: warning: parameter names (without types) in function declaration
In file included from /usr/src/linux-2.4.18-17.8.0/include/linux/highmem.h:5,
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h: In function `get_pgd_fast':
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h:78: `boot_cpu_data_R0657d037' undeclared (first use in this function)
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h:78: (Each undeclared identifier is reported only once
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h:78: for each function it appears in.)
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h: In function `free_pgd_fast':
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h:89: `boot_cpu_data_R0657d037' undeclared (first use in this function)
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h: In function `pte_alloc_one_fast':
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h:127: `boot_cpu_data_R0657d037' undeclared (first use in this function)
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h: In function `pte_free_fast':
/usr/src/linux-2.4.18-17.8.0/include/asm/pgalloc.h:137: `boot_cpu_data_R0657d037' undeclared (first use in this function)
In file included from loop.c:79:
/usr/src/linux-2.4.18-17.8.0/include/linux/suspend.h:58:1: warning: "software_suspend" redefined
In file included from /usr/src/linux-2.4.18-17.8.0/include/linux/modversions.h:264,
from <command line>:1:
/usr/src/linux-2.4.18-17.8.0/include/linux/modules/suspend.ver:4:1: warning: this is the location of the previous definition
loop.c: In function `loop_change_fd':
loop.c:720: warning: implicit declaration of function `kernel_thread_R7e9ebb05'
loop.c:761: warning: label `out_put_all' defined but not used
make: *** [loop.o] Error 1
make: Leaving directory `/usr/src/linux-2.4.18-17.8.0/drivers/block'
make: *** [_modsubdir_block] Error 2
make: Leaving directory `/usr/src/linux-2.4.18-17.8.0/drivers'
make: *** [_mod_drivers] Error 2
There are probably dependency problems with your modules. When building the kernel, it can usually pick up dependency problems but with modules it can't.
Go back to the make xconfig and load the old .config file, when you do the make xconfig or whatever. Take things out carefully. Look at where the problems were - block devices. Make sure you don't touch anything there for the time being.
I ran make menuconfig more than once, and I let it save to the default file. I guess because I did it more than once the .config.old file got overwritten, and .config and .config.old are both the same now... I am out of luck there, still can't make modules..
The dependency tree for the kernel should resolve any problems. Make sure that you check everything you need. Of course pay particular attention to block devices because that's where you had problems before.
Looking at those error messages, there are problems with you kernel headers. Reinstall the kernel headers before proceeding.