This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/43915] Compiler flags error: error: invalid initialization of reference of type 'boost::thread&&' from expression of type 'boost::thread'
- From: "mlrus at mac dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Apr 2010 01:01:09 -0000
- Subject: [Bug c++/43915] Compiler flags error: error: invalid initialization of reference of type 'boost::thread&&' from expression of type 'boost::thread'
- References: <bug-43915-19096@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from mlrus at mac dot com 2010-04-28 01:01 -------
bash-3.2# cat build.2.log
Building the Boost C++ Libraries.
After the build, the headers will be located at
/usr/local/boost_1_42_0
The libraries will be located at
/usr/local/boost_1_42_0/stage/lib
Use 'bjam install --prefix=<path>' if you wish to install headers and
libraries to a different location and remove the source tree.
warning: Building Boost.Regex with the optional Unicode/ICU support disabled.
note: Please refer to the Boost.Regex documentation for more information
note: this is a strictly optional feature.
warning: Graph library does not contain MPI-based parallel components.
note: to enable them, add "using mpi ;" to your user-config.jam
warning: skipping optional Message Passing Interface (MPI) library.
note: to enable MPI support, add "using mpi ;" to user-config.jam.
note: to suppress this message, pass "--without-mpi" to bjam.
note: otherwise, you can safely ignore this message.
...patience...
...patience...
...patience...
...found 6637 targets...
...updating 8 targets...
darwin.compile.c++
bin.v2/libs/thread/build/darwin-4.5.0/release/threading-multi/pthread/thread.o
"g++" -ftemplate-depth-128 -O3 -finline-functions -Wno-inline -Wall
-dynamic -no-cpp-precomp -gdwarf-2 -std=c++0x -fPIC -DBOOST_ALL_NO_LIB=1
-DBOOST_THREAD_BUILD_DLL=1 -DBOOST_THREAD_POSIX -DNDEBUG -I"." -c -o
"bin.v2/libs/thread/build/darwin-4.5.0/release/threading-multi/pthread/thread.o"
"libs/thread/src/pthread/thread.cpp"
g++: unrecognized option '-no-cpp-precomp'
In file included from ./boost/thread/thread.hpp:22:0,
from libs/thread/src/pthread/thread.cpp:10:
./boost/thread/detail/thread.hpp: In function 'boost::thread&&
boost::move(boost::thread&&)':
./boost/thread/detail/thread.hpp:349:16: error: invalid initialization of
reference of type 'boost::thread&&' from expression of type 'boost::thread'
In file included from ./boost/thread/detail/thread_heap_alloc.hpp:17:0,
from ./boost/thread/detail/thread.hpp:13,
from ./boost/thread/thread.hpp:22,
from libs/thread/src/pthread/thread.cpp:10:
./boost/thread/pthread/thread_heap_alloc.hpp: In function 'T*
boost::detail::heap_new(A1&&) [with T = boost::detail::thread_data<void (*)()>,
A1 = void (*&)()]':
./boost/thread/detail/thread.hpp:130:95: instantiated from here
./boost/thread/pthread/thread_heap_alloc.hpp:24:47: error: cannot bind 'void
(*)()' lvalue to 'void (*&&)()'
./boost/thread/detail/thread.hpp:43:13: error: initializing argument 1 of
'boost::detail::thread_data<F>::thread_data(F&&) [with F = void (*)()]'
...failed darwin.compile.c++
bin.v2/libs/thread/build/darwin-4.5.0/release/threading-multi/pthread/thread.o...
...skipped <pstage/lib>libboost_thread.dylib for lack of
<pbin.v2/libs/thread/build/darwin-4.5.0/release/threading-multi>pthread/thread.o...
...skipped
<pbin.v2/libs/thread/build/darwin-4.5.0/release/threading-multi>libboost_thread.dylib
for lack of
<pbin.v2/libs/thread/build/darwin-4.5.0/release/threading-multi>pthread/thread.o...
...skipped <pstage/lib>libboost_wave.dylib for lack of
<pbin.v2/libs/thread/build/darwin-4.5.0/release/threading-multi>libboost_thread.dylib...
darwin.compile.c++
bin.v2/libs/thread/build/darwin-4.5.0/release/link-static/threading-multi/pthread/thread.o
"g++" -ftemplate-depth-128 -O3 -finline-functions -Wno-inline -Wall
-no-cpp-precomp -gdwarf-2 -std=c++0x -DBOOST_ALL_NO_LIB=1
-DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_POSIX -DNDEBUG -I"." -c -o
"bin.v2/libs/thread/build/darwin-4.5.0/release/link-static/threading-multi/pthread/thread.o"
"libs/thread/src/pthread/thread.cpp"
g++: unrecognized option '-no-cpp-precomp'
In file included from ./boost/thread/thread.hpp:22:0,
from libs/thread/src/pthread/thread.cpp:10:
./boost/thread/detail/thread.hpp: In function 'boost::thread&&
boost::move(boost::thread&&)':
./boost/thread/detail/thread.hpp:349:16: error: invalid initialization of
reference of type 'boost::thread&&' from expression of type 'boost::thread'
In file included from ./boost/thread/detail/thread_heap_alloc.hpp:17:0,
from ./boost/thread/detail/thread.hpp:13,
from ./boost/thread/thread.hpp:22,
from libs/thread/src/pthread/thread.cpp:10:
./boost/thread/pthread/thread_heap_alloc.hpp: In function 'T*
boost::detail::heap_new(A1&&) [with T = boost::detail::thread_data<void (*)()>,
A1 = void (*&)()]':
./boost/thread/detail/thread.hpp:130:95: instantiated from here
./boost/thread/pthread/thread_heap_alloc.hpp:24:47: error: cannot bind 'void
(*)()' lvalue to 'void (*&&)()'
./boost/thread/detail/thread.hpp:43:13: error: initializing argument 1 of
'boost::detail::thread_data<F>::thread_data(F&&) [with F = void (*)()]'
...failed darwin.compile.c++
bin.v2/libs/thread/build/darwin-4.5.0/release/link-static/threading-multi/pthread/thread.o...
...skipped
<pbin.v2/libs/thread/build/darwin-4.5.0/release/link-static/threading-multi>libboost_thread.a(clean)
for lack of
<pbin.v2/libs/thread/build/darwin-4.5.0/release/link-static/threading-multi>pthread/thread.o...
...skipped
<pbin.v2/libs/thread/build/darwin-4.5.0/release/link-static/threading-multi>libboost_thread.a
for lack of
<pbin.v2/libs/thread/build/darwin-4.5.0/release/link-static/threading-multi>pthread/thread.o...
...skipped <pstage/lib>libboost_thread.a for lack of
<pbin.v2/libs/thread/build/darwin-4.5.0/release/link-static/threading-multi>libboost_thread.a...
...failed updating 2 targets...
...skipped 6 targets...
bash-3.2#
--
mlrus at mac dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |mlrus at mac dot com
Summary|Compiler flags error: error:|Compiler flags error: error:
|invalid initialization of |invalid initialization of
|reference of type |reference of type
|'boost::thread&&' from |'boost::thread&&' from
|expression of type |expression of type
|'boost::thread' |'boost::thread'
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43915