Post has attachment
log4cplus 2.0.0 released

CMake improvements: Automate export of includes if building as Cmake sub-module. (Rodion Malinovsky)

Debian spec file improvements: Use parallel build. Fix installation path on 64bit. (Michal Marek)

CMake improvements: Use ${CMAKE_INSTALL_LIBDIR} instead of hardcoding lib. (Radek Dostál)

Experimental Windows 10 ARM support through CMAKE

https://www.sourceforge.net/p/log4cplus/news/2018/04/log4cplus-200-released/

can i use external appender from the configuration file or i have to initialize it explicitly in my code ? when i try to use it from the conf file it displays error of "cannot find appenderfactory log4cplus:<my appender>" - but i linked my appender DLL to the app

Post has shared content
I have released log4cplus 1.2.1-RC2:

- Fixed SF#334. Handle signal interrupting `sem_wait()`.

- Avoid language level thread-local variables on Cygwin to avoid compilation issue (GCC PR64697).

- Implement suggestion in SF#297 to allow filters in `AsyncAppender` configuration.

- Require CMake 2.8.12 and later due to use of `INCLUDES DESTINATION` (Patched by Enrico Jorns.)

- Fixed GitHub bug #136, again. Use `mktime()`'s ability to adjust for excess values in fields of `struct tm`.

- `SocketBuffer` now throws an exception on overflow and `SocketAppender` handles it and does not send overlong messages.

- Fixed SF#343. Avoid using C++11 `std::mutex` and other synchronization primitives in Visual Studio earlier than 2015.

https://sourceforge.net/projects/log4cplus/files/log4cplus-stable/1.2.1/

Post has shared content
I have released log4cplus 2.0.0-RC2.

- Avoid copying whole message just to prepend message length in `SocketAppender`. Instead, use OS specific "gather" socket write.

- Fixed GitHub issue #136.

- `FileAppender` classes now have `TextMode` property that can be set to `Binary` or `Text` (default) to specify underlying IO stream behavior with respect to end-of-line handling. (Patch by raphaelmarcucci).

- Fixed compilation issues when building log4cplus with Visual Studio and Clang toolchain.

- Fixed various shutdown and initialization related deadlocks and crashes. GitHub issues #251, #253.

- Fixed GitHub issue #243. Single-threaded build with Visual Studio and CMake were not single-threaded.

- Fixed GitHub issue #250. Creating WiX based installer using CPack does not work because of missing license file.

Hi All,

I am new to Log4cplus. I compiled latest Log4cplus in VS 2015 windows.
When i tried to use it in my project, i am getting this error.

'void log4cplus::Appender::setLayout(std::unique_ptr<log4cplus::Layout,std::default_delete<_Ty>>)': cannot convert argument 1 from 'std::auto_ptr<log4cplus::Layout>' to 'std::unique_ptr<log4cplus::Layout,std::default_delete<_Ty>>'
1> with
1> [
1> _Ty=log4cplus::Layout
1> ]

Can any one point me whether i need to convert to unique_ptr?

is there any smart way to configure filename dynamically which is the property of rollingfileappender in config file?

I have some trouble for bulid multiple library on ubuntu for log4cplus.2.0
how to do that ?
now my way is make directory for x32 and x64 and seperate building it
I feel this way is so stuip

Post has attachment
I have released log4cplus 2.0.0-RC1. It is the first C++11 based release.


- *IMPORTANT*: Implementation language is now C++11. OS specific implementations have been replaced by C++11 facilities wherever possible. This lowers complexity of the library and improves maintainability but it also brings limitations to when the library can be used. Specifically, the library should not be used before `main()` is entered and after `main()` is left. Even more specifically, the library should not be used during global objects construction and destruction.

- log4cplus uses Catch unit testing framework and hand unit tests.

- log4cplus supports IPv6.

- Autotools based build system is now partially generated from templates by the Autogen tool.

- Autotools based build system can build both `wchar_t` and plain `char` variants at once.

Post has shared content
I have released log4cplus 1.2.1-RC1. It is a bugs fixing release.

- Fixed GitHub bug #205. Fixed AsyncAppender shutdown crash.

- Fixed GitHub bug #195. Check if queue thread pointer is not NULL and if it is running before trying to join it.

- Fixed GitHub bug #136. Adjust weekly, daily and twice daily rollover time for DailyRollingFileAppender by time zone offset so that the rollover happens at midnight, etc., of local time instead of UTC time.

- Fixed GitHub bug #148. TTCCLayout boolean members could be left uninitialized. Initialize them.

- Fixed GitHub bug #163. Fixed Visual Studio 2015 build with CMake. Compilation fails not finding FreeAddrInfoW().

- Disabled use of __thread on iOS.

- Fixed SF#333. AsyncAppender's appenders need to be closed so that accumulated logs get flushed onto disk.

- Updated android.toolchain.cmake from OpenCV project.

Hi,

I have a really strange error using log4cplus.
My process exits with code 11. If I run it in the debugger, there is a "SIGSEGV: invalid address".
Here is the call stack:
pthread_join
log4cplus::thread::AbstractThread::join()
log4cplus::AsyncAppender::close()
log4cplus::spi::LoggerImpl::closeNestedAppenders()
log4cplus::Hierarchy::shutdown()
log4cplus::Hierarchy::~Hierarchy()

I have tried to simplify the code and here is what I have:
#include <iostream>
#include <log4cplus/logger.h>
#include <log4cplus/configurator.h>
int main()
{
log4cplus::PropertyConfigurator config("/tmp/log.txt");
config.configure();

return 0;
}

And the config file:
log4cplus.rootLogger=OFF, A1
log4cplus.logger.L1=OFF, A5
log4cplus.logger.L2=OFF, A2
log4cplus.logger.L4=OFF, A3
log4cplus.logger.L6=OFF, A4
log4cplus.logger.L7=OFF, A1

log4cplus.appender.A1=log4cplus::AsyncAppender
log4cplus.appender.A1.Appender=log4cplus::ConsoleAppender

log4cplus.appender.A2=log4cplus::AsyncAppender
log4cplus.appender.A2.Appender=log4cplus::ConsoleAppender

log4cplus.appender.A3=log4cplus::AsyncAppender
log4cplus.appender.A3.Appender=log4cplus::ConsoleAppender

log4cplus.appender.A4=log4cplus::AsyncAppender
log4cplus.appender.A4.Appender=log4cplus::ConsoleAppender

log4cplus.appender.A5=log4cplus::AsyncAppender
log4cplus.appender.A5.Appender=log4cplus::ConsoleAppender

If I change the logger name L7 to L6, I don't have an error anymore.
Actually, if I delete any configuration line, I don't have an error anymore but I noticed that the name of my logger L7 worried.

I use log4cplus 1.1.3-0.4.rc3.
Actually, I use it with centos7 and a newer version of log4cplus is not available with yum.

I have a workaround for my problem, putting an "A" before the logger name which has a problem so it's not blocking but I don't know when it will happen again because I don't understand why the name is a problem.

If this problem is fixed in a newer version, I can manualy upgrade the library.

Thanks in advance.
Wait while more posts are being loaded