Closed swihart closed 2 years ago
Luckily I've hammered this out in gnlrim. See this issue for the stream of consciousness journey of learning and recoding.
So here's how we will tackle it:
rhub::check(platform = "debian-clang-devel")
call_R
#include <Rinternals.h>
SEXP romberg_sexp(SEXP fcn, SEXP a, SEXP b, SEXP len, SEXP eps, SEXP pts, SEXP max, SEXP err, SEXP envir);
extern void romberg_sexp(void *, void *, void *, void *, void *, void *, void *, void *, void *, void *);
usethis::use_build_ignore("./src/romberg.c")
usethis::use_build_ignore("./old_code/")
usethis::use_build_ignore("romberg.c")
romberg_c
devtools::submit_cran()
rmutil
needed a little help with registering things:
Section 5.4 Registering native routines as in the R-manual:
R-news example on page 20
v1.1.4 is on CRAN.
Luckily I've hammered this out in gnlrim. See this issue for the stream of consciousness journey of learning and recoding.
So here's how we will tackle it:
rhub::check(platform = "debian-clang-devel")
to see warnings aboutcall_R
#include <Rinternals.h>
at the top so it knows SEXP typeSEXP romberg_sexp(SEXP fcn, SEXP a, SEXP b, SEXP len, SEXP eps, SEXP pts, SEXP max, SEXP err, SEXP envir);
instead ofextern void romberg_sexp(void *, void *, void *, void *, void *, void *, void *, void *, void *, void *);
usethis::use_build_ignore("./src/romberg.c")
add romberg.c to .Rbuildignore if you want to leave it in repo but want to keep off CRANactually, just remove/delete romberg.c since devtools doesn't respect .Rbuildignore(this works but I want to keep historical code nearby)(doesn't pass pre-checks as per CRAN)usethis::use_build_ignore("./old_code/")
to ignore whole subdirectory and put romberg.c into ./old_code/srcusethis::use_build_ignore("romberg.c")
after puting romberg.c into "./"romberg_c
entryrhub::check(platform = "debian-clang-devel")
successful w/out warnings aboutcall_R
devtools::submit_cran()
rmutil
.