Steve Ong | 1 Oct 01:35
Picon
Favicon

asio - failed to compile "chat_client.cpp" example on Cygwin

Hi,

I downloaded the "chat_client.cpp" from the boost website (http://www.boost.org/doc/libs/1_37_0/doc/html/boost_asio/examples.html) and try to compile it on Cygwin (see my compile statement below..), but it failed. It's worked on Linux (without the -D__USE_W32_SOCKETS -D_WIN32_WINNT=0x0501) , however.

Thanks in advance for your help.

Compile statement:

g++ -o chat_client chat_client.cpp -D__USE_W32_SOCKETS -D_WIN32_WINNT=0x0501 -Wall -I/opt/boost/include -L/opt/boost/lib -lboost_thread -lboost_system -lboost_t
hread


Output message:

/usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../../i686-pc-cygwin/bin/ld: warning: au
to-importing has been activated without --enable-auto-import specified on the co
mmand line.
This should work unless it involves constant data structures referencing symbols
 from auto-imported DLLs./cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:ch
at_client.cpp:(.text$_ZN5boost4asio6detail12winsock_initILi2ELi0EE7do_initC1Ev[b
oost::asio::detail::winsock_init<2, 0>::do_init::do_init()]+0x1f): undefined ref
erence to `_WSAStartup <at> 8'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops5closeEjRNS_6system10error_codeE[boost::asio::detai
l::socket_ops::close(unsigned int, boost::system::error_code&)]+0x18): undefined
 reference to `_closesocket <at> 4'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops13error_wrapperIiEET_S4_RNS_6system10error_codeE[in
t boost::asio::detail::socket_ops::error_wrapper<int>(int, boost::system::error_
code&)]+0x13): undefined reference to `_WSAGetLastError <at> 0'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops11clear_errorERNS_6system10error_codeE[boost::asio:
:detail::socket_ops::clear_error(boost::system::error_code&)]+0xf): undefined re
ference to `_WSASetLastError <at> 4'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops6socketEiiiRNS_6system10error_codeE[boost::asio::de
tail::socket_ops::socket(int, int, int, boost::system::error_code&)]+0x3e): unde
fined reference to `_WSASocketA <at> 24'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops6socketEiiiRNS_6system10error_codeE[boost::asio::de
tail::socket_ops::socket(int, int, int, boost::system::error_code&)]+0x9a): unde
fined reference to `_setsockopt <at> 20'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops13error_wrapperIjEET_S4_RNS_6system10error_codeE[un
signed int boost::asio::detail::socket_ops::error_wrapper<unsigned int>(unsigned
 int, boost::system::error_code&)]+0x13): undefined reference to `_WSAGetLastErr
or <at> 0'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops12call_connectIiEEiMNS2_6msghdrET_jPK8sockaddrj[int
 boost::asio::detail::socket_ops::call_connect<int>(int boost::asio::detail::soc
ket_ops::msghdr::*, unsigned int, sockaddr const*, unsigned int)]+0x1b): undefin
ed reference to `_connect <at> 12'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops5ioctlEjlPmRNS_6system10error_codeE[boost::asio::de
tail::socket_ops::ioctl(unsigned int, long, unsigned long*, boost::system::error
_code&)]+0x26): undefined reference to `_ioctlsocket <at> 12'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops11getaddrinfoEPKcS4_PK8addrinfoPPS5_RNS_6system10er
ror_codeE[boost::asio::detail::socket_ops::getaddrinfo(char const*, char const*,
 addrinfo const*, addrinfo**, boost::system::error_code&)]+0x2e): undefined refe
rence to `_getaddrinfo <at> 16'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops24translate_addrinfo_errorEi[boost::asio::detail::s
ocket_ops::translate_addrinfo_error(int)]+0x228): undefined reference to `_WSAGe
tLastError <at> 0'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops4sendEjPK7_WSABUFjiRNS_6system10error_codeE[boost::
asio::detail::socket_ops::send(unsigned int, _WSABUF const*, unsigned int, int,
boost::system::error_code&)]+0x57): undefined reference to `_WSASend <at> 28'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops12freeaddrinfoEP8addrinfo[boost::asio::detail::sock
et_ops::freeaddrinfo(addrinfo*)]+0xd): undefined reference to `_freeaddrinfo <at> 4'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops15call_setsockoptIiEEiMNS2_6msghdrET_jiiPKvj[int bo
ost::asio::detail::socket_ops::call_setsockopt<int>(int boost::asio::detail::soc
ket_ops::msghdr::*, unsigned int, int, int, void const*, unsigned int)]+0x29): u
ndefined reference to `_setsockopt <at> 20'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail23win_iocp_socket_serviceINS0_2ip3tcpEE13async_receiveINS1_17co
nsuming_buffersINS0_14mutable_bufferENS0_17mutable_buffers_1EEENS1_12read_handle
rINS0_19basic_stream_socketIS4_NS0_21stream_socket_serviceIS4_EEEES9_NS1_14trans
fer_all_tENS_3_bi6bind_tIvNS_4_mfi3mf1Iv11chat_clientRKNS_6system10error_codeEEE
NSH_5list2INSH_5valueIPSL_EEPFNS_3argILi1EEEvEEEEEEEEEvRNS5_19implementation_typ
eERKT_iT0_[void boost::asio::detail::win_iocp_socket_service<boost::asio::ip::tc
p>::async_receive<boost::asio::detail::consuming_buffers<boost::asio::mutable_bu
ffer, boost::asio::mutable_buffers_1>, boost::asio::detail::read_handler<boost::
asio::basic_stream_socket<boost::asio::ip::tcp, boost::asio::stream_socket_servi
ce<boost::asio::ip::tcp> >, boost::asio::mutable_buffers_1, boost::asio::detail:
:transfer_all_t, boost::_bi::bind_t<void, boost::_mfi::mf1<void, chat_client, bo
ost::system::error_code const&>, boost::_bi::list2<boost::_bi::value<chat_client
*>, boost::arg<1> (*)()> > > >(boost::asio::detail::win_iocp_socket_service<boos
t::asio::ip::tcp>::implementation_type&, boost::asio::detail::consuming_buffers<
boost::asio::mutable_buffer, boost::asio::mutable_buffers_1> const&, int, boost:
:asio::detail::read_handler<boost::asio::basic_stream_socket<boost::asio::ip::tc
p, boost::asio::stream_socket_service<boost::asio::ip::tcp> >, boost::asio::muta
ble_buffers_1, boost::asio::detail::transfer_all_t, boost::_bi::bind_t<void, boo
st::_mfi::mf1<void, chat_client, boost::system::error_code const&>, boost::_bi::
list2<boost::_bi::value<chat_client*>, boost::arg<1> (*)()> > >)]+0x41a): undefi
ned reference to `_WSARecv <at> 28'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail23win_iocp_socket_serviceINS0_2ip3tcpEE13async_receiveINS1_17co
nsuming_buffersINS0_14mutable_bufferENS0_17mutable_buffers_1EEENS1_12read_handle
rINS0_19basic_stream_socketIS4_NS0_21stream_socket_serviceIS4_EEEES9_NS1_14trans
fer_all_tENS_3_bi6bind_tIvNS_4_mfi3mf1Iv11chat_clientRKNS_6system10error_codeEEE
NSH_5list2INSH_5valueIPSL_EEPFNS_3argILi1EEEvEEEEEEEEEvRNS5_19implementation_typ
eERKT_iT0_[void boost::asio::detail::win_iocp_socket_service<boost::asio::ip::tc
p>::async_receive<boost::asio::detail::consuming_buffers<boost::asio::mutable_bu
ffer, boost::asio::mutable_buffers_1>, boost::asio::detail::read_handler<boost::
asio::basic_stream_socket<boost::asio::ip::tcp, boost::asio::stream_socket_servi
ce<boost::asio::ip::tcp> >, boost::asio::mutable_buffers_1, boost::asio::detail:
:transfer_all_t, boost::_bi::bind_t<void, boost::_mfi::mf1<void, chat_client, bo
ost::system::error_code const&>, boost::_bi::list2<boost::_bi::value<chat_client
*>, boost::arg<1> (*)()> > > >(boost::asio::detail::win_iocp_socket_service<boos
t::asio::ip::tcp>::implementation_type&, boost::asio::detail::consuming_buffers<
boost::asio::mutable_buffer, boost::asio::mutable_buffers_1> const&, int, boost:
:asio::detail::read_handler<boost::asio::basic_stream_socket<boost::asio::ip::tc
p, boost::asio::stream_socket_service<boost::asio::ip::tcp> >, boost::asio::muta
ble_buffers_1, boost::asio::detail::transfer_all_t, boost::_bi::bind_t<void, boo
st::_mfi::mf1<void, chat_client, boost::system::error_code const&>, boost::_bi::
list2<boost::_bi::value<chat_client*>, boost::arg<1> (*)()> > >)]+0x428): undefi
ned reference to `_WSAGetLastError <at> 0'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail23win_iocp_socket_serviceINS0_2ip3tcpEE10async_sendINS1_17consu
ming_buffersINS0_12const_bufferENS0_17mutable_buffers_1EEENS1_13write_handlerINS
0_19basic_stream_socketIS4_NS0_21stream_socket_serviceIS4_EEEES9_NS1_14transfer_
all_tENS_3_bi6bind_tIvNS_4_mfi3mf1Iv11chat_clientRKNS_6system10error_codeEEENSH_
5list2INSH_5valueIPSL_EEPFNS_3argILi1EEEvEEEEEEEEEvRNS5_19implementation_typeERK
T_iT0_[void boost::asio::detail::win_iocp_socket_service<boost::asio::ip::tcp>::
async_send<boost::asio::detail::consuming_buffers<boost::asio::const_buffer, boo
st::asio::mutable_buffers_1>, boost::asio::detail::write_handler<boost::asio::ba
sic_stream_socket<boost::asio::ip::tcp, boost::asio::stream_socket_service<boost
::asio::ip::tcp> >, boost::asio::mutable_buffers_1, boost::asio::detail::transfe
r_all_t, boost::_bi::bind_t<void, boost::_mfi::mf1<void, chat_client, boost::sys
tem::error_code const&>, boost::_bi::list2<boost::_bi::value<chat_client*>, boos
t::arg<1> (*)()> > > >(boost::asio::detail::win_iocp_socket_service<boost::asio:
:ip::tcp>::implementation_type&, boost::asio::detail::consuming_buffers<boost::a
sio::const_buffer, boost::asio::mutable_buffers_1> const&, int, boost::asio::det
ail::write_handler<boost::asio::basic_stream_socket<boost::asio::ip::tcp, boost:
:asio::stream_socket_service<boost::asio::ip::tcp> >, boost::asio::mutable_buffe
rs_1, boost::asio::detail::transfer_all_t, boost::_bi::bind_t<void, boost::_mfi:
:mf1<void, chat_client, boost::system::error_code const&>, boost::_bi::list2<boo
st::_bi::value<chat_client*>, boost::arg<1> (*)()> > >)]+0x3f4): undefined refer
ence to `_WSASend <at> 28'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail23win_iocp_socket_serviceINS0_2ip3tcpEE10async_sendINS1_17consu
ming_buffersINS0_12const_bufferENS0_17mutable_buffers_1EEENS1_13write_handlerINS
0_19basic_stream_socketIS4_NS0_21stream_socket_serviceIS4_EEEES9_NS1_14transfer_
all_tENS_3_bi6bind_tIvNS_4_mfi3mf1Iv11chat_clientRKNS_6system10error_codeEEENSH_
5list2INSH_5valueIPSL_EEPFNS_3argILi1EEEvEEEEEEEEEvRNS5_19implementation_typeERK
T_iT0_[void boost::asio::detail::win_iocp_socket_service<boost::asio::ip::tcp>::
async_send<boost::asio::detail::consuming_buffers<boost::asio::const_buffer, boo
st::asio::mutable_buffers_1>, boost::asio::detail::write_handler<boost::asio::ba
sic_stream_socket<boost::asio::ip::tcp, boost::asio::stream_socket_service<boost
::asio::ip::tcp> >, boost::asio::mutable_buffers_1, boost::asio::detail::transfe
r_all_t, boost::_bi::bind_t<void, boost::_mfi::mf1<void, chat_client, boost::sys
tem::error_code const&>, boost::_bi::list2<boost::_bi::value<chat_client*>, boos
t::arg<1> (*)()> > > >(boost::asio::detail::win_iocp_socket_service<boost::asio:
:ip::tcp>::implementation_type&, boost::asio::detail::consuming_buffers<boost::a
sio::const_buffer, boost::asio::mutable_buffers_1> const&, int, boost::asio::det
ail::write_handler<boost::asio::basic_stream_socket<boost::asio::ip::tcp, boost:
:asio::stream_socket_service<boost::asio::ip::tcp> >, boost::asio::mutable_buffe
rs_1, boost::asio::detail::transfer_all_t, boost::_bi::bind_t<void, boost::_mfi:
:mf1<void, chat_client, boost::system::error_code const&>, boost::_bi::list2<boo
st::_bi::value<chat_client*>, boost::arg<1> (*)()> > >)]+0x402): undefined refer
ence to `_WSAGetLastError <at> 0'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail12winsock_initILi2ELi0EE7do_initD1Ev[boost::asio::detail::winso
ck_init<2, 0>::do_init::~do_init()]+0x7): undefined reference to `_WSACleanup <at> 0'

/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail25socket_select_interrupterC1Ev[boost::asio::detail::socket_sel
ect_interrupter::socket_select_interrupter()]+0x17f): undefined reference to `_i
net_addr <at> 4'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops11call_acceptIiEEjMNS2_6msghdrET_jP8sockaddrPj[unsi
gned int boost::asio::detail::socket_ops::call_accept<int>(int boost::asio::deta
il::socket_ops::msghdr::*, unsigned int, sockaddr*, unsigned int*)]+0x4d): undef
ined reference to `_accept <at> 12'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops6listenEjiRNS_6system10error_codeE[boost::asio::det
ail::socket_ops::listen(unsigned int, int, boost::system::error_code&)]+0x1f): u
ndefined reference to `_listen <at> 8'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops16call_getsocknameIiEEiMNS2_6msghdrET_jP8sockaddrPj
[int boost::asio::detail::socket_ops::call_getsockname<int>(int boost::asio::det
ail::socket_ops::msghdr::*, unsigned int, sockaddr*, unsigned int*)]+0x23): unde
fined reference to `_getsockname <at> 12'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops9call_bindIiEEiMNS2_6msghdrET_jPK8sockaddrj[int boo
st::asio::detail::socket_ops::call_bind<int>(int boost::asio::detail::socket_ops
::msghdr::*, unsigned int, sockaddr const*, unsigned int)]+0x1b): undefined refe
rence to `_bind <at> 12'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops4recvEjP7_WSABUFjiRNS_6system10error_codeE[boost::a
sio::detail::socket_ops::recv(unsigned int, _WSABUF*, unsigned int, int, boost::
system::error_code&)]+0x57): undefined reference to `_WSARecv <at> 28'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZNK
5boost4asio6detail18win_fd_set_adapter6is_setEj[boost::asio::detail::win_fd_set_
adapter::is_set(unsigned int) const]+0x14): undefined reference to `___WSAFDIsSe
t <at> 8'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops6selectEiP6fd_setS4_S4_P7timevalRNS_6system10error_
codeE[boost::asio::detail::socket_ops::select(int, fd_set*, fd_set*, fd_set*, ti
meval*, boost::system::error_code&)]+0xe4): undefined reference to `_select <at> 20'
/cygdrive/c/DOCUME~1/steven/LOCALS~1/Temp/ccKpZSDF.o:chat_client.cpp:(.text$_ZN5
boost4asio6detail10socket_ops15call_getsockoptIiEEiMNS2_6msghdrET_jiiPvPj[int bo
ost::asio::detail::socket_ops::call_getsockopt<int>(int boost::asio::detail::soc
ket_ops::msghdr::*, unsigned int, int, int, void*, unsigned int*)]+0x31): undefi
ned reference to `_getsockopt <at> 20'
Info: resolving vtable for boost::detail::thread_data_baseby linking to __imp___
ZTVN5boost6detail16thread_data_baseE (auto-import)
collect2: ld returned 1 exit status
make: *** [chat_client] Error 1








