editing the search path for '#include' preprocessor
Reid Linnemann
lreid at cs.okstate.edu
Wed Jun 27 13:11:08 UTC 2007
Written by sameer gupta on 06/27/07 05:05>>
> hello,
> i want to add new search path's for including more directories for header
> files, for that i need to edit the makefile that my gcc compiler uses,
> however i cant figure out where to find that file, kindly help..i'm a
> newbie
> who has just started out
> regards,
> sameer
If you're wanting to add system include paths permanently to gcc, AFAIK
you'll have to edit /usr/src/contrib/gcc/cppdefaults.c and add the paths
you want to the cpp_include_defaults array. However, cpp already has a
non-invasive way of supplying extra include paths with the -I flag, or
you can set the CPATH environemtn vairable to the paths you would like
to search (its form is exactly like that of PATH).
More information about the freebsd-questions
mailing list