Search code examples
c++linuxlog4cxx

how to use log4cxx under the Red Hat 7


I am trying to use log4cxx in my c++ project under the system Red Hat 7.

So I download it with this command: yum install log4cxx.x86_64

After that, I type this command: rpm -ql log4cxx and get this message:

  • /usr/lib64/liblog4cxx.so.10
  • /usr/lib64/liblog4cxx.so.10.0.0
  • /usr/share/doc/log4cxx-0.10.0
  • /usr/share/doc/log4cxx-0.10.0/KEYS
  • /usr/share/doc/log4cxx-0.10.0/LICENSE
  • /usr/share/doc/log4cxx-0.10.0/NOTICE

Now I dont know how to use the log4cxx in my project. Where is the head files? Where is the lib files?

thanks in advance.


Solution

  • Try with:

    yum search log4cxx
    

    you will get:

    ....
    log4cxx.i686 : A port to C++ of the Log4j project
    log4cxx.x86_64 : A port to C++ of the Log4j project
    log4cxx-devel.i686 : Header files for Log4xcc - a port to C++ of the Log4j project
    log4cxx-devel.x86_64 : Header files for Log4xcc - a port to C++ of the Log4j project
    

    Just do yum install log4cxx-devel too