_______________________________________________
Boost-users mailing list
Boost-users <at> lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users
manish4gupta | 1 Oct 02:50
Favicon

Re: How to install boost 1_39 on itanium server


I have used the command  
g++ -I usr/local/include/boost_1_39 programe_name.cpp
 still getting the same error.

Vladimir Prus-3 wrote:
> 
> manish4gupta wrote:
> 
>> 
>> I ran in this way also.
>> 
>> g++ -I /usr/include/boost_1_39 programe_name.cpp
> 
> If you have installed boost to /usr/local, as your prior
> email say, then 
> 
>         /usr/include/boost_1_39
> 
> is clearly a wrong path. Can you please provide the *exact*
> command you have used. You should copy-paste the command
> directly from terminal.
> 
> Thanks,
> Volodya
> 
> 
> _______________________________________________
> Boost-users mailing list
> Boost-users <at> lists.boost.org
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
> 
> 

--

-- 
View this message in context: http://www.nabble.com/How-to-install-boost-1_39-on-itanium-server-tp25680594p25691631.html
Sent from the Boost - Users mailing list archive at Nabble.com.
Marshall Clow | 1 Oct 03:51
Picon

Re: How to install boost 1_39 on itanium server

On Sep 30, 2009, at 5:50 PM, manish4gupta wrote:
> Vladimir Prus-3 wrote:
>>
>> manish4gupta wrote:
>>
>>>
>>> I ran in this way also.
>>>
>>> g++ -I /usr/include/boost_1_39 programe_name.cpp
>>
>> If you have installed boost to /usr/local, as your prior
>> email say, then
>>
>>        /usr/include/boost_1_39
>>
>> is clearly a wrong path. Can you please provide the *exact*
>> command you have used. You should copy-paste the command
>> directly from terminal.

