Re: [R] make error R-5.1 on sun solaris
Thanks. I am working (making some progress) on two installations (different sun's). I am working to get the system admins to install the right libraries and compilers to get the job done. Cheers, Dan =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Daniel A. Powers, Ph.D. Department of Sociology University of Texas at Austin 1 University Station A1700 Austin, TX 78712-0118 phone: 512-232-6335 fax: 512-471-1748 [EMAIL PROTECTED] -Original Message- From: Prof Brian Ripley [mailto:[EMAIL PROTECTED] Sent: Thursday, July 12, 2007 12:00 AM To: Peter Dalgaard Cc: [EMAIL PROTECTED]; 'R-Help' Subject: Re: [R] make error R-5.1 on sun solaris You are asked for a C99 compiler and configure normally finds one: mixing declarations and code is valid C99. Unless something has been done with environment variables (e.g. in config.site) this gcc is very old. configure should come up with 'gcc -std=gnu99'. Re-ordering the code will help (but it may need to go below the next #ifdef block too), but a gcc update would be a very good idea as gcc on Sparc has been buggy up to about 3.4.x. Note too that --without-iconv is undesirable and should not be necessary as libiconv can be installed as a preload on Solaris (8 and 10, so presumably also 9). On Thu, 12 Jul 2007, Peter Dalgaard wrote: Dan Powers wrote: I hope this is enough information to determine the problem. Thanks in advance for any help. Configure goes ok (I think) ./configure --prefix=$HOME --without-iconv R is now configured for sparc-sun-solaris2.9 Source directory: . Installation directory:/home/dpowers C compiler:gcc -g -O2 Fortran 77 compiler: f95 -g C++ compiler: g++ -g -O2 Fortran 90/95 compiler:f95 -g Obj-C compiler: -g -O2 Interfaces supported: X11 External libraries:readline Additional capabilities: NLS Options enabled: shared BLAS, R profiling, Java Recommended packages: yes Make ends after the gcc.. make . . . gcc -I. -I../../src/include -I../../src/include -I/usr/openwin/include -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -c system.c -o system.o system.c: In function `Rf_initialize_R': system.c:144: parse error before `char' system.c:216: `localedir' undeclared (first use in this function) system.c:216: (Each undeclared identifier is reported only once system.c:216: for each function it appears in.) *** Error code 1 make: Fatal error: Command failed for target `system.o' Current working directory /home/dpowers/R-2.5.1/src/unix *** Error code 1 make: Fatal error: Command failed for target `R' Current working directory /home/dpowers/R-2.5.1/src/unix *** Error code 1 make: Fatal error: Command failed for target `R' Current working directory /home/dpowers/R-2.5.1/src *** Error code 1 make: Fatal error: Command failed for target `R' I have tried setting localedir directly in configure options, but get the same error. Any ideas? Hmm, which version of gcc is this? The problem seems to be around line 144 which reads 140 Rstart Rp = rstart; 141 cmdlines[0] = '\0'; 142 143 #ifdef ENABLE_NLS 144 char localedir[PATH_MAX+20]; 145 #endif 146 147 #if defined(HAVE_SYS_RESOURCE_H) defined(HAVE_GETRLIMIT) 148 { 149 struct rlimit rlim; I seem to remember that it used to be non-kosher to mix declarations and ordinary code like that, but the current compiler doesn't seem to care (I do have #define ENABLE_NLS 1 in Rconfig.h, as I assume you do too). Could you perhaps try moving line 141 down below #endif? Thanks, Dan =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Daniel A. Powers, Ph.D. Department of Sociology University of Texas at Austin 1 University Station A1700 Austin, TX 78712-0118 phone: 512-232-6335 fax: 512-471-1748 [EMAIL PROTECTED] __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. -- Brian D. Ripley, [EMAIL PROTECTED] 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, UKFax: +44 1865 272595 __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented
Re: [R] make error R-5.1 on sun solaris
Dan Powers wrote: I hope this is enough information to determine the problem. Thanks in advance for any help. Configure goes ok (I think) ./configure --prefix=$HOME --without-iconv R is now configured for sparc-sun-solaris2.9 Source directory: . Installation directory:/home/dpowers C compiler:gcc -g -O2 Fortran 77 compiler: f95 -g C++ compiler: g++ -g -O2 Fortran 90/95 compiler:f95 -g Obj-C compiler: -g -O2 Interfaces supported: X11 External libraries:readline Additional capabilities: NLS Options enabled: shared BLAS, R profiling, Java Recommended packages: yes Make ends after the gcc.. make . . . gcc -I. -I../../src/include -I../../src/include -I/usr/openwin/include -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -c system.c -o system.o system.c: In function `Rf_initialize_R': system.c:144: parse error before `char' system.c:216: `localedir' undeclared (first use in this function) system.c:216: (Each undeclared identifier is reported only once system.c:216: for each function it appears in.) *** Error code 1 make: Fatal error: Command failed for target `system.o' Current working directory /home/dpowers/R-2.5.1/src/unix *** Error code 1 make: Fatal error: Command failed for target `R' Current working directory /home/dpowers/R-2.5.1/src/unix *** Error code 1 make: Fatal error: Command failed for target `R' Current working directory /home/dpowers/R-2.5.1/src *** Error code 1 make: Fatal error: Command failed for target `R' I have tried setting localedir directly in configure options, but get the same error. Any ideas? Hmm, which version of gcc is this? The problem seems to be around line 144 which reads 140 Rstart Rp = rstart; 141 cmdlines[0] = '\0'; 142 143 #ifdef ENABLE_NLS 144 char localedir[PATH_MAX+20]; 145 #endif 146 147 #if defined(HAVE_SYS_RESOURCE_H) defined(HAVE_GETRLIMIT) 148 { 149 struct rlimit rlim; I seem to remember that it used to be non-kosher to mix declarations and ordinary code like that, but the current compiler doesn't seem to care (I do have #define ENABLE_NLS 1 in Rconfig.h, as I assume you do too). Could you perhaps try moving line 141 down below #endif? Thanks, Dan =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Daniel A. Powers, Ph.D. Department of Sociology University of Texas at Austin 1 University Station A1700 Austin, TX 78712-0118 phone: 512-232-6335 fax: 512-471-1748 [EMAIL PROTECTED] __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Re: [R] make error R-5.1 on sun solaris
You are asked for a C99 compiler and configure normally finds one: mixing declarations and code is valid C99. Unless something has been done with environment variables (e.g. in config.site) this gcc is very old. configure should come up with 'gcc -std=gnu99'. Re-ordering the code will help (but it may need to go below the next #ifdef block too), but a gcc update would be a very good idea as gcc on Sparc has been buggy up to about 3.4.x. Note too that --without-iconv is undesirable and should not be necessary as libiconv can be installed as a preload on Solaris (8 and 10, so presumably also 9). On Thu, 12 Jul 2007, Peter Dalgaard wrote: Dan Powers wrote: I hope this is enough information to determine the problem. Thanks in advance for any help. Configure goes ok (I think) ./configure --prefix=$HOME --without-iconv R is now configured for sparc-sun-solaris2.9 Source directory: . Installation directory:/home/dpowers C compiler:gcc -g -O2 Fortran 77 compiler: f95 -g C++ compiler: g++ -g -O2 Fortran 90/95 compiler:f95 -g Obj-C compiler: -g -O2 Interfaces supported: X11 External libraries:readline Additional capabilities: NLS Options enabled: shared BLAS, R profiling, Java Recommended packages: yes Make ends after the gcc.. make . . . gcc -I. -I../../src/include -I../../src/include -I/usr/openwin/include -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -c system.c -o system.o system.c: In function `Rf_initialize_R': system.c:144: parse error before `char' system.c:216: `localedir' undeclared (first use in this function) system.c:216: (Each undeclared identifier is reported only once system.c:216: for each function it appears in.) *** Error code 1 make: Fatal error: Command failed for target `system.o' Current working directory /home/dpowers/R-2.5.1/src/unix *** Error code 1 make: Fatal error: Command failed for target `R' Current working directory /home/dpowers/R-2.5.1/src/unix *** Error code 1 make: Fatal error: Command failed for target `R' Current working directory /home/dpowers/R-2.5.1/src *** Error code 1 make: Fatal error: Command failed for target `R' I have tried setting localedir directly in configure options, but get the same error. Any ideas? Hmm, which version of gcc is this? The problem seems to be around line 144 which reads 140 Rstart Rp = rstart; 141 cmdlines[0] = '\0'; 142 143 #ifdef ENABLE_NLS 144 char localedir[PATH_MAX+20]; 145 #endif 146 147 #if defined(HAVE_SYS_RESOURCE_H) defined(HAVE_GETRLIMIT) 148 { 149 struct rlimit rlim; I seem to remember that it used to be non-kosher to mix declarations and ordinary code like that, but the current compiler doesn't seem to care (I do have #define ENABLE_NLS 1 in Rconfig.h, as I assume you do too). Could you perhaps try moving line 141 down below #endif? Thanks, Dan =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Daniel A. Powers, Ph.D. Department of Sociology University of Texas at Austin 1 University Station A1700 Austin, TX 78712-0118 phone: 512-232-6335 fax: 512-471-1748 [EMAIL PROTECTED] __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. -- Brian D. Ripley, [EMAIL PROTECTED] 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, UKFax: +44 1865 272595 __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.