• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 265
  • Last Modified:

INCLUDE files can't be found.

I am trying to compile various sybase products. I realised I hadn't installed the include files eg.(stdio.h,stdlib.h)
So I whacked on the Kernel headers RPM
well no i can don a global disk search and find the include files. but programs I am compiling cannot find the include files.
they aren't all in the one directory either.
Basically my question is:

How is the path of the include files set?
  • 2
1 Solution
I just assume that your include files are in the follow directory:
Then, you need the following command to compile:
gcc -I/mount1/include my.c -o my.o

cam_ratAuthor Commented:
the include files are located in more than one location.
I am using Makefiles.
I shouldn't have to enter the path into the makefile.
the include path should be located elsewhere.
You need to include the include paths in your Makefile; there is a Makefile variable INCLUDES. If the files are in more than one location, you might want to define it like
INCLUDES = -I/usr/include -I/usr/local/include -I/home/cam_rat/include etc in your Makefile.

Good Luck
cam_ratAuthor Commented:
sorry.. I looked at your first comment more closely and you were perfectly right.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now