LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
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 12-22-2008, 03:12 AM   #1
navderm
Member
 
Registered: Dec 2008
Location: Chandigarh, India
Distribution: Red Hat 9
Posts: 67

Rep: Reputation: 15
the problem with rtl.h and the make file


i have included rtl.h within <> signs.
and the Makefile has the code

hello.o: hello.c
gcc $(CFLAGS) hello.c

(this program was copied from one of the pdfs to learn real time controling and i got stuck so would need help please)

after this the rtl.mk was copied to the same folder

typing make -f rtl.mk hello.o doesn't help and i am not being able to create hello.o.

if i try to create it using normal gcc code it shows error as the code includes rtl.h header.

what should i do??
 
Old 12-22-2008, 03:56 AM   #2
jcookeman
Member
 
Registered: Jul 2003
Location: London, UK
Distribution: FreeBSD, OpenSuse, Ubuntu, RHEL
Posts: 417

Rep: Reputation: 33
http://www.linuxtopia.org/online_boo...cintro_23.html

You can also use the -I and -L options to point to the directory where rtl.h resides (recommended).

If it's in the same subdir as the source, then use "" as in:

Code:
#include "rtl.h"
But, I doubt that's the case with that file.
 
Old 12-22-2008, 06:30 AM   #3
cupubboy
Member
 
Registered: May 2003
Location: Bucharest,Romania
Distribution: Fedora Core 7
Posts: 109

Rep: Reputation: 15
Quote:
Originally Posted by jcookeman View Post
http://www.linuxtopia.org/online_boo...cintro_23.html

You can also use the -I and -L options to point to the directory where rtl.h resides (recommended).

If it's in the same subdir as the source, then use "" as in:

Code:
#include "rtl.h"
But, I doubt that's the case with that file.
Just a small nitpick with -I (upper case i) you will specify additional directories to search in when compiling (thus directories that contain files you need to include in your code; -L is used to specify additional directories to search in when linking ( so as to find libraries specified with -l (lower case L) to link your code against).

Cheers
 
  


Reply



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
Help needed for make file problem : make: *** No rule to make target `flash', needed rameshsatyavaram Linux - Newbie 3 09-11-2008 02:13 AM
RTL 8193D Time out problem antken Linux - Networking 0 04-08-2007 05:42 PM
RTL 8029 problem with kernel 2.6.10 ae1 Linux - Networking 1 06-28-2006 01:56 AM
Make Trouble linking some fortran code Make file problem? any ideas? TheBrick Linux - General 0 05-17-2006 11:21 AM
rtl 8100 problem orouwk Linux - Hardware 0 01-31-2005 04:31 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 07:12 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration