use boost without include path?

Started by
14 comments, last by Storyyeller 12 years, 5 months ago
"the headers include themselves with an absolute path. "

I don't know what platform you're on, but on my Linux system, they all say "#include <boost/WHATEVER>"
Advertisement
You could always just pre-process all files locally. Most of relevant boost stuff is header only.

"the headers include themselves with an absolute path. "

I don't know what platform you're on, but on my Linux system, they all say "#include <boost/WHATEVER>"


I meant absolute in terms of the boost directory. If boost isn't in your include path, then #include <boost/WHATEVER> won't work. As opposed to just #include "WHATEVER", which would work since it's in the same directory.
I trust exceptions about as far as I can throw them.
I tried that and it doesn't work. You'd have to nest a new copy of the boost directory for every level of inclusion.
I trust exceptions about as far as I can throw them.

I tried that and it doesn't work. You'd have to nest a new copy of the boost directory for every level of inclusion.

That implies something is pretty screwed up in your build system - it should always start from the top-level directory where your makefile resides.

Tristam MacDonald. Ex-BigTech Software Engineer. Future farmer. [https://trist.am]

I tried uploading it, and it doesn't build on their system either.
I trust exceptions about as far as I can throw them.

If you know regular expression and a decent script, such as Perl or Python, or you are a master of Unix commands, it's easy to change all headers to remove "boost/".
Or if you only use several boost headers, how about change them manually, just spending half an hour?


I actually tried writing a Python script to fix all the include paths. It's harder than it sounds because they use macros to define some of the includes, and filenames of headers also appear in the comments. However, I managed it eventually.
I trust exceptions about as far as I can throw them.

This topic is closed to new replies.

Advertisement