Boost Users :
Subject: [Boost-users] Boost Log: I can't see syslog messages sent via boost syslog.
From: Anatoly G (anatolyrishon_at_[hidden])
Date: 2016-04-11 00:15:52
I have a question about Boost syslog.
I"m beginner Boost user.
I created attached code and can't understand why it doesn't work.
I execute my code on linux Kubuntu 3.13.0
After execution I"m looking for test strings in syslog file:
grep "Test" /var/log/syslog
But I don't see any line.
I tried to execute commands from shell
logger "Test from shell"
logger -n 127.0.0.1 -t myapp -p user.notice "Test from shell"
I see these lines after executing grep on /var/log/syslog
I tried to initialize syslog_backend with
boost::log::keywords::use_impl = boost::log::sinks::syslog::native
boost::log::keywords::use_impl = boost::log::sinks::syslog::udp_socket_based
but then I get compile message, native not defined.
I found BOOST_LOG_USE_NATIVE_SYSLOG macro which should be defined during
Boost build, but I don't understand how to activate this macro in boost
Can you please suggest what is the problem?
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