Search This Blog

Monday, November 2, 2009

FreeBSD, Include and Library Path

For user installed header file and library:

/usr/local/include (header files for you to compile your program)
/usr/local/lib (definition ( compile library files) for you to link final executable)

For example:
g++ tls.cc -I/usr/local/include /usr/local/lib/libZThread-2.3.so.2

to use boost header-only library
g++ sp.cc -I/usr/local/include

or include the library path too
g++ sp.cc -I/usr/local/include -L~/boost/stage/lib/ -lboost_regex-gcc34-mt-d-1_36

No comments: