2
0
mirror of https://github.com/boostorg/log.git synced 2026-01-19 16:32:09 +00:00

47 Commits

Author SHA1 Message Date
Andrey Semashev
3efa06b889 Removed disablement of IPC utilities on Cygwin in tests and examples. 2025-12-26 17:22:43 +03:00
Andrey Semashev
ad2eb6c4e5 Added docs, examples and test for wrap_formatter. 2025-07-11 10:28:46 +03:00
Andrey Semashev
86c8cdcced Added a wrap_filter utility.
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.
2025-07-11 03:23:01 +03:00
Andrey Semashev
ecc4466bc0 Added BOOST_LOG_WITHOUT_ASIO config option.
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.
2025-06-13 17:17:31 +03:00
René Ferdinand Rivera Morell
2530a4e03a Add support for modular build structure. (#233)
* 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.
2025-05-26 00:48:16 +03:00
Andrey Semashev
26c93dc061 Replaced Boost.Thread synchronization primitives with std equivalents.
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.
2024-08-16 20:01:18 +03:00
Andrey Semashev
7ddeff52f1 Removed dependency on Boost.LexicalCast. 2023-08-25 14:48:46 +03:00
Andrey Semashev
e957369c80 Explicitly specify attribute value type for make_attr_ordering in examples.
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.
2021-10-26 00:56:17 +03:00
Andrey Semashev
de4e85e9b3 Switched to c++-template-depth feature instead of explicit compiler flags.
This allows to specify the limit for other compilers that support it
and remove it for clang-cl, which doesn't.
2020-09-08 18:23:57 +03:00
Andrey Semashev
4ef885fc7a Moved MSVC C/C++ runtime deprecated macros to a common place.
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.
2020-09-08 18:20:13 +03:00
Andrey Semashev
1ce3c06ac6 Added a compilable example for initialization from a settings container.
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.
2019-06-25 20:10:50 +03:00
Andrey Semashev
1138b47fce Removed linking with Boost.System.
Since Boost.System is now header-only, no need to link with the library.
2019-01-14 20:16:20 +03:00
Andrey Semashev
effd8568a4 Disable Boost.Interprocess on Cygwin.
Boost.Interprocess doesn't compile on Cygwin:

https://github.com/boostorg/interprocess/issues/76

Also, disable affected tests and examples.
2019-01-06 19:51:48 +03:00
Andrey Semashev
136fd2bdfd CI compilation fixes for Cygwin and MinGW.
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.
2019-01-06 14:13:32 +03:00
Andrey Semashev
947d4361d4 Added a check for message compiler on Windows when building examples.
Disable event log examples when message compiler is not available. This
should hopefully fix MinGW failures in CI.
2019-01-06 02:17:46 +03:00
Andrey Semashev
e823f88467 Added support for a separate target file name pattern in text file sink.
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.
2019-01-05 21:15:33 +03:00
Andrey Semashev
ccf5e745aa Updated IPC queue example to compile in C++03 mode with gcc.
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.
2018-01-03 19:54:34 +03:00
Andrey Semashev
6e2632c804 Silenced MSVC warning about a narrowing conversion. 2017-03-25 20:44:32 +03:00
Andrey Semashev
70debc533b Changed the max_size decorator so that the overflow marker length is
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.
2016-08-09 04:20:49 +03:00
Andrey Semashev
fc398fc04d Updated example to make sure an exception is thrown. 2016-07-17 19:41:43 +03:00
Andrey Semashev
7624cf57b9 Added docs for reliable_message_queue. 2016-07-17 15:43:34 +03:00
Andrey Semashev
3c92751c56 Working on documentation for IPC tools. 2016-06-05 22:28:54 +03:00
Andrey Semashev
61e9db5406 Renamed sinks_ipc_viewer.cpp to sinks_ipc_receiver.cpp. 2016-06-05 17:25:02 +03:00
Andrey Semashev
05826649a0 Extracted platform-specific logic regarding interprocess object names to a separate object_name wrapper. Use this wrapper wherever interprocess queue name was used. Added a test for the wrapper. Extracted auto_handle to a separate header. 2016-04-14 19:32:04 +03:00
Andrey Semashev
1852ded16f Updated IPC examples to be compatible with the actual implementation. 2016-04-14 19:32:04 +03:00
Andrey Semashev
89d56bc12a Compilation fixes on Windows. 2016-04-14 19:32:03 +03:00
Lingxi-Li
8d9002cab8 Add text_ipc_message_queue_backend
This new sink backend supports logging messages to an interprocess
message queue.
2016-04-14 19:32:02 +03:00
Andrey Semashev
5de58e8a61 Added documentation and comments. 2016-02-25 22:07:29 +03:00
Erich Keane
2b9cf67a4a Add max_files parameter to the examples that use make_file_collector 2015-12-29 11:16:51 -08:00
Andrey Semashev
7cbcf861e5 Improved docs. 2015-04-04 16:01:16 +03:00
Andrey Semashev
18df30ed33 Followup for the previous commit. 2015-03-25 00:48:52 +03:00
Andrey Semashev
71b12228f1 Disabled warning C4003 on MSVC 8 (VS2005). The warning was caused by Boost.PP macros used in Boost.Fusion and as reported by Boost.PP maintainer cannot be worked around locally in the macro definition. 2015-03-10 02:09:31 +03:00
Andrey Semashev
5bb604ee39 Updated copyright dates. 2015-01-25 17:32:33 +03:00
Andrey Semashev
9e4c006c03 XML character decorator now escapes quote characters. 2014-09-09 21:44:56 +04:00
Andrey Semashev
d706f38e5b Disabled yet another useless warning of Intel Compiler. 2014-07-07 23:02:52 +04:00
Andrey Semashev
d90b457110 Added support for MSVC 14 CTP. 2014-07-05 20:19:40 +04:00
Andrey Semashev
40d5720f9e Disabled more of Intel warnings. 2014-06-23 15:35:45 +04:00
Andrey Semashev
166616c796 Changed all references to empty_deleter to null_deleter in Boost.Core. 2014-06-03 23:09:21 +04:00
Andrey Semashev
a21d096e4a Updated copyright notes to 2014. 2014-01-19 18:46:09 +04:00
Andrey Semashev
4399331206 Merged recent changes from trunk
[SVN r86659]
2013-11-12 19:46:37 +00:00
Andrey Semashev
4c69b429ce Merged recent changes from trunk.
[SVN r86405]
2013-10-23 15:53:47 +00:00
Andrey Semashev
313a5b69cd Merged recent changes from trunk.
[SVN r85657]
2013-09-12 17:17:07 +00:00
Andrey Semashev
5204873fa9 Merged latest changes from trunk.
[SVN r85461]
2013-08-25 14:20:22 +00:00
Andrey Semashev
b9a24cd46c Fixes #8585. Fixed typos in docs and comments.
[SVN r84352]
2013-05-18 14:21:26 +00:00
Andrey Semashev
ab97ab66d9 Added a check for availability of Message Compiler (mc) on Windows. This should simplify building the library on MinGW, Cygwin and MSVC Express and fix MinGW tests.
[SVN r84186]
2013-05-07 23:03:54 +00:00
Andrey Semashev
de668a3cf8 Fixing linking the tests against the library.
[SVN r83943]
2013-04-17 19:37:57 +00:00
Andrey Semashev
a7c4e0e319 Boost.Log merged to trunk.
[SVN r83860]
2013-04-13 12:30:25 +00:00