We help IT Professionals succeed at work.

Default headers location - gcc

liorsolomon
liorsolomon asked
on
Medium Priority
874 Views
Last Modified: 2012-08-13
This is a beginners question
I wanted to know where should i locate the gcc headers on a ubuntu distro
I checked the /usr/include folder but nothing there
and i keep on getting gcc error while trying to include stdio.h header
Thanks
Comment
Watch Question

Commented:
Please port the relevant part of your source and the command line you are using to try to compile and the error message.

Author

Commented:
just a sample code:

#include <stdio.h>

int main(){

             char bell = '\\a';
             printf ("gring!%c\\n",bell);
}

command line:
gcc bell.c -o bell

bell.c:1:19: error: stdio.h: No such file or directory
Top Expert 2005

Commented:
/usr/include is the default location.  How did you install gcc?
Where is it installed?  What does the command 'which gcc' return?

Author

Commented:
well i figured it out already
the issue was that i installed basic ubuntu distro and gcc was already installed
but the libc-dev wasn't
i just added it and now i have all the missing files
thanks anyway
Duncan RoeSoftware Developer
CERTIFIED EXPERT

Commented:
Post in the community support area asking for a refund

Author

Commented:
can you give me please the link to the community support area?
I just post a message asking for refund?
Duncan RoeSoftware Developer
CERTIFIED EXPERT

Commented:
All topics / Community Support
Dear,
simply locate for file stdio.h, in Red Hat Linux it is done with locate command, (# locate filename )
search for similar command in Ubuntu linux, then update your make file.

All the best
S.Prashant Sabnekar
Duncan RoeSoftware Developer
CERTIFIED EXPERT

Commented:
Prashant - look at the comments above. He already fixed it for himself (hadn't installed glibc-devel). I say refund his points.
Commented:
Closed, 125 points refunded.
GranMod
The Experts Exchange
Community Support Moderator of all Ages

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.