Re: [Rcpp-devel] Using CMakeLists.txt

2013-03-05 Thread Dirk Eddelbuettel
On 5 March 2013 at 16:06, Richard Downe wrote: | On http://cran.r-project.org/doc/manuals/R-exts.html, a configure script seems | to be described as an equally respectable alternative to Makevars -- it sounds No. configure determines compile-time _values_ which are then inserted into a Makevars.i

Re: [Rcpp-devel] Using CMakeLists.txt

2013-03-05 Thread Richard Downe
One other detail: cmake by default names all library outputs "lib[TARGET]". (e.g., there *is* no my_package.so, but possibly a libmy_package.so) If you add the line SET_TARGET_PROPERTIES(fusionIndices PROPERTIES PREFIX "") you'll have better luck as well. -rd On 03/05/2013 04:00 PM, Richard

Re: [Rcpp-devel] Using CMakeLists.txt

2013-03-05 Thread Richard Downe
I must admit, it's been awhile since I cobbled together my solution; I know it's worked seamlessly on 2 or 3 linux variants, but hasn't been tested beyond that. I do recall getting frustrated with making cmake interact with Makevars; On http://cran.r-project.org/doc/manuals/R-exts.html, a conf

Re: [Rcpp-devel] Using CMakeLists.txt

2013-03-05 Thread Richard Downe
Also, you're failing to tell CMake to build a shared library. You need SET(CMAKE_C++_CREATE_SHARED_LIBRARY 1) And if you're using Rcpp, also need to explicitly add Rcpp link flags (Rscript -e Rcpp:::LdFlags()) -rd On 03/05/2013 03:44 PM, Richard Downe wrote: What I've been doing the past coupl

Re: [Rcpp-devel] Using CMakeLists.txt

2013-03-05 Thread Dirk Eddelbuettel
On 5 March 2013 at 15:44, Richard Downe wrote: | What I've been doing the past couple years, which has worked extremely | well, is to use a configure script (I've used perl because it allows me | to do a bunch of other build-time processing that's specific to my | package, but bash would work f

Re: [Rcpp-devel] Using CMakeLists.txt

2013-03-05 Thread Richard Downe
What I've been doing the past couple years, which has worked extremely well, is to use a configure script (I've used perl because it allows me to do a bunch of other build-time processing that's specific to my package, but bash would work fine as well). All you need (for perl) is: #!/usr/bin/

Re: [Rcpp-devel] Using CMakeLists.txt

2013-03-05 Thread Dirk Eddelbuettel
On 5 March 2013 at 12:21, Etienne B. Racine wrote: | I'd like to use a PCL algorithm inside R and they provide a CMakeLists.txt for | configuration. I haven't found how to directly use the CMakeLists.txt in | building R package, however when I run `make .` form src, I can generate a | Makefile  th

[Rcpp-devel] Using CMakeLists.txt

2013-03-05 Thread Etienne B. Racine
I'd like to use a PCL algorithm inside R and they provide a CMakeLists.txt for configuration. I haven't found how to directly use the CMakeLists.txt in building R package, however when I run `make .` form src, I can generate a Makefile that nearly works with `R CMD INSTALL --no-multiarch`. It doe