[Rcpp-devel] Redirecting cout/cerr streams to Rprintf

2013-10-23 Thread Renaud Gaujoux
Hi, this is somehow a general C++ question, but it could be of interest to all Rcpp users (I think). Still for the purpose of RcppOctave, I would like to redirect cout and cerr streams that are used by Octave to Rprintf REprintf respectively. Currently I redirect these streams to 2 temporary stri

Re: [Rcpp-devel] RcppOctave on Windows: testing needed

2013-10-11 Thread Renaud Gaujoux
Many thanks for this nice joint investigation work! There certainly still are things to check and tweak to get the package run smoothly and robustly on Mac (and Windows), but this is a great advance! Coming next: * a README file with instructions on how to build/install on these platforms. I w

Re: [Rcpp-devel] RcppOctave on Windows: testing needed

2013-10-10 Thread Renaud Gaujoux
c conflict with std::string. > > > > On Wed, Oct 9, 2013 at 4:21 AM, Renaud Gaujoux < > ren...@mancala.cbio.uct.ac.za> wrote: > >> You are a resourceful person Dominick! :D >> I was not thinking in going Mac for now, because I can't test anything, >

Re: [Rcpp-devel] RcppOctave on Windows: testing needed

2013-10-09 Thread Renaud Gaujoux
You are a resourceful person Dominick! :D I was not thinking in going Mac for now, because I can't test anything, but it will be great if we manage our way through it as well. 1. In src/modules/Makefile.in, the '-F' flag (for framework) is not > recognized by mkoctfile, so I added this tempora

Re: [Rcpp-devel] RcppOctave on Windows: testing needed

2013-10-08 Thread Renaud Gaujoux
ould save the user some >>> trouble if PATH could be updated automatically, but it is probably not >>> a good idea to have R package installation or startup update the users >>> environment... >>> >>> >>> >>> On Mon, Oct 7, 2013 at 10:52

Re: [Rcpp-devel] RcppOctave on Windows: testing needed

2013-10-07 Thread Renaud Gaujoux
ns the file is an > import library, > not a static lib or a shared lib. Import libs tell Windows how to resolve > references > in the corresponding dll. Windows uses the '.lib' suffix for import libs. > For your > purposes you should link against the dll's, not the dll.

Re: [Rcpp-devel] RcppOctave on Windows: testing needed

2013-10-07 Thread Renaud Gaujoux
Dominick, just to be sure: did you have Octave bin directory in your PATH when you tested the package? Because Octave dlls are also in that directory. I am getting confused on which path/dll is to be used where. Currently I build RcppOctave.dll linking against the dll.a files found in "C:\Octave\O

Re: [Rcpp-devel] RcppOctave on Windows: testing needed

2013-10-07 Thread Renaud Gaujoux
Hi, thanks for all these explanations! I believe some clarifications from my side as well may be useful. I also have possibly silly questions :) Building RcppOctave involves 2 separate compilation/linking: * Octave modules that call R RNG functions, but -- currently -- do not use Rcpp at all:

[Rcpp-devel] RcppOctave on Windows: testing needed

2013-10-04 Thread Renaud Gaujoux
Hi all, I finally got RcppOctave to work on Windows! See these threads for details on what it took: http://lists.r-forge.r-project.org/pipermail/rcpp-devel/2013-October/006524.html http://lists.r-forge.r-project.org/pipermail/rcpp-devel/2013-October/006555.html I would love to have feedbacks -- a

Re: [Rcpp-devel] Defining template specialisation for wrap on Windows 64bit (Compilation error: 'result_type' does not name a type)

2013-10-04 Thread Renaud Gaujoux
ding the "typename" would itself be an error :-) > > Steve > > -Original Message- > From: Dirk Eddelbuettel [mailto:e...@debian.org] > Sent: Friday, October 04, 2013 12:12 PM > To: Renaud Gaujoux > Cc: Steve Jaffe; rcpp-devel@lists.r-forge.r-project.org

Re: [Rcpp-devel] Defining template specialisation for wrap on Windows 64bit (Compilation error: 'result_type' does not name a type)

2013-10-04 Thread Renaud Gaujoux
I posted the follow up email adding [SOLVED] to the subject, but I thought it would appear in the same thread. Here it is: http://lists.r-forge.r-project.org/pipermail/rcpp-devel/2013-October/006555.html Indeed, one of the suggested solution out there was to add "typename" in the typdef statement

Re: [Rcpp-devel] Defining template specialisation for wrap on Windows 64bit (Compilation error: 'result_type' does not name a type) [SOLVED]

2013-10-04 Thread Renaud Gaujoux
Hi all, Steve's post got me thinking about a potential more general template declaration issue, so I browsed around, and came across this post in SO (as well as a couple of others): http://stackoverflow.com/questions/14753499/type-defined-in-template-class-does-not-name-a-type This made me try to

Re: [Rcpp-devel] Defining template specialisation for wrap on Windows 64bit (Compilation error: 'result_type' does not name a type)

2013-10-04 Thread Renaud Gaujoux
Thanks for popping in Steve. I was full of hope when I read your reply! Unfortunately I could not solve the issue with the changes you suggested. > I believe the correct syntax for the specialization is > > template <> octave_value as( SEXP ); > This declaration works as fine on Linux as

Re: [Rcpp-devel] Defining template specialisation for wrap on Windows 64bit (Compilation error: 'result_type' does not name a type)

2013-10-03 Thread Renaud Gaujoux
> > I understand that. But I fear you are bitten by a side-effect of linking > against the full R on Windows, and linking against a much smaller subset may > give you a better chance at success (conditional on my first hypothesis being > correct, which may be unlikely ;-) The error occurs on compi

Re: [Rcpp-devel] Defining template specialisation for wrap on Windows 64bit (Compilation error: 'result_type' does not name a type)

2013-10-03 Thread Renaud Gaujoux
Thanks Dirk for shooting ideas here :) > > If you only need the RNGs from R, did you consider using R's standalone Math > library? We can build that fine on Linux, maybe it can be built on Windows? > (Not sure anybody would have it ...) > In short: 1) not needed 2) not wanted In long: 1) not ne

Re: [Rcpp-devel] Defining template specialisation for wrap on Windows 64bit (Compilation error: 'result_type' does not name a type)

2013-10-03 Thread Renaud Gaujoux
\Octave3.6.4_gcc4.6.2\lib -loctinterp -loctave -lcruft On 1 October 2013 17:51, Renaud Gaujoux wrote: >> Yay! Three cheers! > > Indeed wouldn't it be nice to get it working on windows uh? I had a > number of queries for this recently... > >> I'd simplify first. Try smaller examp

Re: [Rcpp-devel] Defining template specialisation for wrap on Windows 64bit (Compilation error: 'result_type' does not name a type)

2013-10-01 Thread Renaud Gaujoux
> Yay! Three cheers! Indeed wouldn't it be nice to get it working on windows uh? I had a number of queries for this recently... > I'd simplify first. Try smaller example on Windows not involving Octave > headers. > Yes, sorry I did not mentioned this. This is definitely linked with Octave. I did

[Rcpp-devel] Defining template specialisation for wrap on Windows 64bit (Compilation error: 'result_type' does not name a type)

2013-10-01 Thread Renaud Gaujoux
Hi, I wanted to "quickly" port my package RcppOctave to run on Windows but it turned out trickier than expected :( I am getting compilation errors (8750 lines of errors - see first line below). The code defines a specialisation for wrap, following the non-intrusive way described in the vignette.