r-lib / cpp11

cpp11 helps you to interact with R objects using C++ code.
https://cpp11.r-lib.org/
Other
193 stars 46 forks source link

vendor path #353

Open pachadotdev opened 4 months ago

pachadotdev commented 4 months ago

A tidy (as in less noise and just 1 commit) version of #340

As @krlmlr suggested, it might be better to vendor to src/vendor instead of inst

This PR implements that and also a better handling and messages about Makevars

DavisVaughan commented 3 months ago

I don't currently have the resources to spend much time on cpp11, but I don't love vendoring in general because it doesn't actually 100% insulate you from cpp11 changes. Previous versions of cpp11 relied on a global R option for the precious list, and that ends up getting shared between, say:

So they aren't fully independent, and if there are changes made to the structure of the thing that gets stored in the global option (which has happened) then whoever sets up the global option first "wins" and can cause the other package to break

krlmlr commented 3 months ago

Interesting. Do you think problems like this are going to resurface?

I've seen very weird behaviors when two cpp11 packages (one of them being duckdb) were used in the same R session. Could have been that.

For duckdb, I don't see a good alternative to vendoring. But if this isn't going to be widely supported, I'm fine with hacking my own solution to move from inst/cpp11 .

pachadotdev commented 3 months ago

@krlmlr hi, I re-made the part that edits the DESCRIPTION

pachadotdev commented 3 months ago

@krlmlr hi, I re-made the part that edits the DESCRIPTION

pachadotdev commented 1 month ago

hi @DavisVaughan @krlmlr I made a small change because I sent another package to CRAN (cpp11armadillo), which was rejected for using path = ".". That issue may eventually affect cpp11. I have used dir and subdir now :)

pachadotdev commented 1 month ago

btw, the only CI that fails is gcc 4.8 because of a bug with the compiler itself