roxygen2似乎讨厌我。我在R 3.6.3 OS X 10.14.6中安装了它,看起来一切正常:
> install.packages("roxygen2")
--- Please select a CRAN mirror for use in this session ---
trying URL 'https://ftp.osuosl.org/pub/cran/bin/macosx/el-capitan/contrib/3.6/roxygen2_7.1.0.tgz'
Content type 'application/x-gzip' length 955820 bytes (933 KB)
==================================================
downloaded 933 KB
The downloaded binary packages are in
/var/folders/lm/c2f0w7g95q18plrh3bzc8klmfjh9r3/T//RtmphL5OZw/downloaded_packages
但是那......
> library(roxygen2)
Error: package or namespace load failed for ‘roxygen2’ in dyn.load(file, DLLpath = DLLpath, ...):
unable to load shared object '/Library/Frameworks/R.framework/Versions/3.6/Resources/library/Rcpp/libs/Rcpp.so':
dlopen(/Library/Frameworks/R.framework/Versions/3.6/Resources/library/Rcpp/libs/Rcpp.so, 6): Symbol not found: __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev
Referenced from: /Library/Frameworks/R.framework/Versions/3.6/Resources/library/Rcpp/libs/Rcpp.so (which was built for Mac OS X 10.14)
Expected in: /usr/local/lib/libstdc++.6.dylib
in /Library/Frameworks/R.framework/Versions/3.6/Resources/library/Rcpp/libs/Rcpp.so
我该如何修复?