Uploaded image for project: 'Log4cxx'
  1. Log4cxx
  2. LOGCXX-489

log4cxx-0.10.0 - socketoutputstream.cpp:52: error: 'memcpy' was not declared in this scope

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 0.10.0
    • 0.11.0
    • Core
    • None
    • CentOS 6, CentOS 7, Debian 9

    Description

      Attempting to build log4cxx 0.10.0 from source fails on make with the following error on CentOS 6, CentOS 7, Debian 9:

      ```
      g++ -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"log4cxx\" -DVERSION=\"0.10.0\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DHAVE_MBSRTOWCS=1 -DHAVE_WCSTOMBS=1 -DHAVE_SYSLOG=1 -DHAVE_FWIDE=1 -I. -I. -I../../../src/main/include -I../../../src/main/include -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -O2 -MT socketoutputstream.lo -MD -MP -MF .deps/socketoutputstream.Tpo -c socketoutputstream.cpp -fPIC -DPIC -o .libs/socketoutputstream.o
      socketoutputstream.cpp: In member function 'virtual void log4cxx::helpers::SocketOutputStream::write(log4cxx::helpers::ByteBuffer&, log4cxx::helpers::Pool&)':
      socketoutputstream.cpp:52: error: 'memcpy' was not declared in this scope
      ```

      Adding "#include <string.h>" to the top of src/main/cpp/inputstreamreader.cpp fixes the problem.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              sheath Simon Heath
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: