LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
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.

Notices

Reply
 
Search this Thread
Old 07-18-2006, 11:25 PM   #1
Nishant Desai
Member
 
Registered: Jul 2006
Posts: 100
Blog Entries: 1

Rep: Reputation: 15
How to compile the program with the makefile?


Dear All,

I am somewhat new to the Linux world and i have given some source code, but i am not in the position to compile it and download it into the board, the main difficulty is, i have given the source code of stand alone device drivers, which does not contain void main, so that i think it wont compile as stand alone and it requires the main file to compile with, but i couldnt found the main file and then i asked my friend and he gave me some idea about the make file and he told me that there will be some information in the make file, which will guide you to compile the program, i have the make file with the program and it also contains some information, but i couldnt understand the data given inside the make file, here i am giving information contained in the make file, can you please guide me what it is suggesting to do?

My Makefile:

----------------------------------------------------------------------------------------------------------------------------------

# File: drivers/at91/serial/Makefile
#
# Makefile for the Atmel AT91RM9200 serial and console device drivers
#

O_TARGET := at91serial.o

obj-y :=
obj-m :=
obj-n :=
obj- :=

obj-$(CONFIG_SERIAL_AT91) += at91_serial.o

include $(TOPDIR)/Rules.make

----------------------------------------------------------------------------------------------------------------------------------

Please help me, i am new to this field and want to do it as early as possible.

Thanks,
Nishant
 
Old 07-18-2006, 11:27 PM   #2
seneschal
LQ Newbie
 
Registered: Jul 2006
Location: Minnesota
Distribution: RHEL, Debian, Ubuntu
Posts: 27

Rep: Reputation: 15
Did you try ./configure && make && make install?
 
Old 07-19-2006, 12:07 AM   #3
raskin
Senior Member
 
Registered: Sep 2005
Location: Russia
Distribution: NixOS (http://nixos.org)
Posts: 1,893

Rep: Reputation: 68
Do you have some old distribution? This code is for kernel version 2.4. And kernel driver do not need to have 'int main' because of the way it is used by kernel.
 
  


Reply


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
makefile to compile kernel? RIgimp75 Slackware 7 07-19-2006 01:42 AM
Makefile.rules not found during kernel compile anilbh Fedora 1 02-21-2006 09:27 AM
Makefile to resursively compile a folder tree yapp Programming 5 06-14-2005 07:51 PM
how to get (makefile -f makefile )output into the textview widget in Pygtk sailu_mvn Programming 3 02-28-2005 03:57 AM
generate Makefile from Makefile.in without calling ./configure ? chris78 Programming 2 05-02-2004 12:23 PM


All times are GMT -5. The time now is 08:17 PM.

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