wush978 / Rcereal

R package provides cereal header files
https://github.com/USCiLab/cereal
Other
13 stars 2 forks source link

Upgrade to cereal 1.3.2 #19

Closed coatless closed 1 month ago

coatless commented 1 year ago

Hi @wush978,

Would it be possible to upgrade the version of cereal to v1.3.2?

Due to new CRAN policies, prior to submitting the updated version of cereal, the following fix would be needed on base64.hpp

sed -i 's|#pragma|// #pragma|' cereal-1.3.2/include/cereal/external/base64.hpp 

If you don't have time or interest in managing the package, I'm more than happy to be a maintainer as it's being used in mlpack's R bindings.

Best,

JJB

stephematician commented 2 months ago

Wush Wu (@wush978) - if you're interested, I can take over maintainer role. I've already updated the package, documentation, and license information here: https://gitlab.com/stephematician/rcereal

The use of update_version should probably be deprecated, as writing files into an R library is not 'best practise'.

I've also incorporated the sed command above as part of a very simple configure script.

The R bindings in mlpack could, in theory, use the updated package without problem (although this was resolved by bundling the cereal headers from mlpack, see resolution to https://github.com/mlpack/mlpack/issues/3486)

stephematician commented 1 month ago

This issue is causing UBSAN to fail when Rcereal is included as a dependency on CRAN (see e.g. https://www.stats.ox.ac.uk/pub/bdr/memtests/gcc-UBSAN/literanger/).

/data/gannet/ripley/R/test-dev/Rcereal/include/cereal/details/static_object.hpp:76:22: runtime error: reference binding to null pointer of type 'const struct bind_to_archives'
coatless commented 1 month ago

@stephematician maybe you could raise a package orphaned note to CRAN and request maintainer status? Especially since the USAN test is now being triggered.

wush978 commented 1 month ago

Hi @coatless, Thank you for bringing the issue to my attention. I will send a patch shortly.

Hi @stephematician, Could you send a PR based on your previous work? Or I can do it by myself.

stephematician commented 1 month ago

Thanks @wush978 - I should be able to send a PR through tomorrow.

wush978 commented 1 month ago

1.3.2 is on CRAN now.