>
> I have used the command
> g++ -I usr/local/include/boost_1_39 programe_name.cpp
> still getting the same error.
>

"usr/local/include/boost_1_39" is not the same as "/usr/include/ 
boost_1_39".

At the very least, you need a leading '/' in the path.

-- Marshall
Caleb Cushing | 1 Oct 03:04
Picon
Gravatar

problems with program_opsitons::parse_environment can't figure out how to do what I want.

    variables_map vm_env;
    store(parse_environment(desc, "HOME"), vm_env);
    notify(vm_env);

    if(vm_env.count("HOME")) {
        path rcfile = ".koramarc";
        path home;
        home = vm_env["HOME"].as<path>();
        path tmp = home / rcfile;
        cout << "check" << endl; // just a retarted test to see if
we're actually reaching the end of this...
    }

--

-- 
Caleb Cushing

http://xenoterracide.blogspot.com
Caleb Cushing | 1 Oct 03:07
Picon
Gravatar

Re: problems with program_opsitons::parse_environment can't figure out how to do what I want.

On Wed, Sep 30, 2009 at 9:04 PM, Caleb Cushing <xenoterracide <at> gmail.com> wrote:
>    variables_map vm_env;
>    store(parse_environment(desc, "HOME"), vm_env);
>    notify(vm_env);
>
>    if(vm_env.count("HOME")) {
>        path rcfile = ".koramarc";
>        path home;
>        home = vm_env["HOME"].as<path>();
>        path tmp = home / rcfile;
>        cout << "check" << endl; // just a retarted test to see if
> we're actually reaching the end of this...
>    }

