gpt4 book ai didi

java - 在 macOS Sierra 10.12.1 : linker error licuuc 上安装 rJava

转载 作者:行者123 更新时间:2023-11-30 08:31:35 25 4
gpt4 key购买 nike

我正在尝试在 R-Studio 中安装 rJava 但出现错误

ld: library not found for -licuuc
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [libjri.jnilib] Error 1
make[1]: *** [src/JRI.jar] Error 2
make: *** [jri] Error 2
ERROR: compilation failed for package ‘rJava’
* removing ‘/Users/iMacLinda/Library/R/3.3/library/rJava’
Warning in install.packages :
installation of package ‘rJava’ had non-zero exit status

R

version _ platform x86_64-apple-darwin16.1.0 arch x86_64 os darwin16.1.0 system x86_64, darwin16.1.0 status major 3 minor 3.2 year 2016 month 10 day 31 svn rev 71607 language R version.string R version 3.3.2 (2016-10-31) nickname Sincere Pumpkin Patch

如何修复此链接器错误?

最佳答案

我在其他地方找到了解决方案,使用 MacPorts,步骤 1-5 由 here 指导和第 6 步由 here 指导.

  1. 作为 root (sudo bash),编辑 /opt/local/Library/Frameworks/R.framework/Resources/etc/Makeconf 并更改行 LIBS = -llzma -lm -liconv -licuuc -licui18nLIBS = -llzma -lm -liconv

  2. 安装原始 1.6 Mac Java

  3. 运行 export JAVA_HOME=/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home

  4. R CMD javareconf

  5. 现在您可以启动 R 并执行 install.packages("rJava")

  6. sudo ln -f -s $(/usr/libexec/java_home)/jre/lib/server/libjvm.dylib/usr/local/lib

    <

关于java - 在 macOS Sierra 10.12.1 : linker error licuuc 上安装 rJava,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40572179/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com