0

特别是我试图在 linux 上本地安装 rggobi(我没有 root 访问权限)。所以我在本地安装了ggobi

cd ggobi-2.1.11/
./configure --prefix=~/my-apps/ --with-all-plugins
make
make install

一切顺利。然后我尝试了

$ R CMD INSTALL /tmp/Rtmp2PL6au/downloaded_packages/rggobi_2.1.20.tar.gz -l ~/R/x86_64-redhat-linux-gnu-library/3.1/
* installing *source* package ‘rggobi’ ...
** package ‘rggobi’ successfully unpacked and MD5 sums checked
checking for pkg-config... /usr/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for GGOBI... no
configure: error: Package requirements (ggobi >= 2.1.6) were not met:
No package 'ggobi' found

Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix.
Alternatively, you may set the environment variables GGOBI_CFLAGS and GGOBI_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
ERROR: configuration failed for package ‘rggobi’
* removing ‘/apps/infrafs1/rdahiya/R/x86_64-redhat-linux-gnu-library/3.1/rggobi’

我尝试在 PKG_CONFIG_PATH 中添加 ~/my-apps/lib/pkgconfig/ 这有助于安装更进一步,但最后它给出了不同的错误

building package indices
testing if installed package can be loaded
Error in dyn.load(file, DLLpath = DLLpath, ...) : 
unable to load shared object '~/R/x86_64-redhat-linux-gnu-library/3.1/rggobi/libs/rggobi.so': libggobi.so.0: cannot open shared object file: No such file or directory
Error: loading failed
Execution halted
ERROR: loading failed
removing ‘~/R/x86_64-redhat-linux-gnu-library/3.1/rggobi’

libggobi.so.0 在 ~/my-apps/lib/ 中。有什么建议可以让 R 查看正确的位置吗?

4

1 回答 1

0

我找到了一个(?)解决方法。我必须设置 LD_LIBRARY_PATH=~/my-apps/lib/ 在安装或运行任何我想加载 rggobi 的未来 R 会话时。如果您有更干净的解决方案,请分享。

于 2014-08-29T14:26:24.483 回答