[Rcpp-devel] R - couchbase R client using Rcpp

amine gassem amine.gassem at ag-study.com
Wed Mar 19 17:32:54 CET 2014


Context:

I develop a new rcouchbase package client for couchbase.
I am following the example of rhiredis<https://github.com/eddelbuettel/rhiredis>
 package.
Including libcouchbase headers using : #include <libcouchbase/couchbase.h>works
fine.

Problem:

dyn.load failed to load symbol due to and undefined symbol: lcb_destroy.
I think this is a link problem because I don't tell Rcpp compiler where/how
to find libcouchebase libs.
Ho can I fix this?

What I have tried:

Should I create configure.in and makvers.in like in this RcppGSL
package<http://dirk.eddelbuettel.com/code/rcpp/RcppGSL.pdf>
?
Reading the vignette I did not see how can I adopt it for my needs.
Also from this vignette
<http://dirk.eddelbuettel.com/code/rcpp/Rcpp-package.pdf> it
looks like this changed with Rcpp release 0.11.0. These files are now
optional.
And also, The rhiredis <https://github.com/eddelbuettel/rhiredis> package don't
provide a configure for autoconf, and I think  it works fine.


Thanks again for your help.
agstudy




I am








On Tue, Mar 18, 2014 at 6:21 PM, contact AG STUDY <contact at ag-study.com>wrote:

> Dirk,
>
> Thanks for your help. I will get a closer look at rhiredis  package.
>
> Amine GASSEM
>
> For the mail I agree it is better to have my fisrt/last name.
> The problem I am using my professional mail.
> I will see if I can create an alias to this one with a proper identifiable
>  name.
>
>
> On Tue, Mar 18, 2014 at 6:14 PM, Dirk Eddelbuettel <edd at debian.org> wrote:
>
>>
>> Amine,
>>
>> On 18 March 2014 at 17:56, contact AG STUDY wrote:
>> | I would like to use to create an R client for couchbase. ( let me know
>> if there
>> | is already an existing package)
>> | My idea is to create a new R package based on the c
>> library libcouchbase.
>> | This is what is already done for other wrappers in python,ruby,..
>> | What is the best method to call the C code from Rcpp?
>> | Can Iuse dyn.load('../../libcouchebase.so.2"), or should I copy all the
>> c code?
>> | If I should copy , what part of code in the original code I need , src
>> folder
>> | and the makfile for example?
>> | Is there any R/Rcpp package doing similar tasks ( a wrapper to a c
>> library) ,
>> | that I can follow to start ?
>>
>> Among the 186 existing CRAN packages using Rcpp, many do in fact use
>> either
>> an external library as you plan here, or in simpler cases embed the code
>> (eg
>> my RcppCNPy just adds one or two C files).
>>
>> I'll probably also rename lib rhiredis package on Github into RcppRedis to
>> make this more plain; it too uses an external library, here the C library
>> hiredis.
>>
>> Dirk
>>
>> PS List etiquette I'd really like to establish / confirm is to sign an
>> email
>> with a proper, identifiable name.  I tell you who I am, don't readers
>> deserve
>> to know about you if you ask them to help you?
>>
>> --
>> Dirk Eddelbuettel | edd at debian.org | http://dirk.eddelbuettel.com
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20140319/a6ad4a0b/attachment-0001.html>


More information about the Rcpp-devel mailing list