[R-SIG-Mac] RcppArmadillo errors

David Winsemius dwinsemius at comcast.net
Thu Sep 1 21:40:10 CEST 2016


> On Sep 1, 2016, at 11:58 AM, David Winsemius <dwinsemius at comcast.net> wrote:
> 
> 
>> On Aug 27, 2016, at 5:35 AM, Oskar Knapik <oknapik at gmail.com> wrote:
>> 
>> Dear all
>> 
>> I am having some problems with your package.
>> 
>> It looks that I can't load it on my Mac computer (OS X El Capitan 10.11.6)
>> 
>> I got the following errors:
>> Error in dyn.load(file, DLLpath = DLLpath, ...) : 
>> can't load shared object
>> '/Users/oknapik/Library/R/3.3/library/RcppArmadillo/libs/RcppArmadillo.so':
>> dlopen(/Users/oknapik/Library/R/3.3/library/RcppArmadillo/libs/RcppArmadillo.so, 6): Library not loaded: /Library/Frameworks/R.framework/Versions/3.3/Resources/lib/libRlapack.dylib
>> Referenced from: /Users/oknapik/Library/R/3.3/library/RcppArmadillo/libs/RcppArmadillo.so
>> Reason: image not found
>> 
>> The newest OS X doesn't support X11 (I am not sure if you use it)
> 
> XQuartz is the X11 for the Mac:
> 
> https://www.xquartz.org/
> 
> This error can be found on SO and I think the second answer (to just (re-?) install XQuartz) is the correct one.
> 
> http://stackoverflow.com/questions/26489928/cant-load-x11-in-r-after-os-x-yosemite-upgrade
> 
> -- 
> David.
>> 
>> I am also trying to install the package on Microsoft R
>> https://mran.microsoft.com <https://mran.microsoft.com/>
>> 
>> 
>> Below the errors from the installation:
>> 
>> install.packages("RcppArmadillo", verbose=T)
>> Installing package into ‘/Users/oknapik/Library/R/3.3/library’
>> (as ‘lib’ is unspecified)
>> system (cmd0): /Library/Frameworks/R.framework/Resources/bin/R CMD INSTALL
>> trying URL 'https://mran.revolutionanalytics.com/snapshot/2016-07-01/src/contrib/RcppArmadillo_0.7.100.3.1.tar.gz <https://mran.revolutionanalytics.com/snapshot/2016-07-01/src/contrib/RcppArmadillo_0.7.100.3.1.tar.gz>'
>> Content type 'application/octet-stream' length 1055712 bytes (1.0 MB)
>> ==================================================
>> downloaded 1.0 MB
>> 
>> foundpkgs: RcppArmadillo, /var/folders/mr/_t437jvd5v5fty4z3pypn_yc0000gn/T//RtmpPj3WB7/downloaded_packages/RcppArmadillo_0.7.100.3.1.tar.gz
>> files: /var/folders/mr/_t437jvd5v5fty4z3pypn_yc0000gn/T//RtmpPj3WB7/downloaded_packages/RcppArmadillo_0.7.100.3.1.tar.gz
>> Warning
>> In command 'doTryCatch(return(expr), name, parentenv, handler)':
>> can't load the shared object  '/Library/Frameworks/R.framework/Resources/modules//R_X11.so':

snipped

>> ld: warning: directory not found for option '-L/private/var/root/jenkins/workspace/External-R-3.3.1/vendor/build/lib'
>> ld: warning: directory not found for option '-L/usr/local/lib/gcc/i686-apple-darwin8/4.2.3/x86_64'
>> ld: warning: directory not found for option '-L/usr/local/lib/x86_64'
>> ld: warning: directory not found for option '-L/usr/local/lib/gcc/i686-apple-darwin8/4.2.3'
>> ld: library not found for -lgfortran
>> clang: error: linker command failed with exit code 1 (use -v to see invocation)

Apologies for the noise. 

The XQuartz concern wasn't the actual error. I didn't read down far enough. Appears you do have an earlier version of RcppArmadillo although it's not clear which one it might be. I was able to install both a binary (RcppArmadillo_0.7.400.2.0.tgz) and from source: https://cran.cnr.berkeley.edu/src/contrib/RcppArmadillo_0.7.400.2.0.tar.gz  without difficulty. (No warnings.)  That appears to be the current version that would install from CRAN and it's also the one I see at MRAN: https://mran.microsoft.com/src/contrib/RcppArmadillo_0.7.400.2.0.tar.gz

You are installing a somewhat older version. Using https://mran.microsoft.com made me wonder if you may have an earlier version of R distributed by Microsoft, although your directory naming suggests they have now "caught up". The "standard" version of Fortran for the Mac is at http://r.research.att.com/tools/   The MRAN distribution is not entirely standar. I have not heard of discrepancies with Fortran dependencies in the past.

-- David


>> make: *** [RcppArmadillo.so] Error 1
>> ERROR: compilation failed for package ‘RcppArmadillo’
>> * removing ‘/Users/oknapik/Library/R/3.3/library/RcppArmadillo’
>> * restoring previous ‘/Users/oknapik/Library/R/3.3/library/RcppArmadillo’
>> Warning in install.packages :
>> installation of package ‘RcppArmadillo’ had non-zero exit status
>> 
>> 
>> 
>> I would be very grateful for help.
>> 
>> Best,
>> Oskar
>> 	[[alternative HTML version deleted]]
>> 
>> _______________________________________________
>> R-SIG-Mac mailing list
>> R-SIG-Mac at r-project.org
>> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
> 
> David Winsemius
> Alameda, CA, USA
> 
> _______________________________________________
> R-SIG-Mac mailing list
> R-SIG-Mac at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-mac

David Winsemius
Alameda, CA, USA



More information about the R-SIG-Mac mailing list