Visit the LQ Articles and Editorials section
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 12-26-2004, 08:41 AM   #1
Registered: Nov 2004
Location: india
Distribution: Fedora core 1
Posts: 67

Rep: Reputation: 15
creating Makefile with multiple kernel module files

I am not getting how to write a Makefile and require your help. I have written 2 modules in which exporting_module.c exports function and using_module.c uses that module.
when i give following command without creatinf makefile i got errors

[myhost@localhost module]# gcc -c using_module.c exporting_module.c -I /usr/src/linux-2.4.22-1.2115.nptl/include/
using_module.c: In function `func1':
using_module.c:30: warning: assignment makes pointer from integer without a cast
exporting_module.c:106: error: syntax error before "this_object_must_be_defined_as_export_objs_in_the_Makefile"
exporting_module.c:106: warning: data definition has no type or storage class

I have defined MODULE and __KERNEL__ symbols in both modules.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Creating Multiple Log Files koacamper Linux - Newbie 3 09-24-2005 07:24 PM
Debian :trouble creating a kernel module covertops Linux - Newbie 2 03-21-2005 08:31 AM
Require a Makefile for kernel module programs b123coder Linux - Newbie 1 12-28-2004 10:11 AM
Creating a Makefile with multiple header files MattG1981 Programming 4 07-28-2004 05:04 PM
module makefile for c++ in kernel 2.6 yuhuahe Linux - Software 0 04-14-2004 06:03 PM

All times are GMT -5. The time now is 09:22 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration