Boost logo

Boost Users :

Subject: Re: [Boost-users] Query on Boost.Log
From: Leo Carreon (lcarreon_at_[hidden])
Date: 2013-07-13 01:11:58


From: Colin Powers
Sent: Saturday, July 13, 2013 1:49 AM
To: boost-users_at_[hidden]
Subject: Re: [Boost-users] Query on Boost.Log

_____________________________________________
From: Leo Carreon [mailto:lcarreon_at_[hidden]]
Sent: 12 July 2013 01:31
To: Boost Users Mailing List
Subject: Re: [Boost-users] Query on Boost.Log

From: Leo Carreon
Sent: Friday, July 12, 2013 8:42 AM
To: Boost Users Mailing List
Subject: Query on Boost.Log

Hi everyone,

I’m trying to learn how to use Boost.Log from Boost 1.54.0 on Fedora 18.

When I attempt to call boost::log::init_from_stream() even with BOOST_LOG_DYN_LINK defined, I get the error message”undefined reference to `void boost::log::v2_mt_posix::init_from_stream<char>(std::basic_istream<char, std::char_traits<char> >&)'” for the line where I called the function. Note that I have included the header file “boost/log/utility/setup/from_stream.hpp” and added –lboost_log to my link command line.

Am I missing something. I have noticed that boost::log::init_from_stream() is a template. Is an instance of this template added into the shared library?

Kind regards,
Leo

Hi again everyone,

FYI.

I built Boost 1.54.0 using the following bjam options – link=shared runtime-link=shared

I have also checked the build logs from the above and discovered that not all of the .cpp files in libs/log/src have been included during the build.

Kind regards,
Leo

Just a guess from having used quite a lot of Boost Log v1 before it was fully integrated into boost. I believe there is a separate library boost_log_setup - have you tried linking against that?

-Colin

Thanks for the reply. I did not realize that there is a separate boost_log_setup library.

--------------------------------------------------------------------------------
_______________________________________________
Boost-users mailing list
Boost-users_at_[hidden]
http://lists.boost.org/mailman/listinfo.cgi/boost-users



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net