I have been using b2 to build the preprocessed files for boost phoenix. When I try to do this it now fails with a failure to build thread.cpp "g++-4.6" -ftemplate-depth-128 -O3 -finline-functions -Wno-inline -Wall -pedantic -pthread -Wextra -Wno-long-long -Wno-variadic-macros -Wunused-function -pedantic -DBOOST_ALL_NO_LIB=1 -DBOOST_SYSTEM_STATIC_LINK=1 -DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_DONT_USE_CHRONO -DBOOST_THREAD_POSIX -DBOOST_WAVE_SUPPORT_THREADING=0 -DNDEBUG -I"../../.." -c -o "../../../bin.v2/libs/thread/build/gcc-4.6/release/link-static/threading-multi/wavetool-on/pthread/thread.o" "../../../libs/thread/src/pthread/thread.cpp" ../../../boost/ref.hpp:32:25: error: redefinition of ‘class boost::reference_wrapper<T>’ ../../../boost/core/ref.hpp:59:25: error: previous definition of ‘class boost::reference_wrapper<T>’ ../../../boost/ref.hpp:56:75: error: redefinition of ‘template<class T> const boost::reference_wrapper<T> boost::ref(T&)’ ../../../boost/core/ref.hpp:131:74: error: ‘template<class T> const boost::reference_wrapper<T> boost::ref(T&)’ previously declared here . It looks as though it is picking up two copies of the header file ref.hpp. This is the case with both gcc 4.6 and also gcc 4.9.0 It is not clear to me where the source file is coming from. At the moment all the libraries in my modular boost are checked out as develop. This is meaning that I cannot update my preprocessed files. Please advise me what to do. Thanks John
On Friday 27 June 2014 19:53:18 Fletcher, John P wrote:
I have been using b2 to build the preprocessed files for boost phoenix.
When I try to do this it now fails with a failure to build thread.cpp
"g++-4.6" -ftemplate-depth-128 -O3 -finline-functions -Wno-inline -Wall -pedantic -pthread -Wextra -Wno-long-long -Wno-variadic-macros -Wunused-function -pedantic -DBOOST_ALL_NO_LIB=1 -DBOOST_SYSTEM_STATIC_LINK=1 -DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_DONT_USE_CHRONO -DBOOST_THREAD_POSIX -DBOOST_WAVE_SUPPORT_THREADING=0 -DNDEBUG -I"../../.." -c -o "../../../bin.v2/libs/thread/build/gcc-4.6/release/link-static/threading-mu lti/wavetool-on/pthread/thread.o" "../../../libs/thread/src/pthread/thread.cpp"
../../../boost/ref.hpp:32:25: error: redefinition of ‘class boost::reference_wrapper<T>’ ../../../boost/core/ref.hpp:59:25: error: previous definition of ‘class boost::reference_wrapper<T>’ ../../../boost/ref.hpp:56:75: error: redefinition of ‘template<class T> const boost::reference_wrapper<T> boost::ref(T&)’ ../../../boost/core/ref.hpp:131:74: error: ‘template<class T> const boost::reference_wrapper<T> boost::ref(T&)’ previously declared here . It looks as though it is picking up two copies of the header file ref.hpp.
This is the case with both gcc 4.6 and also gcc 4.9.0
It is not clear to me where the source file is coming from. At the moment all the libraries in my modular boost are checked out as develop.
This is meaning that I cannot update my preprocessed files.
Please advise me what to do.
Check that you completely updated all submodules, core and utility in particular. If they are fully updated I suspect you may need to remove $BOOST_ROOT/boost and run 'b2 headers'.
________________________________________ From: Boost [boost-bounces@lists.boost.org] on behalf of Andrey Semashev [andrey.semashev@gmail.com] Sent: 27 June 2014 21:00 To: boost@lists.boost.org Subject: Re: [boost] [wave] preprocess fails using b2 On Friday 27 June 2014 19:53:18 Fletcher, John P wrote:
I have been using b2 to build the preprocessed files for boost phoenix.
When I try to do this it now fails with a failure to build thread.cpp
Please advise me what to do.
Check that you completely updated all submodules, core and utility in particular. If they are fully updated I suspect you may need to remove $BOOST_ROOT/boost and run 'b2 headers'.
I have done that and it still fails. On closer inspection the failure is related to boost/bind in some way: In file included from ../../../boost/bind/bind.hpp:25:0, from ../../../boost/bind.hpp:22, from ../../../boost/thread/detail/thread.hpp:29, from ../../../boost/thread/thread_only.hpp:22, from ../../../libs/thread/src/pthread/thread.cpp:11: ../../../boost/ref.hpp:32:25: error: redefinition of ‘class boost::reference_wrapper<T>’ ../../../boost/core/ref.hpp:59:25: error: previous definition of ‘class boost::reference_wrapper<T>’ John _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
On Jun 27, 2014, at 2:24 PM, "Fletcher, John P"
From: Boost [boost-bounces@lists.boost.org] on behalf of Andrey Semashev [andrey.semashev@gmail.com] Sent: 27 June 2014 21:00 To: boost@lists.boost.org Subject: Re: [boost] [wave] preprocess fails using b2
On Friday 27 June 2014 19:53:18 Fletcher, John P wrote:
I have been using b2 to build the preprocessed files for boost phoenix.
Check that you completely updated all submodules, core and utility in particular. If they are fully updated I suspect you may need to remove $BOOST_ROOT/boost and run 'b2 headers'.
I have done that and it still fails. On closer inspection the failure is related to boost/bind in some way:
In file included from ../../../boost/bind/bind.hpp:25:0, from ../../../boost/bind.hpp:22, from ../../../boost/thread/detail/thread.hpp:29, from ../../../boost/thread/thread_only.hpp:22, from ../../../libs/thread/src/pthread/thread.cpp:11: ../../../boost/ref.hpp:32:25: error: redefinition of ‘class boost::reference_wrapper<T>’ ../../../boost/core/ref.hpp:59:25: error: previous definition of ‘class boost::reference_wrapper<T>â
How is this possible, there's only 17 lines in libs/core/include/boost/ref.hpp. Check that: boost/ref.hpp -> libs/core/include/boost/ref.hpp -- Noel
________________________________________ From: Boost [boost-bounces@lists.boost.org] on behalf of Fletcher, John P [j.p.fletcher@aston.ac.uk] Sent: 27 June 2014 21:24 To: boost@lists.boost.org Subject: Re: [boost] [wave] preprocess fails using b2 ________________________________________ From: Boost [boost-bounces@lists.boost.org] on behalf of Andrey Semashev [andrey.semashev@gmail.com] Sent: 27 June 2014 21:00 To: boost@lists.boost.org Subject: Re: [boost] [wave] preprocess fails using b2 On Friday 27 June 2014 19:53:18 Fletcher, John P wrote:
I have been using b2 to build the preprocessed files for boost phoenix.
When I try to do this it now fails with a failure to build thread.cpp
Please advise me what to do.
Check that you completely updated all submodules, core and utility in particular. If they are fully updated I suspect you may need to remove $BOOST_ROOT/boost and run 'b2 headers'.
I have done that and it still fails. On closer inspection the failure is related to boost/bind in some way: In file included from ../../../boost/bind/bind.hpp:25:0, from ../../../boost/bind.hpp:22, from ../../../boost/thread/detail/thread.hpp:29, from ../../../boost/thread/thread_only.hpp:22, from ../../../libs/thread/src/pthread/thread.cpp:11: ../../../boost/ref.hpp:32:25: error: redefinition of ‘class boost::reference_wrapper<T>’ ../../../boost/core/ref.hpp:59:25: error: previous definition of ‘class boost::reference_wrapper<T>’ John Further information: thread was changed on 9 June 2014 to use core versions of files. It is clear reading the codes that boost/core/ref.hpp is a recent (2014) development of boost/ref.hpp. They have different include protection but are not able to work together as they both define the same structure (see error messages) above.
Hi,
Op 28 jun. 2014 om 09:37 heeft "Fletcher, John P"
On Friday 27 June 2014 19:53:18 Fletcher, John P wrote:
I have been using b2 to build the preprocessed files for boost phoenix.
When I try to do this it now fails with a failure to build thread.cpp
Please advise me what to do.
Check that you completely updated all submodules, core and utility in particular. If they are fully updated I suspect you may need to remove $BOOST_ROOT/boost and run 'b2 headers'.
I have done that and it still fails. On closer inspection the failure is related to boost/bind in some way:
In file included from ../../../boost/bind/bind.hpp:25:0, from ../../../boost/bind.hpp:22, from ../../../boost/thread/detail/thread.hpp:29, from ../../../boost/thread/thread_only.hpp:22, from ../../../libs/thread/src/pthread/thread.cpp:11: ../../../boost/ref.hpp:32:25: error: redefinition of ‘class boost::reference_wrapper<T>’ ../../../boost/core/ref.hpp:59:25: error: previous definition of ‘class boost::reference_wrapper<T>’
John
Further information: thread was changed on 9 June 2014 to use core versions of files.
It is clear reading the codes that boost/core/ref.hpp is a recent (2014) development of boost/ref.hpp. They have different include protection but are not able to work together as they both define the same structure (see error messages) above.
Did you use: git submodule update --init before removing boost and running b2 headers? It solved similar problems for me. https://svn.boost.org/trac/boost/wiki/StartModMaint Sent from iPad. Barend Gehrels www.barendgehrels.nl
I'm trying to implement a custom wave pragma using the interpret_pragma hook but having a bit of difficulty. If I run the preprocess_pragma_output example, the output of preprocessing example.cpp is as expected. When I try to use the alternative _Pragma() syntax I'm unable to duplicate the results- for example _Pragma("wave pp \"#define C() 1.0\n\"") C() Just preprocesses to C() I've been using a gcc pragma page https://gcc.gnu.org/onlinedocs/cpp/Pragmas.html as a reference, and poked around a bit more on the net but have been unable to arrive at anything that works. Here are the definitions in 'libs/wave/samples/preprocess_pragma_output/example.cpp' #pragma wave pp ( \ "#define A() \"some text\" and more\n" \ "#define B() 1.0\n" \ ) \ /**/ A() // this should produce: "some text" and more B() // and this expands to 1.0 Does anyone have an idea how to re-write this using the _Pragma() syntax? Erik ---------------------------------------------------------------------- This message, and any attachments, is for the intended recipient(s) only, may contain information that is privileged, confidential and/or proprietary and subject to important terms and conditions available at http://www.bankofamerica.com/emaildisclaimer. If you are not the intended recipient, please delete this message.
participants (5)
-
Andrey Semashev
-
Barend Gehrels
-
Belcourt, Kenneth
-
Fletcher, John P
-
Nelson, Erik - 2