I'm trying to install R3.1.1 from sources on CentOS 6.5.
我正在尝试从CentOS 6.5的源代码中安装R3.1.1。
The .configure
raises the following error
配置引发以下错误
(...)
checking whether we can compute C Make dependencies... yes, using $(CC) -MM
checking whether gcc -std=gnu99 supports -c -o FILE.lo... yes
checking for gcc -std=gnu99 option to support OpenMP... -fopenmp
checking how to get verbose linking output from gfortran... -v
checking for Fortran 77 libraries of gfortran... -L/usr/local/lib64 -L/cm/shared/apps/slurm/14.03.0/lib64/../lib64 -L/cm/shared/apps/gcc/4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2 -L/cm/shared/apps/gcc/4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -L/cm/shared/apps/slurm/14.03.0/lib64/slurm -L/cm/shared/apps/slurm/14.03.0/lib64 -L/cm/shared/apps/gcc/4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2/../../.. -lgfortran -lm -lquadmath
checking how to get verbose linking output from gcc -std=gnu99... -v
checking for C libraries of gcc -std=gnu99... -L/usr/local/lib64 -L/cm/shared/apps/slurm/14.03.0/lib64/../lib64 -L/cm/shared/apps/gcc/4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2 -L/cm/shared/apps/gcc/4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -L/cm/shared/apps/slurm/14.03.0/lib64/slurm -L/cm/shared/apps/slurm/14.03.0/lib64 -L/cm/shared/apps/gcc/4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2/../../.. -lgcc_s
checking for dummy main to link with Fortran 77 libraries... none
checking for Fortran 77 name-mangling scheme... lower case, underscore, no extra underscore
checking whether gfortran appends underscores to external names... yes
checking whether gfortran appends extra underscores to external names... no
checking whether mixed C/Fortran code can be run... configure: WARNING: cannot run mixed C/Fortran code
configure: error: Maybe check LDFLAGS for paths to Fortran libraries?
gfortran was installed using yum
使用yum安装gfortran
gfortran --version
GNU Fortran (GCC) 4.8.2
Copyright (C) 2013 Free Software Foundation, Inc.
I've no idea what I should put in LDFLAGS to fix that error.
我不知道应该在LDFLAGS中放置什么来修正这个错误。
UDPATE:
UDPATE:
# find / -name "libgfor*.so"
/usr/lib/gcc/x86_64-redhat-linux/4.4.4/libgfortran.so
/usr/lib/gcc/x86_64-redhat-linux/4.4.4/32/libgfortran.so
/usr/lib/gcc/x86_64-redhat-linux/4.4.4/libgfortran.so
/usr/lib/gcc/x86_64-redhat-linux/4.4.4/32/libgfortran.so
/cm/shared/apps/gcc/4.8.2/lib64/libgfortran.so
/cm/shared/apps/gcc/4.8.2/lib/libgfortran.so
/cm/images/default-image/usr/lib/gcc/x86_64-redhat-linux/4.4.4/libgfortran.so
/cm/images/default-image/usr/lib/gcc/x86_64-redhat-linux/4.4.4/32/libgfortran.so
.
。
# tail config.log
#define SIZEOF_LONG_LONG 8
#define SIZEOF_DOUBLE 8
#define SIZEOF_SIZE_T 8
#define HAVE_LONG_DOUBLE 1
#define SIZEOF_LONG_DOUBLE 16
#define F77_FUNC(name,NAME) name ## _
#define F77_FUNC_(name,NAME) name ## _
#define HAVE_F77_UNDERSCORE 1
configure: exit 1
1 个解决方案
#1
3
Try to locate libgfortran.so
in your system and provide the path -Lthe_path -lgfortran
or set the respective environment variables. If that does not help, try to find more details in the config.log
(or similar) file to find out what does the configure actually try to do in that check.
试图找到libgfortran。因此,在您的系统中,提供路径-Lthe_path -lgfortran或设置相应的环境变量。如果这没有帮助,请尝试在配置中查找更多细节。记录(或类似)文件,以查明configure在该检查中实际尝试做什么。
Your gfortran reports it is version 4.8.2
but the libraries are from version 4.4.4
. Try to locate (by which
) which gfortran binary you run and where are its libraries. Try running the locate
command for libgfortran
.
您的gfortran报告它是4.8.2版,但是库来自4.4.4版。尝试定位你运行的gfortran二进制文件以及它的库在哪里。尝试运行libgfortran的locate命令。
#1
3
Try to locate libgfortran.so
in your system and provide the path -Lthe_path -lgfortran
or set the respective environment variables. If that does not help, try to find more details in the config.log
(or similar) file to find out what does the configure actually try to do in that check.
试图找到libgfortran。因此,在您的系统中,提供路径-Lthe_path -lgfortran或设置相应的环境变量。如果这没有帮助,请尝试在配置中查找更多细节。记录(或类似)文件,以查明configure在该检查中实际尝试做什么。
Your gfortran reports it is version 4.8.2
but the libraries are from version 4.4.4
. Try to locate (by which
) which gfortran binary you run and where are its libraries. Try running the locate
command for libgfortran
.
您的gfortran报告它是4.8.2版,但是库来自4.4.4版。尝试定位你运行的gfortran二进制文件以及它的库在哪里。尝试运行libgfortran的locate命令。