On 4 May 2017 at 10:16, Yue Li wrote: | Dear List, | | This is probably a dumb question: | | Is there an easy way to convert Rcpp code to pure cpp code to build a command line tool? | | I was thinking about something similar to the 'python setup.py install’ thing. Once the software is built, the binary executable can be added to /usr/bin/ and invoked directly on command line without the R environment.
Not quite. "All you get" is python script with, say '#!/usr/bin/python' loading the packaged modules. And *not* a binary executable. And guess what: all that exists for R too via littler and Rscript. Maybe start here http://dirk.eddelbuettel.com/code/littler.html and look at all the examples here http://dirk.eddelbuettel.com/code/littler.examples.html and in the repo https://github.com/eddelbuettel/littler/tree/master/inst/examples You then deploy packages using Rcpp just any of the other R packages. | I apologize as the question seems to be spoiled in that i could write everything in cpp in the first place ... Yes, it was an off-topic question. Dirk | | many thanks! | Yue | | | _______________________________________________ | Rcpp-devel mailing list | Rcpp-devel@lists.r-forge.r-project.org | https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel -- http://dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org _______________________________________________ Rcpp-devel mailing list Rcpp-devel@lists.r-forge.r-project.org https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel