Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/r/69.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
从源生成R:生成错误1_R_Unix_Makefile - Fatal编程技术网

从源生成R:生成错误1

从源生成R:生成错误1,r,unix,makefile,R,Unix,Makefile,我正试图在一个我有读、写exec访问权限的目录中从源代码构建R(在unix服务器上)。我试着在谷歌上搜索这个特定的错误,但没有结果。我觉得这很愚蠢 我已将源代码(R-3.0.2)解压缩到该目录/home/rmgzshd/R-3.0.2,并成功运行/configure--prefix=$home/R-3.0.2,并且我具有所需的依赖项,例如./configure消息以以下内容结尾: R is now configured for x86_64-unknown-linux-gnu Source

我正试图在一个我有读、写exec访问权限的目录中从源代码构建R(在unix服务器上)。我试着在谷歌上搜索这个特定的错误,但没有结果。我觉得这很愚蠢

我已将源代码(R-3.0.2)解压缩到该目录
/home/rmgzshd/R-3.0.2
,并成功运行
/configure--prefix=$home/R-3.0.2
,并且我具有所需的依赖项,例如./configure消息以以下内容结尾:

R is now configured for x86_64-unknown-linux-gnu
  Source directory:          .
  Installation directory:    /home/rmgzshd/R-3.0.2
  C compiler:                gcc -std=gnu99  -g -O2
  Fortran 77 compiler:       gfortran  -g -O2
  C++ compiler:              g++  -g -O2
  Fortran 90/95 compiler:    gfortran -g -O2
  Obj-C compiler:
  Interfaces supported:      X11
  External libraries:        readline
  Additional capabilities:   PNG, JPEG, NLS
  Options enabled:           shared BLAS, R profiling
  Recommended packages:      yes
而且我似乎有正确的目录结构,并且在同一个
/configure
目录中生成文件:

ChangeLog      configure     etc      m4           Makefile.bak  Makefrag.cc_lo  NEWS.0    po      SVN-REVISION  VERSION-NICK
config.log     configure.ac  INSTALL  Makeconf     Makefile.fw   Makefrag.cxx    NEWS.1    README  tests
config.site    COPYING       lib64    Makeconf.in  Makefile.in   Makefrag.m      NEWS.2    share   tools
config.status  doc           libtool  Makefile     Makefrag.cc   NEWS            NEWS.pdf  src     VERSION 
但是,
make
命令失败,出现一条似乎完全错误的消息…(因为m4存在)

/bin/sh:line 1:cd:m4:没有这样的文件或目录

我还尝试了一个更简单的
/configure
,没有
--前缀,后跟
make
,但这会使我的安装目录
/usr/bin
,并且失败,并出现同样的错误

有人遇到过这个问题吗?例如,源目录应该是

thx

编辑按照下面的建议,我尝试了
make distclean
,但很明显,不管我得到的
/configure
消息是什么,路径都被阻塞了:

make distclean
/bin/sh: line 1: cd: tests: No such file or directory
/bin/sh: line 1: cd: src: No such file or directory
/bin/sh: line 1: cd: share: No such file or directory
/bin/sh: line 1: cd: etc: No such file or directory
/bin/sh: line 1: cd: doc: No such file or directory
/bin/sh: line 1: cd: tools: No such file or directory
/bin/sh: line 1: cd: m4: No such file or directory

但是它们都在
/home/rmgzshd/R-3.0.2
中,我在那里执行命令

我通过将
CDPATH
的值从
CDPATH=/some/location
更改为
CDPATH=
解决了这个完全相同的问题。 或者,如果需要在
CDPATH
中保留该值,只需将
添加到
CDPATH=。:/some/location


如果您想了解更多有关此行为的信息,请访问

当我在同一目录中多次使用不同的选项来配置
时,有时会发生奇怪的事情:该目录最终包含这些不同尝试的不一致位。您可以通过键入
make distclean
,然后
/configure--prefix=$HOME/R-3.0.2&&make
@Vincent Zoonekynd thx将尝试清理目录。我不会尝试将其安装在与源代码相同的文件夹中。在某个地方创建一个新的空文件夹-
mkdir$HOME/build/R
,然后从一个干净的R源解包中执行
/configure--prefix=$HOME/build/R