
Hi, I am new to boost, just trying to use it for the first time. I have a test code which uses Boost and I am trying to get it running on my machine. But I get an error while compilation: In file included from /usr/include/boost/mpl/or.hpp:43:0, from /usr/include/boost/serialization/smart_cast.hpp:54, from /usr/include/boost/archive/detail/oserializer.hpp:41, from /usr/include/boost/archive/detail/interface_oarchive.hpp:23, from /usr/include/boost/archive/detail/common_oarchive.hpp:22, from /usr/include/boost/archive/basic_text_oarchive.hpp:32, from /usr/include/boost/archive/text_oarchive.hpp:31, from src/main.cc:1207: /usr/include/boost/mpl/aux_/include_preprocessed.hpp:37:90: fatal error: boost/mpl/aux_/preprocessed/gcc/||.hpp: No such file or directory compilation terminated. make[2]: *** [obj/debug/critpts.o] Error 1 This is the line 37 of file /usr/include/boost/mpl/aux_/include_preprocessed.hpp include BOOST_PP_STRINGIZE(boost/mpl/aux_/preprocessed/AUX778076_PREPROCESSED_HEADER) It looks like AUX778076_PREPROCESSED_HEADER is not defined correctly. Any ideas where I could go and check for this ? -- View this message in context: http://boost.2283326.n4.nabble.com/boost-includes-tp4454829p4454829.html Sent from the Boost - Users mailing list archive at Nabble.com.

Hi,
I am new to boost, just trying to use it for the first time. I have a test code which uses Boost and I am trying to get it running on my machine. But I get an error while compilation:
In file included from /usr/include/boost/mpl/or.hpp:43:0, from /usr/include/boost/serialization/smart_cast.hpp:54, from /usr/include/boost/archive/detail/oserializer.hpp:41, from /usr/include/boost/archive/detail/interface_oarchive.hpp:23, from /usr/include/boost/archive/detail/common_oarchive.hpp:22, from /usr/include/boost/archive/basic_text_oarchive.hpp:32, from /usr/include/boost/archive/text_oarchive.hpp:31, from src/main.cc:1207: /usr/include/boost/mpl/aux_/include_preprocessed.hpp:37:90: fatal error: boost/mpl/aux_/preprocessed/gcc/||.hpp: No such file or directory compilation terminated.
It seems that boost/mpl/or.hpp defines: # define BOOST_MPL_PREPROCESSED_HEADER or.hpp and since 'or' is an alternative token for the '||' operator, the preprocessor substitutes '||' for it. I'm not sure whether the preprocessor is supposed to perform this substitution at this stage or not... What version of GCC are you using? I tried with version 4.3 through 4.7, and I do not get this error with them. Regards, Nate

Thanks for the replies guys. I found out the solution. Nathan is right, the preprocessor was substituting "||" for "or". I was using somebody else's very old code as well, which had the following definitions #define and && #define or || #define not ! I removed those definition, and the errors went away. Thanks -- View this message in context: http://boost.2283326.n4.nabble.com/boost-includes-tp4454829p4457470.html Sent from the Boost - Users mailing list archive at Nabble.com.

-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi! Am 07.03.12 22:58, schrieb bhatiaharsh:
It looks like AUX778076_PREPROCESSED_HEADER is not defined correctly. Any ideas where I could go and check for this ?
Which version of Boost are you using? Which compiler are you using? What is the content of your main.cc here? Frank -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: keyserver x-hkp://pool.sks-keyservers.net iEYEARECAAYFAk9YWvUACgkQhAOUmAZhnmoTWgCcDVgk8YjXrq0rQwRCF0rPxvow uqIAn1yZ2vsP4J9GRG39zhhUGKLffB1p =BIzM -----END PGP SIGNATURE-----
participants (3)
-
bhatiaharsh
-
Frank Birbacher
-
Nathan Ridge