Search code examples
eclipseeclipse-cdtrcpparmadillo

setting up the Eclipse for Rcpp/Armadillo


I am new to area of writing functions for using in R using Rcpp and Armadillo. I was looking trough the Tutorials and other questions which asked about this topic, but I was not able to find something suitable because most of them were out dated and did not work for me.

I would like to ask for any help with setting up the Eclipse for using Rcpp on Windows 10.

Best wishes.


Solution

  • The R Project documents all build and tests steps via commands starting with R with for example

    • R CMD build
    • R CMD COMPILE
    • R CMD SHLIB

    and so on. Eclipse, as far as I know, prefers cmake so you need to write a CMakeLists.txt to do what you need. You will have to duplicate file location searches and all those features R provides for you. I suspect this to be a bit of work.

    I did receive a contribution to RInside many moons ago so if you in its inst/examples/ directory:

    edd@rob:~/git/rinside(master)$ find . -name CMakeLists.txt
    ./inst/examples/eigen/cmake/CMakeLists.txt
    ./inst/examples/wt/cmake/CMakeLists.txt
    ./inst/examples/qt/cmake/CMakeLists.txt
    ./inst/examples/mpi/cmake/CMakeLists.txt
    ./inst/examples/armadillo/cmake/CMakeLists.txt
    ./inst/examples/standard/cmake/CMakeLists.txt
    edd@rob:~/git/rinside(master)$ 
    

    I am not sure if these are still current and working but you could start there.