With gcc 3.2.3 on SunOS 5.8 and R 1.7.0, configure fails for me unless I set LDFLAGS ( LDFLAGS=-L/apps/asd/unix/gnu/gcc/3.2.3/SunOS5.8/lib ). With that set it appears that configure succeeds (i.e. no error messages on the console), but config.log contains messages configure:4099: checking for gcc option to accept ANSI C configure:4160: gcc -c -g -O2 -I/usr/local/include conftest.c >&5 In file included from configure:4124: /usr/include/sys/stat.h:258: syntax error before "blksize_t" /usr/include/sys/stat.h:262: syntax error before '}' token /usr/include/sys/stat.h:318: syntax error before "blksize_t" /usr/include/sys/stat.h:319: conflicting types for `st_blocks' /usr/include/sys/stat.h:259: previous declaration of `st_blocks' /usr/include/sys/stat.h:322: syntax error before '}' token configure:4163: $? = 1 configure: failed program was: | #line 4106 "configure" | /* confdefs.h. */ | | #define PACKAGE_NAME "R" | #define PACKAGE_TARNAME "R" | #define PACKAGE_VERSION "1.7.0" | #define PACKAGE_STRING "R 1.7.0" Make then fails with gcc -I. -I../../src/include -I../../src/include -I/usr/openwin/include -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -c sys-unix.c -o sys-unix.o In file included from sys-unix.c:31: /usr/include/sys/stat.h:258: syntax error before "blksize_t" /usr/include/sys/stat.h:262: syntax error before '}' token /usr/include/sys/stat.h:318: syntax error before "blksize_t" /usr/include/sys/stat.h:319: conflicting types for `st_blocks' /usr/include/sys/stat.h:259: previous declaration of `st_blocks' /usr/include/sys/stat.h:322: syntax error before '}' token make[3]: *** [sys-unix.o] Error 1 make[3]: Leaving directory `/home/com1/gilp/toolchain/R/R-1.7.0/src/unix' make[2]: *** [R] Error 2 Any suggestions would be greatly appreciated. Paul Gilbert
On Fri, 9 May 2003, Paul Gilbert wrote:> With gcc 3.2.3 on SunOS 5.8 and R 1.7.0, configure fails for me unless I > set LDFLAGS ( LDFLAGS=-L/apps/asd/unix/gnu/gcc/3.2.3/SunOS5.8/lib ).It works here with gcc installed in /usr/local/lib.> With that set it appears that configure succeeds (i.e. no error messages > on the console), but config.log contains messages > > configure:4099: checking for gcc option to accept ANSI C > configure:4160: gcc -c -g -O2 -I/usr/local/include conftest.c >&5 > In file included from configure:4124: > /usr/include/sys/stat.h:258: syntax error before "blksize_t" > /usr/include/sys/stat.h:262: syntax error before '}' token > /usr/include/sys/stat.h:318: syntax error before "blksize_t" > /usr/include/sys/stat.h:319: conflicting types for `st_blocks' > /usr/include/sys/stat.h:259: previous declaration of `st_blocks' > /usr/include/sys/stat.h:322: syntax error before '}' token > configure:4163: $? = 1 > configure: failed program was: > | #line 4106 "configure" > | /* confdefs.h. */ > | > | #define PACKAGE_NAME "R" > | #define PACKAGE_TARNAME "R" > | #define PACKAGE_VERSION "1.7.0" > | #define PACKAGE_STRING "R 1.7.0"No such entries here. Those errors are in the stat structure, following a section #if !defined(_XOPEN_SOURCE) && !defined(_POSIX_C_SOURCE) || \ defined(__EXTENSIONS__) Do you have any of those defined? -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595