Reputation: 196
Where does debian stores C header files like stdio.h
, string.h
etc? I am working on a project and I need to add a header file to the location but I couldn't locate it anywhere.
Upvotes: 3
Views: 19131
Reputation: 121599
Typically in /usr/include
It wouldn't hurt to run a command like this to make sure you've got the "basics" like compiler and standard headers: apt-get install build-essential
Failing all else, you can also do a "find". For example:
find / -name stdio.h -print 2> /dev/null
Upvotes: 2
Reputation: 213268
The system headers are in /usr/include
and the headers for user-installed packages are in /usr/local/include
.
But you only should put headers there if you are writing a library which other projects will use. Otherwise, you should use the -I
flag for your compiler to specify the location of additional header file search paths.
Upvotes: 8