ropensci / redland-bindings

Redland librdf language bindings
http://librdf.org/bindings/
Other
17 stars 3 forks source link

Fix CRAN warnings #70

Closed gothub closed 6 years ago

gothub commented 6 years ago

Resolve problems shown from the CRAN 'results' page:

1:

checking R code for possible problems ... [10s/13s] NOTE
mergeNamespace_roclet: no visible global function definition for
  ‘new_roclet’
Undefined global functions or variables:
  new_roclet

2:

checking compiled code ... NOTE
File ‘redland/libs/redland.so’:
  Found no call to: ‘R_useDynamicSymbols’

It is good practice to register native routines and to disable symbol
search.

See ‘Writing portable packages’ in the ‘Writing R Extensions’ manual.

These NOTES appear on most of the builds.

gothub commented 6 years ago

The first problem (new_roclet NOTE), was resolved in commit a5c97142753a374b3acf4f5dff589fd7a2221924 and will be included in the 1.0.17-10 release

gothub commented 6 years ago

The second problem was resolved in April with commit 6958f2ccab22952d0405f85f4dbcfe9c80f5ae96, but after re-reading https://cran.r-project.org/doc/manuals/R-exts.html#Registering-native-routines, I'm realizing that this April commit just prevented the error from being printed, but didn't really implement the local symbol searching as expained in the CRAN docs just mentioned.

The 2018 06 19 commit fully implements the local symbol searching as described/desired by CRAN. We only have one local symbol that this change relates to, the call isnull in the C source util.c. This has been updated so that this function is "registered", so that this function is called as intended and isn't called inadvertently (not explaining this as well as the CRAN docs).

These changes have been made in commit 47879483432139222e9f03db184741595d8b0bdc, but still need to be verified on all the usual testing platforms, R releases.