【问题标题】:R compilation failed for package fst包 fst 的 R 编译失败
【发布时间】:2018-08-25 21:31:56
【问题描述】:

我正在尝试从 CRAN 安装 fst R 包,但出现错误:

gcc -I"/path/apps/R/3.5.1-20180807-test/x86_64-linux-2.6-rhel6/lib64/R/include" -DNDEBUG 
-fopenmp -I. -Ifstcore -Ifstcore_v1 -Ifstcore/LZ4 -Ifstcore/ZSTD -Ifstcore/ZSTD/common 
-Ifstcore/ZSTD/decompress -Ifstcore/ZSTD/compress 
-I"/path/apps/R/3.5.1-20180807-test/x86_64-linux-2.6-rhel6/r_libs_site/Rcpp/include" 
-I /path/apps/R/static-zlib-gcc6.3/x86_64-linux-2.6-rhel6/include   -fpic  
-I /path/apps/R/static-zlib-gcc6.3/x86_64-linux-2.6-rhel6/include   
-c fstcore/ZSTD/compress/huf_compress.c -o fstcore/ZSTD/compress/huf_compress.o
gcc -I"/path/apps/R/3.5.1-20180807-test/x86_64-linux-2.6-rhel6/lib64/R/include" -DNDEBUG 
-fopenmp -I. -Ifstcore -Ifstcore_v1 -Ifstcore/LZ4 -Ifstcore/ZSTD -Ifstcore/ZSTD/common 
-Ifstcore/ZSTD/decompress -Ifstcore/ZSTD/compress 
-I"/path/apps/R/3.5.1-20180807-test/x86_64-linux-2.6-rhel6/r_libs_site/Rcpp/include" 
-I /path/apps/R/static-zlib-gcc6.3/x86_64-linux-2.6-rhel6/include   -fpic  
-I /path/apps/R/static-zlib-gcc6.3/x86_64-linux-2.6-rhel6/include   
-c fstcore/ZSTD/decompress/zstd_decompress.c -o fstcore/ZSTD/decompress/zstd_decompress.o
/tmp/cc0LoSFX.s: Assembler messages:
/tmp/cc0LoSFX.s:7353: Error: no such instruction: `shlx %rax,%rdx,%rax'
/tmp/cc0LoSFX.s:8204: Error: no such instruction: `shlx %rax,%rdx,%rax'
/tmp/cc0LoSFX.s:8608: Error: no such instruction: `shlx %rax,%rdx,%rax'
make: *** [fstcore/ZSTD/decompress/zstd_decompress.o] Error 1
ERROR: compilation failed for package ‘fst’

我有任何需要的可以从源代码编译的 linux 库吗?我还能做什么?

编辑:

$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/path/apps/gcc/6.3.0/x86_64-linux-2.6-rhel6/bin/../libexec/gcc/x86_64-pc-linux-gnu/6.3.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ./configure --prefix=/path/apps/gcc/6.3.0/x86_64-linux-2.6-rhel6 --disable-multilib
Thread model: posix
gcc version 6.3.0 (GCC)

【问题讨论】:

  • 你的 gcc 版本是多少?
  • @Dirk Eddelbuettel 6.3.0
  • 那么可能会有其他事情发生。
  • 在 CRAN 上,它显示 SystemRequirements: little-endian platform。您有特殊类型的操作系统吗?它在 Solaris 上失败了。
  • 我的操作系统是 RHEL6。并且它已经由以前的人为 R 3.4.3 安装,所以它是可能的。

标签: r gcc compiler-errors compilation r-package


【解决方案1】:

将其放在这里以供后代使用,以防其他人在遇到类似问题时最终遇到此问题。

事实证明,据我们所知,问题在于汇编程序 (/usr/bin/as) 和 gcc(我们的非系统 6.3.0 安装)的版本不兼容。

因此,如果您在不知道为什么会看到这些错误的情况下到达这里,请考虑获取兼容版本的汇编程序(在 linux 世界中,这是 binutils 模块/项目的一部分)。希望对您有所帮助。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2012-11-09
    • 2013-12-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-02-02
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多