Roberto Huelga
Sat, 10 Jan 2009 09:05:14 -0800
I'm trying to test the log4cxx library following the information in this wiki page: http://wiki.apache.org/logging-log4cxx/MSWindowsBuildInstructions when I run make in the apr folder, I'm getting this is the errors: /bin/sh /home/kanzeon/src/apr/trunk/libtool --silent --mode=compile gcc -O0 -s -mms-bitfields -march=i686 -DHAVE_CONFIG_H -D_LARGEFILE64_SOURCE -I/usr/local/include -I./include -I/home/kanzeon/src/apr/trunk/include/arch/win32 -I./include/arch/unix -I/home/kanzeon/src/apr/trunk/include/arch/unix -I/home/kanzeon/src/apr/trunk/include -o dso/win32/dso.lo -c dso/win32/dso.c && touch dso/win32/dso.lo In file included from C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_file_io.h:29, from dso/win32/dso.c:20: C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:421: error: syntax error before "LPPROCESSENTRY32W" C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:421: error: syntax error before "LPPROCESSENTRY32W" C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h: In function `apr_winapi_Process32FirstW': C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:421: error: `hSnapshot' undeclared (first use in this function) C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:421: error: (Each undeclared identifier is reported only once C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:421: error: for each function it appears in.) C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:421: error: `lppe' undeclared (first use in this function) C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h: At top level: C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:430: error: syntax error before "LPPROCESSENTRY32W" C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:430: error: syntax error before "LPPROCESSENTRY32W" C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h: In function `apr_winapi_Process32NextW': C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:430: error: `hSnapshot' undeclared (first use in this function) C:/msys/1.0/home/kanzeon/src/apr/trunk/include/arch/win32/apr_arch_misc.h:430: error: `lppe' undeclared (first use in this function) make[1]: *** [dso/win32/dso.lo] Error 1 make[1]: Leaving directory `/home/kanzeon/src/apr/trunk' make: *** [all-recursive] Error 1 I solved the problems using the WINVER def and inserting the tlhelp32.h include in the file include/arch/win32/apr_arch_misc.h I'm using the following configure line: $ ./configure CFLAGS="-O0 -s -mms-bitfields -march=i686 -DWINVER=0x0501" CXXFLAGS="-O0 -s -mms-bitfields -march=i686 -DWINVER=0x0501" using this configuration everything get compiled without error (only get some warnings) and the make test only fail 4 of the 5 test of dso Failed Tests Total Fail Failed % =================================================== testdso 5 4 80.00% I hope this info will be useful to someone. -- http://marssong.blogspot.com