log4cplus Icon

Logging Framework for C++

User Ratings

★★★★★
★★★★
★★★
★★
25
0
0
0
3
ease 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5 4 / 5
features 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5 4 / 5
design 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5 4 / 5
support 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5 4 / 5
Write a Review

User Reviews

  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    hi worked quite well for me here is a guide if you have problems How to Linux unzip the files and open now a terminal in the created folder step 1 enter in your terminal: cmake . step 2 after cmake is finished enter: make step 3 now enter: sudo make install after this log4cplus files ,which you need to Link in your IDE are installed in /usr/local/include/log4cplus and /usr/local/liblog4cplus.so now you can close your terminal and you 're finshed For the ones who using cmake here is an example CMakeLists.txt ######################CMakeLists.txt############# cmake_minimum_required(VERSION 2.8) add_compile_options(-std=c++14) #project name project( Log4CPlusExample) set( CMAKE_C_FLAGS "-Wall -g" ) file(GLOB SRCS *.cpp *.h) set(LOG4CPLUS_INCLUDE_DIR /usr/local/include/log4cplus) set(LOG4PLUS_LIBRARY /usr/local/lib/liblog4cplus.so) add_executable( Log4CPlusExample ${SRCS} ) include_directories( ${LOG4CPLUS_INCLUDE_DIR} ) target_link_libraries(Log4CPlusExample ${LOG4PLUS_LIBRARY} ) ################################################# Here is a small Hello World logger example #################MyLogger.h########################## /* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ /* * File: MyLogger.h * Author: yoymoyroy * * Created on 26. April 2017, 14:04 */ //my log header #ifndef MYLogger_H #define MYLogger_H #include <log4cplus/loggingmacros.h> //wichtig enthält alle wege wie ich einen Log Schreibe #include <log4cplus/consoleappender.h> #include <log4cplus/layout.h> #include <log4cplus/logger.h> //Consol appender static log4cplus::helpers::SharedObjectPtr<log4cplus::Appender> consoleAppender (new log4cplus::ConsoleAppender()); static std::string pattern = "%d{%m/%d/%y %H:%M:%S} - %m [%l]%n"; static std::auto_ptr<log4cplus::Layout> layout(new log4cplus::PatternLayout(pattern)); //logger static log4cplus::Logger logger = log4cplus::Logger::getInstance("Display"); #endif ############################################## ##############main.cpp###################### #include "MyLogger.h" using namespace log4cplus; using namespace log4cplus::helpers; int main() { consoleAppender->setName("ConsolAppender"); consoleAppender->setLayout(layout); logger.setLogLevel(ALL_LOG_LEVEL); logger.addAppender(consoleAppender); LOG4CPLUS_INFO(logger,"Hallo World!!"); } ######################################## thats it greedings from Germany!

    Posted 04/26/2017
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    When i use the AsyncAppender in V1.2.0, VS2010 had detected many memory leaks like this: {2713} normal block at 0x00000000039C3070, 40 bytes long. Data: <@ I > 40 8B 49 00 00 00 00 00 FF FF FF FF 00 00 00 00 {2712} normal block at 0x00000000039BE0B0, 72 bytes long. Data: < @ @ > 08 EE 86 40 01 00 00 00 10 EE 86 40 01 00 00 00 {2711} normal block at 0x00000000039C1F40, 40 bytes long. Data: < I > E0 8A 49 00 00 00 00 00 FF FF FF FF 00 00 00 00 {2710} normal block at 0x00000000039BE000, 64 bytes long. Data: <(z @ 8z @ > 28 7A 87 40 01 00 00 00 38 7A 87 40 01 00 00 00 {2709} normal block at 0x00000000039C1ED0, 8 bytes long. Data: < > E4 01 00 00 00 00 00 00 {2708} normal block at 0x00000000039BDA00, 8 bytes long. Data: < > E0 01 00 00 00 00 00 00 {2707} normal block at 0x00000000039C1E40, 40 bytes long. Data: < I > 80 8A 49 00 00 00 00 00 FF FF FF FF 00 00 00 00 {2706} normal block at 0x00000000039BF370, 16 bytes long. Data: < > 18 A2 9B 03 00 00 00 00 00 00 00 00 00 00 00 00 {2705} normal block at 0x00000000039BF2E0, 40 bytes long. Data: < I > 20 8A 49 00 00 00 00 00 FF FF FF FF 00 00 00 00 {2704} normal block at 0x00000000039BA210, 112 bytes long. Data: < @ p > B8 C4 87 40 01 00 00 00 70 F3 9B 03 00 00 00 00 {2701} normal block at 0x00000000039B9300, 8 bytes long. Data: < > 00 00 00 00 00 00 00 00 {2309} normal block at 0x00000000039C1DC0, 16 bytes long. Data: < > 80 A4 9B 03 00 00 00 00 00 00 00 00 00 00 00 00 {2308} normal block at 0x00000000039C1D30, 40 bytes long. Data: <p=E > 70 3D 45 00 00 00 00 00 FF FF FF FF 00 00 00 00 {2307} normal block at 0x00000000039C1CB0, 16 bytes long. Data: < - @ > 88 2D 87 40 01 00 00 00 01 CD CD CD CD CD CD CD {2306} normal block at 0x00000000039C0E70, 16 bytes long. Data: < > 18 A4 9B 03 00 00 00 00 00 00 00 00 00 00 00 00 {2305} normal block at 0x00000000039C0DF0, 16 bytes long. Data: < @ @ > 90 8C 87 40 01 00 00 00 40 06 9B 03 00 00 00 00 {2304} normal block at 0x00000000039BA540, 40 bytes long. Data: <P<E > 50 3C 45 00 00 00 00 00 FF FF FF FF 00 00 00 00 {2303} normal block at 0x00000000039BA400, 208 bytes long. Data: < | @ H| @ > 08 7C 87 40 01 00 00 00 48 7C 87 40 01 00 00 00

    Posted 09/14/2016
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Agree with kyberuserid..., I used this API in a project with hopes that it would simplify my task of development, but it didn't... Worked in native win32/x64 version of the application that uses it, but when called from managed code that uses the native version of application dll it throws scheduler_resource_allocation_error. So I'm going to consider looking for something else, maybe Pantheios - I'm back to square one after all that bloody hard work only to discover that I can't make a release because it fails with .NET

    Posted 02/03/2016
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Thanks for good program!

    Posted 06/22/2013
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Thanks for good program!

    Posted 06/13/2013
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    very good project, thanks!

    Posted 04/06/2013
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    I compile static lib with my project (Visual Studio 2010), but linking error! --------------------------------------------------------------------------- 1>ClCompile: 1> All outputs are up-to-date. 1>ManifestResourceCompile: 1> All outputs are up-to-date. 1>log4cplusSD.lib(factory.obj) : error LNK2019: unresolved external symbol "public: __thiscall log4cplus::SysLogAppender::SysLogAppender(class log4cplus::helpers::Properties const &)" (??0SysLogAppender@log4cplus@@QAE@ABVProperties@helpers@1@@Z) referenced in function "public: virtual class log4cplus::helpers::SharedObjectPtr<class log4cplus::Appender> __thiscall log4cplus::spi::FactoryTempl<class log4cplus::SysLogAppender,class log4cplus::spi::AppenderFactory>::createObject(class log4cplus::helpers::Properties const &)" (?createObject@?$FactoryTempl@VSysLogAppender@log4cplus@@VAppenderFactory@spi@2@@spi@log4cplus@@UAE?AV?$SharedObjectPtr@VAppender@log4cplus@@@helpers@3@ABVProperties@53@@Z) 1>D:\Projects\AutoTradeSystem\Bin\Win32\Debug\Backtest.exe : fatal error LNK1120: 1 unresolved externals 1> 1>Build FAILED.

    Posted 10/06/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Wouldn't it be better to move the project to github? Or at least provide official mirror?

    Posted 08/11/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Good. But do not remove the old solutions for previous versions Visual Studio.

    Posted 07/27/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Superb!)

    Posted 06/13/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    the best, just works

    Posted 06/08/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Great software Well-Known Myths As Opposed To The Accurate Pieces Of Information

    Posted 06/08/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Thanks again for the hard work!

    Posted 06/07/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    never noticed any problems

    Posted 06/06/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    This is an excellent tool. I have used it for a while now and I have had no issues.

    Posted 06/05/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Extremely Versatile - Available Cross-Platform

    Posted 06/04/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Exxcellent program. Thanks all developers.

    Posted 06/02/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Easy to learn and use interface

    Posted 06/02/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Excellent work.

    Posted 04/24/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Thanks for a good library! Easy to modify and nice architecture.

    Posted 04/02/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    log4cplus is a good competitor. It is for c++, I write a pure c logging library, which is quite fast and flexsible, but is not so big to a "framework". It is zlog, pls try~~ https://github.com/HardySimpson/zlog

    Posted 03/26/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Great library. I like it better (used to use log4cxx).

    Posted 03/15/2012
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Great library, thank you for this project!

    Posted 04/28/2011
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Great library! I used Pantheios before, but (being very fast and extendable, though) it hasn't "multiple loggers" feature, while it's quite a "must have" one. The 'log4cplus' lets me log different functionality domains via different loggers, which logging levels can be managed run-time. It means that when my end-user found some hard-to-track issue in my software, I can say him "please open config-file and turn on the logging port A at TRACE level, the logging port B at ERROR level, and left all other logging ports off". This is typical real-life logging use-case, and 'log4cplus' does it great.

    Posted 04/28/2011
  • 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Easy to modify. Good architecture. Thank you.

    Posted 04/20/2011
Show next 3 reviews

Thanks for helping keep SourceForge clean.

Screenshot instructions:
Windows
Mac
Red Hat Linux   Ubuntu

Click URL instructions:
Right-click on ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)

More information about our ad policies
X

Briefly describe the problem (required):

Upload screenshot of ad (required):
Select a file, or drag & drop file here.

Please provide the ad click URL, if possible:

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks