I am getting the following errors. I have the full stack of the commands I have run....
Any pointers will help me resolve the problem faster...
groan:/usr2/ajitc->uname -a
SunOS groan 5.8 Generic_108528-07 sun4u sparc SUNW,Ultra-1
groan:/usr2/ajitc/pkg/log4cpp-0.2.6->./configure
checking for a BSD compatible install... config/install-sh -c
checking whether build environment is sane... yes
checking whether make sets ${MAKE}... yes
checking for working aclocal... missing
checking for working autoconf... missing
checking for working automake... missing
checking for working autoheader... missing
checking for working makeinfo... missing
checking build system type... sparc-sun-solaris2.8
checking host system type... sparc-sun-solaris2.8
checking for gcc... gcc
checking for C compiler default output... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for executable suffix...
checking for object suffix... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for ld used by GCC... /usr/ccs/bin/ld
checking if the linker (/usr/ccs/bin/ld) is GNU ld... no
checking for /usr/ccs/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/ccs/bin/nm -p
checking whether ln -s works... yes
checking how to recognise dependant libraries... pass_all
checking command to parse /usr/ccs/bin/nm -p output... ok
checking how to run the C preprocessor... gcc -E
checking for dlfcn.h... yes
checking for ranlib... ranlib
checking for strip... strip
checking for objdir... .libs
checking for gcc option to produce PIC... -fPIC
checking if gcc PIC flag -fPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.lo... no
checking if gcc supports -fno-rtti -fno-exceptions... yes
checking whether the linker (/usr/ccs/bin/ld) supports shared libraries... yes
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... no
checking dynamic linker characteristics... solaris2.8 ld.so
checking if libtool supports shared libraries... yes
creating libtool
checking for a BSD compatible install... config/install-sh -c
checking whether make sets ${MAKE}... (cached) yes
checking for g++... no
checking for c++... no
checking for gpp... no
checking for aCC... no
checking for CC... CC
checking whether we are using the GNU C++ compiler... no
checking whether CC accepts -g... yes
checking how to run the C++ preprocessor... CC -E
CC: Warning: Option --version passed to ld, if ld is invoked, ignored otherwise
checking for unistd.h... yes
checking for io.h... no
checking whether the compiler implements namespaces... no
checking whether the compiler has stringstream... no
checking for working snprintf... no
checking for syslog... no
checking for socket in -lsocket... no
checking for gethostbyname in -lnsl... no
checking for doxygen... no
creating log4cpp-config - generic 0.2.6 of log4cpp
configure: creating ./config.status
config.status: creating Makefile
config.status: creating log4cpp.spec
config.status: creating config/Makefile
config.status: creating doc/Makefile
config.status: creating doc/Doxyfile
config.status: creating src/Makefile
config.status: creating include/Makefile
config.status: creating include/log4cpp/Makefile
config.status: creating tests/Makefile
config.status: creating debian/Makefile
config.status: creating msvc6/Makefile
config.status: creating msvc6/log4cpp/Makefile
config.status: creating msvc6/testCategory/Makefile
config.status: creating msvc6/testNDC/Makefile
config.status: creating bcb5/Makefile
config.status: creating bcb5/log4cpp/Makefile
config.status: creating bcb5/testCategory/Makefile
config.status: creating bcb5/testFixedContextCategory/Makefile
config.status: creating bcb5/testmain/Makefile
config.status: creating bcb5/testNDC/Makefile
config.status: creating include/config.h
config.status: include/config.h is unchanged
creating include/log4cpp/config.h - prefix LOG4CPP for include/config.h defines
/
groan:/usr2/ajitc/pkg/log4cpp-0.2.6->make install
Making install in debian
Making install in msvc6
Making install in log4cpp
Making install in testCategory
Making install in testNDC
Making install in bcb5
Making install in log4cpp
Making install in testCategory
Making install in testFixedContextCategory
Making install in testmain
Making install in testNDC
Making install in config
Making install in src
/bin/sh ../libtool --mode=compile CC -DHAVE_CONFIG_H -I. -I. -I../include -I../include -g -Wall -pedantic -c Appender.cpp
rm -f .libs/Appender.lo
CC -DHAVE_CONFIG_H -I. -I. -I../include -I../include -g -Wall -pedantic -c Appender.cpp -fPIC -DPIC -o Appender.o
CC: Warning: Option -Wall passed to ld, if ld is invoked, ignored otherwise
CC: Warning: Option -pedantic passed to ld, if ld is invoked, ignored otherwise
CC: Warning: Option -fPIC passed to ld, if ld is invoked, ignored otherwise
"../include/log4cpp/Appender.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/Appender.hh", line 14: Error: Could not open include file <map>.
"../include/log4cpp/OstringStream.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/OstringStream.hh", line 21: Error: Could not open include file <strstream>.
"../include/log4cpp/OstringStream.hh", line 24: Error: Type name expected instead of "namespace".
"../include/log4cpp/OstringStream.hh", line 48: Error: Unexpected "}".
"../include/log4cpp/OstringStream.hh", line 50: Error: Unexpected "}".
"../include/log4cpp/Priority.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/Priority.hh", line 54: Error: Type name expected instead of "namespace".
"../include/log4cpp/Priority.hh", line 68: Error: Type name expected instead of "FATAL".
"../include/log4cpp/Priority.hh", line 92: Error: std is not defined.
"../include/log4cpp/Priority.hh", line 92: Error: string must be initialized.
"../include/log4cpp/Priority.hh", line 92: Error: "," expected instead of "&".
"../include/log4cpp/Priority.hh", line 93: Error: Unexpected "}".
"../include/log4cpp/Priority.hh", line 94: Error: Unexpected "}".
"../include/log4cpp/Layout.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/LoggingEvent.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/LoggingEvent.hh", line 21: Error: Type name expected instead of "namespace".
"../include/log4cpp/LoggingEvent.hh", line 49: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 49: Error: categoryName must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 52: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 52: Error: message must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 55: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 55: Error: ndc must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 58: Error: Priority is not defined.
Compilation aborted, too many messages.
*** Error code 1
make: Fatal error: Command failed for target `Appender.lo'
Current working directory /usr2/ajitc/pkg/log4cpp-0.2.6/src
*** Error code 1
make: Fatal error: Command failed for target `install-recursive'
groan:/usr2/ajitc/pkg/log4cpp-0.2.6->make
Making all in debian
Making all in msvc6
Making all in log4cpp
Making all in testCategory
Making all in testNDC
Making all in bcb5
Making all in log4cpp
Making all in testCategory
Making all in testFixedContextCategory
Making all in testmain
Making all in testNDC
Making all in config
Making all in src
/bin/sh ../libtool --mode=compile CC -DHAVE_CONFIG_H -I. -I. -I../include -I../include -g -Wall -pedantic -c Appender.cpp
rm -f .libs/Appender.lo
CC -DHAVE_CONFIG_H -I. -I. -I../include -I../include -g -Wall -pedantic -c Appender.cpp -fPIC -DPIC -o Appender.o
CC: Warning: Option -Wall passed to ld, if ld is invoked, ignored otherwise
CC: Warning: Option -pedantic passed to ld, if ld is invoked, ignored otherwise
CC: Warning: Option -fPIC passed to ld, if ld is invoked, ignored otherwise
"../include/log4cpp/Appender.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/Appender.hh", line 14: Error: Could not open include file <map>.
"../include/log4cpp/OstringStream.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/OstringStream.hh", line 21: Error: Could not open include file <strstream>.
"../include/log4cpp/OstringStream.hh", line 24: Error: Type name expected instead of "namespace".
"../include/log4cpp/OstringStream.hh", line 48: Error: Unexpected "}".
"../include/log4cpp/OstringStream.hh", line 50: Error: Unexpected "}".
"../include/log4cpp/Priority.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/Priority.hh", line 54: Error: Type name expected instead of "namespace".
"../include/log4cpp/Priority.hh", line 68: Error: Type name expected instead of "FATAL".
"../include/log4cpp/Priority.hh", line 92: Error: std is not defined.
"../include/log4cpp/Priority.hh", line 92: Error: string must be initialized.
"../include/log4cpp/Priority.hh", line 92: Error: "," expected instead of "&".
"../include/log4cpp/Priority.hh", line 93: Error: Unexpected "}".
"../include/log4cpp/Priority.hh", line 94: Error: Unexpected "}".
"../include/log4cpp/Layout.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/LoggingEvent.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/LoggingEvent.hh", line 21: Error: Type name expected instead of "namespace".
"../include/log4cpp/LoggingEvent.hh", line 49: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 49: Error: categoryName must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 52: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 52: Error: message must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 55: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 55: Error: ndc must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 58: Error: Priority is not defined.
Compilation aborted, too many messages.
*** Error code 1
make: Fatal error: Command failed for target `Appender.lo'
Current working directory /usr2/ajitc/pkg/log4cpp-0.2.6/src
*** Error code 1
make: Fatal error: Command failed for target `all-recursive'
groan:/usr2/ajitc/pkg/log4cpp-0.2.6->
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
You seem to have serious problems with you C++ compiler: it cannot find the C++ standard header <string> and does not understand namespaces.
Maybe with the correct command line switches it will compile, but most likely you'll need to upgrade to a newer version or switch to the GNU C++. The latter is what I use for development.
Bastiaan
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am getting the following errors. I have the full stack of the commands I have run....
Any pointers will help me resolve the problem faster...
groan:/usr2/ajitc->uname -a
SunOS groan 5.8 Generic_108528-07 sun4u sparc SUNW,Ultra-1
groan:/usr2/ajitc/pkg/log4cpp-0.2.6->./configure
checking for a BSD compatible install... config/install-sh -c
checking whether build environment is sane... yes
checking whether make sets ${MAKE}... yes
checking for working aclocal... missing
checking for working autoconf... missing
checking for working automake... missing
checking for working autoheader... missing
checking for working makeinfo... missing
checking build system type... sparc-sun-solaris2.8
checking host system type... sparc-sun-solaris2.8
checking for gcc... gcc
checking for C compiler default output... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for executable suffix...
checking for object suffix... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for ld used by GCC... /usr/ccs/bin/ld
checking if the linker (/usr/ccs/bin/ld) is GNU ld... no
checking for /usr/ccs/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/ccs/bin/nm -p
checking whether ln -s works... yes
checking how to recognise dependant libraries... pass_all
checking command to parse /usr/ccs/bin/nm -p output... ok
checking how to run the C preprocessor... gcc -E
checking for dlfcn.h... yes
checking for ranlib... ranlib
checking for strip... strip
checking for objdir... .libs
checking for gcc option to produce PIC... -fPIC
checking if gcc PIC flag -fPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.lo... no
checking if gcc supports -fno-rtti -fno-exceptions... yes
checking whether the linker (/usr/ccs/bin/ld) supports shared libraries... yes
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... no
checking dynamic linker characteristics... solaris2.8 ld.so
checking if libtool supports shared libraries... yes
creating libtool
checking for a BSD compatible install... config/install-sh -c
checking whether make sets ${MAKE}... (cached) yes
checking for g++... no
checking for c++... no
checking for gpp... no
checking for aCC... no
checking for CC... CC
checking whether we are using the GNU C++ compiler... no
checking whether CC accepts -g... yes
checking how to run the C++ preprocessor... CC -E
CC: Warning: Option --version passed to ld, if ld is invoked, ignored otherwise
checking for unistd.h... yes
checking for io.h... no
checking whether the compiler implements namespaces... no
checking whether the compiler has stringstream... no
checking for working snprintf... no
checking for syslog... no
checking for socket in -lsocket... no
checking for gethostbyname in -lnsl... no
checking for doxygen... no
creating log4cpp-config - generic 0.2.6 of log4cpp
configure: creating ./config.status
config.status: creating Makefile
config.status: creating log4cpp.spec
config.status: creating config/Makefile
config.status: creating doc/Makefile
config.status: creating doc/Doxyfile
config.status: creating src/Makefile
config.status: creating include/Makefile
config.status: creating include/log4cpp/Makefile
config.status: creating tests/Makefile
config.status: creating debian/Makefile
config.status: creating msvc6/Makefile
config.status: creating msvc6/log4cpp/Makefile
config.status: creating msvc6/testCategory/Makefile
config.status: creating msvc6/testNDC/Makefile
config.status: creating bcb5/Makefile
config.status: creating bcb5/log4cpp/Makefile
config.status: creating bcb5/testCategory/Makefile
config.status: creating bcb5/testFixedContextCategory/Makefile
config.status: creating bcb5/testmain/Makefile
config.status: creating bcb5/testNDC/Makefile
config.status: creating include/config.h
config.status: include/config.h is unchanged
creating include/log4cpp/config.h - prefix LOG4CPP for include/config.h defines
/
groan:/usr2/ajitc/pkg/log4cpp-0.2.6->make install
Making install in debian
Making install in msvc6
Making install in log4cpp
Making install in testCategory
Making install in testNDC
Making install in bcb5
Making install in log4cpp
Making install in testCategory
Making install in testFixedContextCategory
Making install in testmain
Making install in testNDC
Making install in config
Making install in src
/bin/sh ../libtool --mode=compile CC -DHAVE_CONFIG_H -I. -I. -I../include -I../include -g -Wall -pedantic -c Appender.cpp
rm -f .libs/Appender.lo
CC -DHAVE_CONFIG_H -I. -I. -I../include -I../include -g -Wall -pedantic -c Appender.cpp -fPIC -DPIC -o Appender.o
CC: Warning: Option -Wall passed to ld, if ld is invoked, ignored otherwise
CC: Warning: Option -pedantic passed to ld, if ld is invoked, ignored otherwise
CC: Warning: Option -fPIC passed to ld, if ld is invoked, ignored otherwise
"../include/log4cpp/Appender.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/Appender.hh", line 14: Error: Could not open include file <map>.
"../include/log4cpp/OstringStream.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/OstringStream.hh", line 21: Error: Could not open include file <strstream>.
"../include/log4cpp/OstringStream.hh", line 24: Error: Type name expected instead of "namespace".
"../include/log4cpp/OstringStream.hh", line 48: Error: Unexpected "}".
"../include/log4cpp/OstringStream.hh", line 50: Error: Unexpected "}".
"../include/log4cpp/Priority.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/Priority.hh", line 54: Error: Type name expected instead of "namespace".
"../include/log4cpp/Priority.hh", line 68: Error: Type name expected instead of "FATAL".
"../include/log4cpp/Priority.hh", line 92: Error: std is not defined.
"../include/log4cpp/Priority.hh", line 92: Error: string must be initialized.
"../include/log4cpp/Priority.hh", line 92: Error: "," expected instead of "&".
"../include/log4cpp/Priority.hh", line 93: Error: Unexpected "}".
"../include/log4cpp/Priority.hh", line 94: Error: Unexpected "}".
"../include/log4cpp/Layout.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/LoggingEvent.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/LoggingEvent.hh", line 21: Error: Type name expected instead of "namespace".
"../include/log4cpp/LoggingEvent.hh", line 49: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 49: Error: categoryName must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 52: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 52: Error: message must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 55: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 55: Error: ndc must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 58: Error: Priority is not defined.
Compilation aborted, too many messages.
*** Error code 1
make: Fatal error: Command failed for target `Appender.lo'
Current working directory /usr2/ajitc/pkg/log4cpp-0.2.6/src
*** Error code 1
make: Fatal error: Command failed for target `install-recursive'
groan:/usr2/ajitc/pkg/log4cpp-0.2.6->make
Making all in debian
Making all in msvc6
Making all in log4cpp
Making all in testCategory
Making all in testNDC
Making all in bcb5
Making all in log4cpp
Making all in testCategory
Making all in testFixedContextCategory
Making all in testmain
Making all in testNDC
Making all in config
Making all in src
/bin/sh ../libtool --mode=compile CC -DHAVE_CONFIG_H -I. -I. -I../include -I../include -g -Wall -pedantic -c Appender.cpp
rm -f .libs/Appender.lo
CC -DHAVE_CONFIG_H -I. -I. -I../include -I../include -g -Wall -pedantic -c Appender.cpp -fPIC -DPIC -o Appender.o
CC: Warning: Option -Wall passed to ld, if ld is invoked, ignored otherwise
CC: Warning: Option -pedantic passed to ld, if ld is invoked, ignored otherwise
CC: Warning: Option -fPIC passed to ld, if ld is invoked, ignored otherwise
"../include/log4cpp/Appender.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/Appender.hh", line 14: Error: Could not open include file <map>.
"../include/log4cpp/OstringStream.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/OstringStream.hh", line 21: Error: Could not open include file <strstream>.
"../include/log4cpp/OstringStream.hh", line 24: Error: Type name expected instead of "namespace".
"../include/log4cpp/OstringStream.hh", line 48: Error: Unexpected "}".
"../include/log4cpp/OstringStream.hh", line 50: Error: Unexpected "}".
"../include/log4cpp/Priority.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/Priority.hh", line 54: Error: Type name expected instead of "namespace".
"../include/log4cpp/Priority.hh", line 68: Error: Type name expected instead of "FATAL".
"../include/log4cpp/Priority.hh", line 92: Error: std is not defined.
"../include/log4cpp/Priority.hh", line 92: Error: string must be initialized.
"../include/log4cpp/Priority.hh", line 92: Error: "," expected instead of "&".
"../include/log4cpp/Priority.hh", line 93: Error: Unexpected "}".
"../include/log4cpp/Priority.hh", line 94: Error: Unexpected "}".
"../include/log4cpp/Layout.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/LoggingEvent.hh", line 13: Error: Could not open include file <string>.
"../include/log4cpp/LoggingEvent.hh", line 21: Error: Type name expected instead of "namespace".
"../include/log4cpp/LoggingEvent.hh", line 49: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 49: Error: categoryName must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 52: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 52: Error: message must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 55: Error: std is not defined.
"../include/log4cpp/LoggingEvent.hh", line 55: Error: ndc must be initialized.
"../include/log4cpp/LoggingEvent.hh", line 58: Error: Priority is not defined.
Compilation aborted, too many messages.
*** Error code 1
make: Fatal error: Command failed for target `Appender.lo'
Current working directory /usr2/ajitc/pkg/log4cpp-0.2.6/src
*** Error code 1
make: Fatal error: Command failed for target `all-recursive'
groan:/usr2/ajitc/pkg/log4cpp-0.2.6->
Hi,
You seem to have serious problems with you C++ compiler: it cannot find the C++ standard header <string> and does not understand namespaces.
Maybe with the correct command line switches it will compile, but most likely you'll need to upgrade to a newer version or switch to the GNU C++. The latter is what I use for development.
Bastiaan