[Rd] Unable to compile R 3.1.3 under GCC 4.1.2 (Red Hat 4.1.2-51)
Gábor Csárdi
csardi.gabor at gmail.com
Mon Sep 1 23:01:17 CEST 2014
Hi, see this about updating your gcc. Assuming you can do that:
https://www.centos.org/forums/viewtopic.php?t=22240
Gabor
On Mon, Sep 1, 2014 at 3:58 PM, Titus Barik <titus at barik.net> wrote:
> Hi all,
>
> I'm unable to compile R under an HPC system (which like many HPC systems
> doesn't always have the latest and greatest software). The version of
> GCC is 4.1.2 under CentOS 5.7. Running ./configure gives the following
> output:
>
> R is now configured for x86_64-unknown-linux-gnu
>
> Source directory: .
> Installation directory: /home/tbarik
>
> C compiler: gcc -std=gnu99 -I/home/tbarik/include
> Fortran 77 compiler: gfortran -g -O2
>
> C++ compiler: g++ -g -O2
> C++ 11 compiler:
> Fortran 90/95 compiler: gfortran -g -O2
> Obj-C compiler:
>
> Interfaces supported: X11
> External libraries: readline
> Additional capabilities: NLS
> Options enabled: shared BLAS, R profiling
>
> Recommended packages: yes
>
> which I think looks good (at least, -std=gnu99 appears to be present).
> However, when I try make, I receive the following dump during
> installation of the Matrix package:
>
> * installing *source* package 'Matrix' ...
> ** package 'Matrix' successfully unpacked and MD5 sums checked
> ** libs
> make[3]: Entering directory
> `/state/partition1/tmp/RtmpCw7v7G/R.INSTALL3227fa892a3/Matrix/src'
> mpicc -I/home/tbarik/src/R-3.1.1/include -DNDEBUG -DNTIMER
> -I./SuiteSparse_config -I/usr/local/incl ude -fpic
> -I/home/tbarik/include -c CHMfactor.c -o CHMfactor.o
> In file included from CHMfactor.h:4,
> from CHMfactor.c:2:
> Mutils.h: In function 'inv_permutation':
> Mutils.h:270: error: 'for' loop initial declaration used outside C99
> mode
> In file included from Mutils.h:374,
> from CHMfactor.h:4,
> from CHMfactor.c:2:
> t_sparseVector.c: In function 'dsparseVector_sub':
> t_sparseVector.c:139: error: 'for' loop initial declaration used outside
> C99 mode
> In file included from Mutils.h:377,
> from CHMfactor.h:4,
> from CHMfactor.c:2:
> t_sparseVector.c: In function 'isparseVector_sub':
> t_sparseVector.c:139: error: 'for' loop initial declaration used outside
> C99 mode
> In file included from Mutils.h:380,
> from CHMfactor.h:4,
> from CHMfactor.c:2:
> t_sparseVector.c: In function 'lsparseVector_sub':
> t_sparseVector.c:139: error: 'for' loop initial declaration used outside
> C99 mode
> In file included from Mutils.h:383,
> from CHMfactor.h:4,
> from CHMfactor.c:2:
> t_sparseVector.c: In function 'nsparseVector_sub':
> t_sparseVector.c:139: error: 'for' loop initial declaration used outside
> C99 mode
> In file included from Mutils.h:386,
> from CHMfactor.h:4,
> from CHMfactor.c:2:
> t_sparseVector.c: In function 'zsparseVector_sub':
> t_sparseVector.c:139: error: 'for' loop initial declaration used outside
> C99 mode
> make[3]: *** [CHMfactor.o] Error 1
> make[3]: Leaving directory
> `/state/partition1/tmp/RtmpCw7v7G/R.INSTALL3227fa892a3/Matrix/src'
> ERROR: compilation failed for package 'Matrix'
> * removing '/home/tbarik/src/R-3.1.1/library/Matrix'
> make[2]: *** [Matrix.ts] Error 1
>
> Any advice on what to do is greatly appreciated.
>
> Thanks,
>
> Titus
>
>
> --
> Titus Barik, PE <titus at barik.net>
>
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
More information about the R-devel
mailing list