[R-SIG-Mac] Unable to load local library via GUI

Simon Urbanek simon.urbanek at r-project.org
Tue Oct 4 05:05:11 CEST 2011


Noel,

the package uses BLAS and your R is setup to build against vecLib BLAS which has bad ID so anything linked against it will have trouble finding libRblas. The simple fix is to switch to R BLAS instead of vecLib BLAS (see R for Mac FAQ 12.5). Alternatively update to R 2.13.2, the issue has been fixed in the CRAN binary distribution of R 2.13.2.

Cheers,
Simon


On Oct 3, 2011, at 10:41 PM, Noel Faux wrote:

> Hi all,
> 
> I have an interesting issue specific to the Mac R.app, but not to the command line R or Rstudio.
> I have looked through the archive, however most of the threads seem to be for std packages, and further, most of what is said is a little beyond me, so any help with the problem below would be really appreciated.
> 
> I have a locally developed library (libmlalgs), which I am able to install via the command line:
> sudo R64 CMD INSTALL libmlalgs
> In the /Library/Frameworks/R.framework/Versions/2.13/Resources/library/libmlalgs there is a .so file
> /Library/Frameworks/R.framework/Versions/2.13/Resources/library/libmlalgs/libs/x86_64/libmlalgs.so
> 
> This runs and installs OK.
> I am able to run R64 in the command line and load the libmlalgs library fine :)
> I am able to use Rstudio and load the libmlalgs library fine.
> 
> However, when using the R64.app and try and load the library within the GUI I am getting the following error:
> Error in dyn.load(file, DLLpath = DLLpath, ...) : 
>  unable to load shared object '/Library/Frameworks/R.framework/Versions/2.13/Resources/library/libmlalgs/libs/x86_64/libmlalgs.so':
>  dlopen(/Library/Frameworks/R.framework/Versions/2.13/Resources/library/libmlalgs/libs/x86_64/libmlalgs.so, 6): Library not loaded: libRblas.dylib
>  Referenced from: /Library/Frameworks/R.framework/Versions/2.13/Resources/library/libmlalgs/libs/x86_64/libmlalgs.so
>  Reason: image not found
> Error in library(libmlalgs) : .First.lib failed for 'libmlalgs'
> 
> I know the libmlalgs.so is in the right place and the permissions look OK:
> -rwxr-xr-x  1 root  admin  58384  3 Oct 14:30 libmlalgs.so
> 
> So I am stumped as to why the GUI is unable to read the file.
> 
> Any pointers would very welcome. As I am a textmate user and it passes the code to the R64.app, I currently stuck with either command line or Rstudio (it's nice but is currently missing some key features textmate has)
> 
> Specs:
> Running Mac OSX 10.7.1
> R version 2.13.1 Patched (2011-08-14 r56741)
> Copyright (C) 2011 The R Foundation for Statistical Computing
> ISBN 3-900051-07-0
> Platform: x86_64-apple-darwin9.8.0/x86_64 (64-bit)
> 
> Many thanks,
> Noel Faux
> 
> ---------
> NHMRC Post Doctoral Fellow
> Australian Imaging Biomarker Lifestyle (AIBL) flagship
> Mental Health Research Institute
> ---------
> 155 Oak St, Parkville
> Victoria 3052
> T: +613 9389 2943
> ---------
> The University of Melbourne
> Level 3, Alan Gilbert Building
> 161 Barry Street, Carlton
> Victoria 3010
> T: +613 8344 1944
> ----------------
> This email and any attachments are confidential. They ma...{{dropped:18}}
> 
> _______________________________________________
> R-SIG-Mac mailing list
> R-SIG-Mac at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
> 
> 



More information about the R-SIG-Mac mailing list