Newbie question

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Newbie question

Tom Nabhani
Hi,

I'm having some difficulty using the boost libraries in my programs (I have an iBook running Panther).  My boost install passes all the regression tests.  My files are all stored in the appropriate places under /usr/local.  But when I try to #include <boost> libraries in my programs, the compiler doesn't seem to find them.  I'm assuming that there is some very simple stupid problem with the way my computer is set up, but I don't know enough about using c++ libraries to know what to do. I'm a pretty experienced Java programmer, but I'm very new to c++.  Unfortuntately I don't have anyone to ask how to solve this problem.  I hope this doesn't try your patience too much, but could anybody suggest how I might get this problem fixed?

Thanks,

Tom

_______________________________________________
Boost-users mailing list
[hidden email]
http://lists.boost.org/mailman/listinfo.cgi/boost-users
Reply | Threaded
Open this post in threaded view
|

Re: Newbie question

David Abrahams
"Tom Nabhani" <[hidden email]> writes:

> Hi,
>
> I'm having some difficulty using the boost libraries in my programs (I have
> an iBook running Panther).  My boost install passes all the regression
> tests.  My files are all stored in the appropriate places under /usr/local.
> But when I try to #include <boost> libraries in my programs, the compiler
> doesn't seem to find them.  I'm assuming that there is some very simple
> stupid problem with the way my computer is set up, but I don't know enough
> about using c++ libraries to know what to do. I'm a pretty experienced Java
> programmer, but I'm very new to c++.  Unfortuntately I don't have anyone to
> ask how to solve this problem.  I hope this doesn't try your patience too
> much, but could anybody suggest how I might get this problem fixed?

you need to put the Boost root directory in your #include path, by
adding

       -Ipath/to/boost/root

to your g++ command line.  The boost root directory is the one
containing a subdirectory called "boost," which subdirectory contains
lots of .hpp files.

HTH,

--
Dave Abrahams
Boost Consulting
www.boost-consulting.com

_______________________________________________
Boost-users mailing list
[hidden email]
http://lists.boost.org/mailman/listinfo.cgi/boost-users
Reply | Threaded
Open this post in threaded view
|

Re: Newbie question

Mortoc
Also, if you are using some version of XCode, you can set that up in the
IDE rather than the g++ command line.
If you right click (or ctrl click) on the project icon in the Group &
Files window, and go to Get Info, uner the build tab there is a line for
additional header search paths. Just add things to that (also remember
this for later, the next line is Library Search Paths which you will
need later for some Boost functionality).

-Chris

David Abrahams wrote:

> "Tom Nabhani" <[hidden email]> writes:
>
>  
>> Hi,
>>
>> I'm having some difficulty using the boost libraries in my programs (I have
>> an iBook running Panther).  My boost install passes all the regression
>> tests.  My files are all stored in the appropriate places under /usr/local.
>> But when I try to #include <boost> libraries in my programs, the compiler
>> doesn't seem to find them.  I'm assuming that there is some very simple
>> stupid problem with the way my computer is set up, but I don't know enough
>> about using c++ libraries to know what to do. I'm a pretty experienced Java
>> programmer, but I'm very new to c++.  Unfortuntately I don't have anyone to
>> ask how to solve this problem.  I hope this doesn't try your patience too
>> much, but could anybody suggest how I might get this problem fixed?
>>    
>
> you need to put the Boost root directory in your #include path, by
> adding
>
>        -Ipath/to/boost/root
>
> to your g++ command line.  The boost root directory is the one
> containing a subdirectory called "boost," which subdirectory contains
> lots of .hpp files.
>
> HTH,
>
>  


_______________________________________________
Boost-users mailing list
[hidden email]
http://lists.boost.org/mailman/listinfo.cgi/boost-users