The wrap_filter helper can be used to inject user-defined filter
functions into Boost.Log filtering expressions.
Added implementation, tests, docs and examples.
Refs https://github.com/boostorg/log/issues/195.
This lets users to disable Boost.ASIO-related functionality and remove
the dependency on Boost.ASIO. This may be useful on platforms where
Boost.ASIO or its dependencies don't work or disabled.
Refs https://github.com/chriskohlhoff/asio/issues/1637.
* Make the library modular usable.
* Switch to library requirements instead of source. As source puts extra source in install targets.
* Clean up build dependencies.
* Remove external build references and avoid custom project loading.
* Use relative paths to declare config sub-projects.
* Add missing NO_LIB usage requirements.
* Add missing library ref.
* Add missing import-search for cconfig/predef checks.
* Add requires-b2 check to top-level build file.
* Update dependencies.
* Bump B2 require to 5.2
* Update copyright dates.
* Move inter-lib dependencies to a project variable and into the build targets.
* Remove custom symbolic project names for config subprojects. And use project root relative targets.
* Move private deps to the build project.
* Put back default boost locale link as locale build is now fixed.
* Set default address-model and architecture to avoid extra/custom detection logic. Put back missing check and config rules.
* Adjust doc build to avoid boost-root references.
* Fix ref to predef.jam location.
* Have B2 build use same deps as CML for per-target private/public.
* Add log dep to log_setup, as it's needed on some platforms.
* Add boost_log_with_support target to mirror CML.
* Fix platform specific winapi dependency spec.
This replaces boost::thread and most mutexes and condition variables with
std equivalents. It also adds support for std lock types to the strictest_lock
type trait.
This significantly, although not completely, reduces the dependency on
Boost.Thread.
Refs https://github.com/boostorg/log/issues/232.
C++20 removed argument type typedefs in standard function objects, which made
it impossible to deduce the attribute value type from the standard function
objects. This caused compilation errors with VS2022 in C++20 mode.
The _SCL_SECURE_NO_WARNINGS, _SCL_SECURE_NO_DEPRECATE,
_CRT_SECURE_NO_WARNINGS and _CRT_SECURE_NO_DEPRECATE macros need to be
defined for every compiler that uses MSVC C/C++ runtime, so instead of
duplicating these definitions in multiple places, define them for
Windows platform regardless of the compiler. In particular, they are
now defined for clang-cl.
Explicit specification of attribute value type is necessary when it cannot
be inferred from the function object type. With C++20 removing argument type
typedefs from standard function objects, like std::less, and compilers following
suit (e.g. future MSVC versions), it is better to update the example so that
it is compatible with future compilers.
Related to https://github.com/boostorg/log/issues/105.
The new example demostrates working with the settings container directly
and provides a more complete view on the library initialization.
Closes https://github.com/boostorg/log/issues/87.
The default filter/formatter factories will now be able to extract severity
level values of type boost::log::trivial::severity_level. For filters, this
is only supported for attributes with the "Severity" name.
Some tests pull in pthread rwlock and therefore need _XOPEN_SOURCE=600
or higher to compile. Added platform defines to tests and examples
for good measure.
For MinGW worked around Boost.Build error when BOOST_LOG_WITHOUT_EVENT_LOG
is defined.
This allows to have different file names when actively writing the log file
and when rotating. In particular, this solves the problem with appending
to the previous file, when the log files are also collected and are supposed
to have distincs names.
The example uses IPC queue operation_result as a namespace qualifier for
the values of the enum. This is allowed in C++11 and some compilers also allow
it in C++03. This is the preferred use of the enum values, so in the official
docs that kind of use is still displayed. For compatibility with C++03 though
an additional hidden code branch is added that refers to the constants without
qualification.
included into the size limit.
The max_size method on the stream buffer will now attempt to truncate
the attached string on the character boundary.
Fixed character boundary detection for multibyte encodings.
Clean up the overflow flag and the max size limit after the formatter
has completed.
Added a test for the max_size decorator.
Cleaned up some includes and reduced the dependency on Boost.Thread.