none
Rccp failure RRS feed

  • Question

  • R Open does not work with Rcpp on OSX (and probably linux) as we're missing a bunch of libraries. 

    library(Rcpp)
    evalCpp("2 + 2")

    clang: error: no such file or directory: '/usr/local/lib/libcairo.a'
    clang: error: no such file or directory: '/usr/local/lib/libpixman-1.a'
    clang: error: no such file or directory: '/usr/local/lib/libfreetype.a'
    clang: error: no such file or directory: '/usr/local/lib/libfontconfig.a'
    clang: error: no such file or directory: '/usr/local/lib/libreadline.a'
    make: *** [sourceCpp_1.so] Error 1

    This issue was raised on stackoverflow in feb
    http://stackoverflow.com/questions/35687820/osx-rcpp-sourcecpp-errors

    Wednesday, May 4, 2016 8:32 AM

All replies

  • This is fixed on OSX with a simple 'brew install cairo' - not sure why Rcpp depends on this! 
    • Proposed as answer by Andrie de Vries Tuesday, May 17, 2016 2:19 PM
    • Marked as answer by znite Tuesday, May 17, 2016 2:52 PM
    • Unmarked as answer by znite Tuesday, May 17, 2016 3:04 PM
    Wednesday, May 4, 2016 8:43 AM
  • I just marked this as an answer, but realised this is not - R Open should be a direct drop-in replacement for R, as Rcpp isnt working this should be considered a bug in R Open. 

    Tuesday, May 17, 2016 3:06 PM
  • Hack I found googling:

    $ brew install readline
    $ brew link --force readline
    $ brew install cairo

    Saturday, July 9, 2016 2:51 AM
  • I second this observation. The root of the problem is that 

    R CMD SHLIB does not work as the position of the above mentioned libraries are hardwired and not present on all systems. Using brew to install them is not really a solution IMHO.

    gg

    Wednesday, July 27, 2016 2:44 PM