Hello,
I am trying to install boost for the first time as part of rose compiler installation. Here is what I did on a Linux machine:
downloaded, extracted boost 1.47.0
./bootstrap.sh --prefix=/home/usmda/rose/
boost/install2 --with-python-version=2.7
./bjam install -sGCC=gcc-4.4 -sGXX=g++-4.4 --prefix=/home/usmda/rose/boost/install2
Default gcc version is 4.7.1 [/usr/bin/g(cc|++)] on this machine so I specify the gcc 4.4 [/usr/bin/g(cc|++)-4.4] for 2 reasons:
1) I need to use gcc 4.4 to compile rose compiler as well.
2) I read
that gcc 4.7.1 disables boost threading support so that's why I want to
use gcc 4.4 but specifying -sGCC and -sGXX didn't help as still I guess
it uses gcc-4.7.1 (as shown in log below).
Build fail for 4 targets. Here is the build message...
...
In file included from ./boost/thread/detail/platform.hpp:17:0,
from ./boost/thread/detail/config.hpp:20,
from libs/thread/src/pthread/thread.cpp:8:
./boost/config/requires_threads.hpp:29:4: error: #error "Threading support unavaliable: it has been explicitly disabled with BOOST_DISABLE_THREADS"
In file included from ./boost/thread/pthread/mutex.hpp:14:0,
from ./boost/thread/mutex.hpp:16,
from ./boost/thread/pthread/thread_data.hpp:12,
from ./boost/thread/thread.hpp:17,
from libs/thread/src/pthread/thread.cpp:10:
./boost/thread/xtime.hpp:23:5: error: expected identifier before numeric constant
./boost/thread/xtime.hpp:23:5: error: expected ‘}’ before numeric constant
./boost/thread/xtime.hpp:23:5: error: expected unqualified-id before numeric constant
./boost/thread/xtime.hpp:46:14: error: expected type-specifier before ‘system_time’
In file included from ./boost/thread/pthread/mutex.hpp:14:0,
from ./boost/thread/mutex.hpp:16,
from ./boost/thread/pthread/thread_data.hpp:12,
from ./boost/thread/thread.hpp:17,
from libs/thread/src/pthread/thread.cpp:10:
./boost/thread/xtime.hpp: In function ‘int xtime_get(xtime*, int)’:
./boost/thread/xtime.hpp:73:40: error: ‘get_system_time’ was not declared in this scope
./boost/thread/xtime.hpp:73:40: note: suggested alternative:
In file included from ./boost/thread/locks.hpp:12:0,
from ./boost/thread/pthread/mutex.hpp:12,
from ./boost/thread/mutex.hpp:16,
from ./boost/thread/pthread/thread_data.hpp:12,
from ./boost/thread/thread.hpp:17,
from libs/thread/src/pthread/thread.cpp:10:
./boost/thread/thread_time.hpp:19:24: note: ‘boost::get_system_time’
In file included from ./boost/thread/pthread/mutex.hpp:14:0,
from ./boost/thread/mutex.hpp:16,
from ./boost/thread/pthread/thread_data.hpp:12,
from ./boost/thread/thread.hpp:17,
from libs/thread/src/pthread/thread.cpp:10:
./boost/thread/xtime.hpp: At global scope:
./boost/thread/xtime.hpp:88:1: error: expected declaration before ‘}’ token
"g++" -ftemplate-depth-128 -O3 -finline-functions -Wno-inline -Wall
-pthread -Wno-long-long -DBOOST_ALL_NO_LIB=1 -DBOOST_THREAD_BUILD_LIB=1
-DBOOST_THREAD_POSIX -DNDEBUG -I"." -c -o
"bin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi/pthread/thread.o" "libs/thread/src/pthread/thread.cpp"
...failed gcc.compile.c++ bin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi/pthread/thread.o...
gcc.compile.c++ bin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi/pthread/once.o
In file included from ./boost/thread/detail/platform.hpp:17:0,
from ./boost/thread/once.hpp:12,
from libs/thread/src/pthread/once.cpp:7:
./boost/config/requires_threads.hpp:29:4: error: #error "Threading support unavaliable: it has been explicitly disabled with BOOST_DISABLE_THREADS"
"g++" -ftemplate-depth-128 -O3 -finline-functions -Wno-inline
-Wall -pthread -Wno-long-long -DBOOST_ALL_NO_LIB=1
-DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_POSIX -DNDEBUG -I"." -c -o
"bin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi/pthread/once.o" "libs/thread/src/pthread/once.cpp"
...failed gcc.compile.c++ bin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi/pthread/once.o...
...skipped <pbin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi>libboost_thread.a(clean) for lack of <pbin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi>pthread/thread.o...
...skipped <pbin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi>libboost_thread.a for lack of <pbin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi>pthread/thread.o...
...skipped <p/home/usmda/rose/boost/install2/lib>libboost_thread.a for lack of <pbin.v2/libs/thread/build/gcc-4.7.1/release/link-static/threading-multi>libboost_thread.a...
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/instantiate_cpp_exprgrammar.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/instantiate_cpp_grammar.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/instantiate_cpp_literalgrs.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/instantiate_defined_grammar.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/instantiate_predef_macros.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/instantiate_re2c_lexer.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/instantiate_re2c_lexer_str.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/token_ids.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/wave_config_constant.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/cpplexer/re2clex/aq.o
gcc.compile.c++ bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/cpplexer/re2clex/cpp_re.o
gcc.archive bin.v2/libs/wave/build/gcc-4.7.1/release/link-static/threading-multi/libboost_wave.a
common.copy /home/usmda/rose/boost/install2/lib/libboost_wave.a
...failed updating 4 targets...
...skipped 9 targets...
...updated 9270 targets...