Displaying 3 results from an estimated 3 matches similar to: "Platform dependent native routine registration"
2017 Mar 07
0
Platform dependent native routine registration
On 7 March 2017 at 14:13, G?bor Cs?rdi wrote:
| Dear All,
|
| I am trying to convert a package to native routine registration, and
| not sure how to
| best solve the problem of C functions that are only used for a single
| platform, i.e.
| Windows, Linux (& Unix) or macOS.
|
| If I simply provide a different method table for each platform, then the .Call()
| statements for the other
2017 Mar 07
2
Platform dependent native routine registration
On Tue, Mar 7, 2017 at 2:45 PM, Dirk Eddelbuettel <edd at debian.org> wrote:
[...]
>
> Could you resort to preprocessor conditioning to only compile the code
> relevant for a particular platform while hiding away the inapplicable parts?
Yes, I do exactly that. The problem is that the R code still has
.Call(c_non_existent_function_on_this_platform, ...)
and R CMD check picks up on
2017 Mar 07
1
Platform dependent native routine registration
On Tue, Mar 7, 2017 at 2:51 PM, Dirk Eddelbuettel <edd at debian.org> wrote:
[...]
> | But I just found that using string literals in .Call() works just
> | fine. Hopefully
> | this will still be allowed in the long run:
> |
> | .Call("c_non_existent_function_on_this_platform", ...)
>
> So you are adjusting the literals on the fly at compilation time?
No, I