whoops... my code never enters the if statement and I'm not sure why.

I'm still working on the best way to get the HOME variable from the
env so I can more correctly reference ~/.koramarc. I need however to
combine HOME with the actual rcfile name. and then I need to pass it
to parse_config_file... but everything I've tried I just keep getting
stumped... any help would really be appreciated, I've been trying
various things for 3-ish days now.

--

-- 
Caleb Cushing

http://xenoterracide.blogspot.com
_______________________________________________
Boost-users mailing list
Boost-users <at> lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users
manish4gupta | 1 Oct 04:01
Favicon

Re: How to install boost 1_39 on itanium server


I tried this way also

 g++ -I /usr/local/include/boost_1_39 programe_name.cpp 
and   g++ -I /usr/local/include/boost_1_39 programe_name.cpp  -lrt
 but still error is same. 

Marshall Clow-2 wrote:
> 
> On Sep 30, 2009, at 5:50 PM, manish4gupta wrote:
>> Vladimir Prus-3 wrote:
>>>
>>> manish4gupta wrote:
>>>
>>>>
>>>> I ran in this way also.
>>>>
>>>> g++ -I /usr/include/boost_1_39 programe_name.cpp
>>>
>>> If you have installed boost to /usr/local, as your prior
>>> email say, then
>>>
>>>        /usr/include/boost_1_39
>>>
>>> is clearly a wrong path. Can you please provide the *exact*
>>> command you have used. You should copy-paste the command
>>> directly from terminal.
> 
>>
>> I have used the command
>> g++ -I usr/local/include/boost_1_39 programe_name.cpp
>> still getting the same error.
>>
> 
> "usr/local/include/boost_1_39" is not the same as "/usr/include/ 
> boost_1_39".
> 
> At the very least, you need a leading '/' in the path.
> 
> -- Marshall
> 
> _______________________________________________
> Boost-users mailing list
> Boost-users <at> lists.boost.org
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
> 
> 

