Add support for MUSL based Operation Systems#449
Conversation
|
This unfortunately does not compile on OS X (tested on El Capitan). |
Sorry, something went wrong.
|
Perhaps instead we need to guard this in https://github.com/RcppCore/Rcpp/blob/master/inst/include/Rcpp/platform/compiler.h, with something like and then guard based on that? |
Sorry, something went wrong.
|
It failed because another change is missed. No @kevinushey From the FAQ (http://wiki.musl-libc.org/wiki/FAQ#Q:_why_is_there_no_MUSL_macro_.3F), it seems no way to detect usage of |
Sorry, something went wrong.
|
We could put a else-if in there and have the Alpine user (at least for now) define that themselves... |
Sorry, something went wrong.
|
@thirdwing but backtraces do currently work on OS X, so there must be a more scoped / targeted change. I loathe the idea of making a configure script to do it, though. |
Sorry, something went wrong.
|
@kevinushey Yes, OSX doesn't define The only idea I have now is to detect |
Sorry, something went wrong.
|
As I said before, add a test for I have no intention of breaking OS X, and no appetite for byzantine build mechanisms. |
Sorry, something went wrong.
|
Totally agree. On Mon, Mar 21, 2016 at 3:04 PM, Dirk Eddelbuettel <notifications@github.com
Qiang Kou |
Sorry, something went wrong.
I have added a |
Sorry, something went wrong.
|
That looks much better. And I presume it works for you, ie (And please don't get me wrong -- I have nothing against Musl or Alpine. I use Docker quite a bit and have quite some sympathy for thinner builds but we got to this right and not break a bazillion existing use cases ...) |
Sorry, something went wrong.
Yes! For testing purposes (and given I'm using docker) I have added the x86_64-alpine-linux-musl-g++ -I/usr/lib/R/include -DNDEBUG -D__MUSL__ -I../inst/include -DCOMPILING_DPLYR -Os -fomit-frame-pointer -I"/app/packrat/lib/x86_64-alpine-linux-musl/3.2
.3/Rcpp/include" -I"/app/packrat/lib/x86_64-alpine-linux-musl/3.2.3/BH/include" -fpic -Os -fomit-frame-pointer -c RcppExports.cpp -o RcppExports.obut once Alpine adds that to the |
Sorry, something went wrong.
|
Err, yes, I understand the But what is missing here is someone checking with the good folks of the Musl library to please add such an unmistakable identifier as we cannot possibly do this piecemeal package by package. So let me rephrase: Can you please run a recursive grep over the C library headers for Musl and check that |
Sorry, something went wrong.
Here's the list of macros: https://gist.github.com/lostie/2b60cb4afb3bbba0b928
All I can do is request MUSL community (I've already sent them an e-mail) to set by default in their library. |
Sorry, something went wrong.
|
Yes, please liaise with them. They will need this. I'll fold this in now. We have Rcpp 0.12.4 pending at CRAN so with be for the next release anyway. |
Sorry, something went wrong.
Addresses #448
Final solution: After some discussion we decided the best way would be to add a
__MUSL__test and get Alpine distributions to add that to thePKG_CXXFLAGSUsing suggestion recommend by the(Read below)muslF.A.Q.:http://wiki.musl-libc.org/wiki/FAQ