Re: How to link the module ?

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

 



Try this:

ld -r <list of ur .o file> -o <ur obj file name>

for eg,

ld -r main.o pipe.o fifo.o msg_q.o -o final.o


Regards
bhaskar
On Mon, 2004-06-21 at 20:13, Gaurav Dhiman wrote:
> 
> Hi,
>  
> I have made the multi source file module and compiled it sucssufully with following comand:
>  
> gcc - c main.c pipe.c fifo.c msg_q.c
>  
> Now I have the corresponding .o file with me. Can someone tell me how can I link it to each other to form one file of module. How can we resolve the internal reference (reference to our own variable and functions) without getting any errors or warninng for kernel symbols. I know kernel symbols are resolved at load time by 'insmod'.
> Please let me know how to resolve the internal symbols and get one file for module which we can load using 'insmod'. Please let me know the command.
>  
> Regards,
> Gaurav.
>  
> 
> 		
> ---------------------------------
> Do you Yahoo!?
> New and Improved Yahoo! Mail - 100MB free storage!



--
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