--

-- 
View this message in context: http://www.nabble.com/How-to-install-boost-1_39-on-itanium-server-tp25680594p25692085.html
Sent from the Boost - Users mailing list archive at Nabble.com.
manish4gupta | 1 Oct 04:55
Favicon

Re: How to install boost 1_39 on itanium server


As i said 
I am installing the boost on itanium (64 bit red hat) machine. I am
following
the three steps.
./bootstrap.sh --prefix=/usr/local
./bjam
./bjam install

boost gets installed in /usr/local/include . should I give any other options
like ia64 while building since it 64 bit machine.Also do i need to specify
the libdir and include dir option ? If yes what could be the option. Please
help. 
Thanks in advance. 

do i need to specify where to install 

manish4gupta wrote:
> 
> I tried this way also
> 
>  g++ -I /usr/local/include/boost_1_39 programe_name.cpp 
> and   g++ -I /usr/local/include/boost_1_39 programe_name.cpp  -lrt
>  but still error is same. 
> 
> 
> 
> Marshall Clow-2 wrote:
>> 
>> On Sep 30, 2009, at 5:50 PM, manish4gupta wrote:
>>> Vladimir Prus-3 wrote:
>>>>
>>>> manish4gupta wrote:
>>>>
>>>>>
>>>>> I ran in this way also.
>>>>>
>>>>> g++ -I /usr/include/boost_1_39 programe_name.cpp
>>>>
>>>> If you have installed boost to /usr/local, as your prior
>>>> email say, then
>>>>
>>>>        /usr/include/boost_1_39
>>>>
>>>> is clearly a wrong path. Can you please provide the *exact*
>>>> command you have used. You should copy-paste the command
>>>> directly from terminal.
>> 
>>>
>>> I have used the command
>>> g++ -I usr/local/include/boost_1_39 programe_name.cpp
>>> still getting the same error.
>>>
>> 
>> "usr/local/include/boost_1_39" is not the same as "/usr/include/ 
>> boost_1_39".
>> 
>> At the very least, you need a leading '/' in the path.
>> 
>> -- Marshall
>> 
>> _______________________________________________
>> Boost-users mailing list
>> Boost-users <at> lists.boost.org
>> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>> 
>> 
> 
> 

--

-- 
View this message in context: http://www.nabble.com/How-to-install-boost-1_39-on-itanium-server-tp25680594p25692427.html
Sent from the Boost - Users mailing list archive at Nabble.com.
Sergey Nikulov | 1 Oct 05:41
Picon

Re: How to install boost 1_39 on itanium server

Manish,

According you first description gcc can not find include files.
Solution for this, just provide compiler with exact path using -I options.

Could you please provide exact compiler error and exact path to managed_shared_memory.hpp file?


2009/10/1 manish4gupta <manish <at> synamatix.com>

As i said
I am installing the boost on itanium (64 bit red hat) machine. I am
following
the three steps.
./bootstrap.sh --prefix=/usr/local
./bjam
./bjam install

boost gets installed in /usr/local/include . should I give any other options
like ia64 while building since it 64 bit machine.Also do i need to specify
the libdir and include dir option ? If yes what could be the option. Please
help.
Thanks in advance.





do i need to specify where to install

manish4gupta wrote:
>
> I tried this way also
>
>  g++ -I /usr/local/include/boost_1_39 programe_name.cpp
> and   g++ -I /usr/local/include/boost_1_39 programe_name.cpp  -lrt
>  but still error is same.
>
>
>
> Marshall Clow-2 wrote:
>>
>> On Sep 30, 2009, at 5:50 PM, manish4gupta wrote:
>>> Vladimir Prus-3 wrote:
>>>>
>>>> manish4gupta wrote:
>>>>
>>>>>
>>>>> I ran in this way also.
>>>>>
>>>>> g++ -I /usr/include/boost_1_39 programe_name.cpp
>>>>
>>>> If you have installed boost to /usr/local, as your prior
>>>> email say, then
>>>>
>>>>        /usr/include/boost_1_39
>>>>
>>>> is clearly a wrong path. Can you please provide the *exact*
>>>> command you have used. You should copy-paste the command
>>>> directly from terminal.
>>
>>>
>>> I have used the command
>>> g++ -I usr/local/include/boost_1_39 programe_name.cpp
>>> still getting the same error.
>>>
>>
>> "usr/local/include/boost_1_39" is not the same as "/usr/include/
>> boost_1_39".
>>
>> At the very least, you need a leading '/' in the path.
>>
>> -- Marshall
>>
>> _______________________________________________
>> Boost-users mailing list
>> Boost-users <at> lists.boost.org
>> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>>
>>
>
>

--
View this message in context: http://www.nabble.com/How-to-install-boost-1_39-on-itanium-server-tp25680594p25692427.html
Sent from the Boost - Users mailing list archive at Nabble.com.

_______________________________________________
Boost-users mailing list
Boost-users <at> lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users



--
Best Regards,
Sergey Nikulov
_______________________________________________
Boost-users mailing list
Boost-users <at> lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users
manish4gupta | 1 Oct 06:11
Favicon

Re: How to install boost 1_39 on itanium server


Hi,

path to managed_shared_memory.hpp
/usr/local/include/boost-1_39/boost/interprocess/managed_shared_memory.hpp

My program name is boostindex.cpp 
I am running the following command 
 g++ -I /usr/local/include/boost-1_39 boostindex.cpp -lrt
and gettting the following error

In file included from
/usr/local/include/boost-1_39/boost/interprocess/sync/interprocess_mutex.hpp:47,
                 from
/usr/local/include/boost-1_39/boost/interprocess/mem_algo/rbtree_best_fit.hpp:27,
                 from
/usr/local/include/boost-1_39/boost/interprocess/detail/managed_memory_impl.hpp:22,
                 from
/usr/local/include/boost-1_39/boost/interprocess/managed_shared_memory.hpp:21,
                 from boostindex.cpp:1:
/usr/local/include/boost-1_39/boost/interprocess/detail/atomic.hpp:466:2:
#error No atomic operations implemented for this platform, sorry!
/usr/local/include/boost-1_39/boost/interprocess/detail/atomic.hpp:45:
warning: inline function `uint32_t
boost::interprocess::detail::atomic_cas32(volatile uint32_t*, uint32_t,
uint32_t)' used but never defined
/usr/local/include/boost-1_39/boost/interprocess/detail/atomic.hpp:36:
warning: inline function `void
boost::interprocess::detail::atomic_write32(volatile uint32_t*, uint32_t)'
used but never defined
/usr/local/include/boost-1_39/boost/interprocess/detail/atomic.hpp:31:
warning: inline function `uint32_t
boost::interprocess::detail::atomic_read32(volatile uint32_t*)' used but
never defined

Now this error is different from what earlier i was getting since i ran one
more command for checking installation.
g++ -E -I/usr/local/include//boost-1_39 boostindex.cpp >/dev/null from the
following link
http://ubuntuforums.org/showthread.php?t=1180792

Please help. Thanks in advance. 

Sergey Nikulov wrote:
> 
> Manish,
> 
> According you first description gcc can not find include files.
> Solution for this, just provide compiler with exact path using -I options.
> 
> Could you please provide exact compiler error and exact path to
> managed_shared_memory.hpp file?
> 
> 
> 2009/10/1 manish4gupta <manish <at> synamatix.com>
> 
>>
>> As i said
>> I am installing the boost on itanium (64 bit red hat) machine. I am
>> following
>> the three steps.
>> ./bootstrap.sh --prefix=/usr/local
>> ./bjam
>> ./bjam install
>>
>> boost gets installed in /usr/local/include . should I give any other
>> options
>> like ia64 while building since it 64 bit machine.Also do i need to
>> specify
>> the libdir and include dir option ? If yes what could be the option.
>> Please
>> help.
>> Thanks in advance.
>>
>>
>>
>>
>>
>> do i need to specify where to install
>>
>> manish4gupta wrote:
>> >
>> > I tried this way also
>> >
>> >  g++ -I /usr/local/include/boost_1_39 programe_name.cpp
>> > and   g++ -I /usr/local/include/boost_1_39 programe_name.cpp  -lrt
>> >  but still error is same.
>> >
>> >
>> >
>> > Marshall Clow-2 wrote:
>> >>
>> >> On Sep 30, 2009, at 5:50 PM, manish4gupta wrote:
>> >>> Vladimir Prus-3 wrote:
>> >>>>
>> >>>> manish4gupta wrote:
>> >>>>
>> >>>>>
>> >>>>> I ran in this way also.
>> >>>>>
>> >>>>> g++ -I /usr/include/boost_1_39 programe_name.cpp
>> >>>>
>> >>>> If you have installed boost to /usr/local, as your prior
>> >>>> email say, then
>> >>>>
>> >>>>        /usr/include/boost_1_39
>> >>>>
>> >>>> is clearly a wrong path. Can you please provide the *exact*
>> >>>> command you have used. You should copy-paste the command
>> >>>> directly from terminal.
>> >>
>> >>>
>> >>> I have used the command
>> >>> g++ -I usr/local/include/boost_1_39 programe_name.cpp
>> >>> still getting the same error.
>> >>>
>> >>
>> >> "usr/local/include/boost_1_39" is not the same as "/usr/include/
>> >> boost_1_39".
>> >>
>> >> At the very least, you need a leading '/' in the path.
>> >>
>> >> -- Marshall
>> >>
>> >> _______________________________________________
>> >> Boost-users mailing list
>> >> Boost-users <at> lists.boost.org
>> >> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>> >>
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/How-to-install-boost-1_39-on-itanium-server-tp25680594p25692427.html
>> Sent from the Boost - Users mailing list archive at Nabble.com.
>>
>> _______________________________________________
>> Boost-users mailing list
>> Boost-users <at> lists.boost.org
>> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>>
> 
> 
> 
> -- 
> Best Regards,
> Sergey Nikulov
> 
> _______________________________________________
> Boost-users mailing list
> Boost-users <at> lists.boost.org
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
> 

--

-- 
View this message in context: http://www.nabble.com/How-to-install-boost-1_39-on-itanium-server-tp25680594p25692842.html
Sent from the Boost - Users mailing list archive at Nabble.com.
Picon

spurious string

Hello all,

I'm reading an html file and parsing data from it. I've encountered a spurious string (researcher’s). Notepad++ shows that string as  researcher's .

I'm reading the file using std::fstream class. Is there any way i can read the string and get the spurious characters replaced using boost string/regex algorithms ?

Thanks,
Surya

_______________________________________________
Boost-users mailing list
Boost-users <at> lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users

Gmane