Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emit bindings for oldrel-1 #244

Closed
wants to merge 21 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 36 additions & 27 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,29 +55,33 @@ jobs:
# - emit-bindings: If 'true', emit bindings. In principle, we choose
# only one stable Rust toolchain per combination of a platform and
# an R version (e.g. Windows and R-release) to emit bindings.
- {os: windows-latest, r: 'release', rust-version: 'stable-msvc', target: 'x86_64-pc-windows-gnu', emit-bindings: 'true'}
- {os: windows-latest, r: 'release', rust-version: 'nightly-msvc', target: 'x86_64-pc-windows-gnu'}
- {os: windows-latest, r: 'devel', rust-version: 'stable-msvc', target: 'x86_64-pc-windows-gnu', emit-bindings: 'true'}
- {os: windows-latest, r: 'release', rust-version: 'stable-gnu', target: 'x86_64-pc-windows-gnu'}
- {os: windows-latest, r: 'oldrel', rust-version: 'stable-msvc', target: 'x86_64-pc-windows-gnu', emit-bindings: 'true'}

- {os: macOS-latest, r: 'release', rust-version: 'nightly'}
- {os: macOS-latest, r: 'devel', rust-version: 'stable', emit-bindings: 'true'}
- {os: macOS-latest, r: 'oldrel', rust-version: 'stable', emit-bindings: 'true'}
- {os: macOS-latest, r: 'release', rust-version: 'stable', emit-bindings: 'true'}
- {os: macOS-latest, r: 'release', rust-version: 'stable', target: 'x86_64-apple-darwin', skip-tests: 'true', emit-bindings: 'true'}


- {os: ubuntu-latest, r: 'release', rust-version: 'nightly'}
- {os: ubuntu-latest, r: 'release', rust-version: 'stable', emit-bindings: 'true'}
- {os: ubuntu-latest, r: 'release', rust-version: 'stable', target: 'aarch64-unknown-linux-gnu', skip-tests: 'true', emit-bindings: 'true'}

- {os: ubuntu-latest, r: 'devel', rust-version: 'stable', emit-bindings: 'true'}
- {os: ubuntu-latest, r: 'devel', rust-version: 'stable', target: 'aarch64-unknown-linux-gnu', skip-tests: 'true', emit-bindings: 'true'}

- {os: ubuntu-latest, r: 'oldrel', rust-version: 'stable', emit-bindings: 'true'}
- {os: ubuntu-latest, r: 'oldrel', rust-version: 'stable', target: 'aarch64-unknown-linux-gnu', skip-tests: 'true', emit-bindings: 'true'}

# - {os: windows-latest, r: 'release', rust-version: 'stable-msvc', target: 'x86_64-pc-windows-gnu', emit-bindings: 'true'}
# - {os: windows-latest, r: 'release', rust-version: 'nightly-msvc', target: 'x86_64-pc-windows-gnu'}
# - {os: windows-latest, r: 'devel', rust-version: 'stable-msvc', target: 'x86_64-pc-windows-gnu', emit-bindings: 'true'}
# - {os: windows-latest, r: 'release', rust-version: 'stable-gnu', target: 'x86_64-pc-windows-gnu'}
# - {os: windows-latest, r: 'oldrel', rust-version: 'stable-msvc', target: 'x86_64-pc-windows-gnu', emit-bindings: 'true'}
# - {os: windows-latest, r: '4.2', rust-version: 'stable-msvc', target: 'x86_64-pc-windows-gnu', emit-bindings: 'true' }

# - {os: macOS-latest, r: 'release', rust-version: 'nightly'}
# - {os: macOS-latest, r: 'devel', rust-version: 'stable', emit-bindings: 'true'}
# - {os: macOS-latest, r: 'oldrel', rust-version: 'stable', emit-bindings: 'true'}
# - {os: macOS-latest, r: 'release', rust-version: 'stable', emit-bindings: 'true'}
# - {os: macOS-latest, r: 'release', rust-version: 'stable', target: 'x86_64-apple-darwin', skip-tests: 'true', emit-bindings: 'true'}
# - {os: macOS-latest, r: '4.2', rust-version: 'stable', emit-bindings: 'true' }
# - {os: macOS-latest, r: '4.2', rust-version: 'stable', target: 'x86_64-apple-darwin', skip-tests: 'true', emit-bindings: 'true'}

# - {os: ubuntu-latest, r: 'release', rust-version: 'nightly'}
# - {os: ubuntu-latest, r: 'release', rust-version: 'stable', emit-bindings: 'true'}
# - {os: ubuntu-latest, r: 'release', rust-version: 'stable', target: 'aarch64-unknown-linux-gnu', skip-tests: 'true', emit-bindings: 'true'}

# - {os: ubuntu-latest, r: 'devel', rust-version: 'stable', emit-bindings: 'true'}
# - {os: ubuntu-latest, r: 'devel', rust-version: 'stable', target: 'aarch64-unknown-linux-gnu', skip-tests: 'true', emit-bindings: 'true'}

# - {os: ubuntu-latest, r: 'oldrel', rust-version: 'stable', emit-bindings: 'true'}
# - {os: ubuntu-latest, r: 'oldrel', rust-version: 'stable', target: 'aarch64-unknown-linux-gnu', skip-tests: 'true', emit-bindings: 'true'}

- {os: ubuntu-latest, r: '4.2', rust-version: 'stable', emit-bindings: 'true' }
# - {os: ubuntu-latest, r: '4.2', rust-version: 'stable', target: 'aarch64-unknown-linux-gnu', skip-tests: 'true', emit-bindings: 'true'}
env:
RSPM: ${{ matrix.config.rspm }}

Expand Down Expand Up @@ -248,11 +252,10 @@ jobs:
runs-on: ubuntu-latest
outputs:
head_commit_message: ${{ steps.get_head_commit_message.outputs.HEAD_COMMIT_MESSAGE }}
# generate_bindings: ${{ contains(steps.get_head_commit_message.outputs.HEAD_COMMIT_MESSAGE, '[generate bindings]') }}
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.ref }}
ref: ${{ github.event.pull_request.head.sha }}
- name: Get Head Commit Message
id: get_head_commit_message
run: echo "HEAD_COMMIT_MESSAGE=$(git show -s --format=%s)" >> "$GITHUB_OUTPUT"
Expand All @@ -261,15 +264,19 @@ jobs:
echo "${{ steps.get_head_commit_message.outputs.HEAD_COMMIT_MESSAGE }}"
echo "${{ contains(steps.get_head_commit_message.outputs.HEAD_COMMIT_MESSAGE, '[generate bindings]') }}"

pr_generated_bindings:
name: Make PR with generated bindings
commit_generated_bindings_to_pr:
name: Commit generated bindings to PR
needs: [test_with_bindgen, check_generate_bindings_flag]
if: ${{ contains(needs.check_generate_bindings_flag.outputs.head_commit_message, '[generate bindings]') }}
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ github.event.pull_request.head.ref }}
repository: ${{ github.event.pull_request.head.repo.full_name }}
- uses: actions/download-artifact@v4
andyquinterom marked this conversation as resolved.
Show resolved Hide resolved

- name: Update bindings
Expand All @@ -292,6 +299,8 @@ jobs:
git commit -m "Update bindings [skip ci]"
- name: Push to PR branch
run: git push
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# Gather the generated bindings and push them to generated_bindings branch.
# If we need to update the bindings, create a pull request from that branch.
Expand Down
24 changes: 13 additions & 11 deletions bindings/bindings-linux-aarch64-R4.5-devel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,9 @@ pub const R_MAJOR: &[u8; 2] = b"4\0";
pub const R_MINOR: &[u8; 4] = b"5.0\0";
pub const R_STATUS: &[u8; 29] = b"Under development (unstable)\0";
pub const R_YEAR: &[u8; 5] = b"2024\0";
pub const R_MONTH: &[u8; 3] = b"05\0";
pub const R_DAY: &[u8; 3] = b"08\0";
pub const R_SVN_REVISION: u32 = 86528;
pub const R_MONTH: &[u8; 3] = b"06\0";
pub const R_DAY: &[u8; 3] = b"11\0";
pub const R_SVN_REVISION: u32 = 86723;
pub const R_GE_definitions: u32 = 13;
pub const R_GE_deviceClip: u32 = 14;
pub const R_GE_group: u32 = 15;
Expand Down Expand Up @@ -1359,6 +1359,8 @@ extern "C" {
pub fn Rf_isEnvironment(s: SEXP) -> Rboolean;
pub fn Rf_isString(s: SEXP) -> Rboolean;
pub fn Rf_isObject(s: SEXP) -> Rboolean;
pub fn MAYBE_SHARED(x: SEXP) -> ::std::os::raw::c_int;
pub fn NO_REFERENCES(x: SEXP) -> ::std::os::raw::c_int;
#[doc = "General Cons Cell Attributes"]
pub fn ATTRIB(x: SEXP) -> SEXP;
pub fn OBJECT(x: SEXP) -> ::std::os::raw::c_int;
Expand Down Expand Up @@ -1393,6 +1395,7 @@ extern "C" {
pub fn SET_VECTOR_ELT(x: SEXP, i: R_xlen_t, v: SEXP) -> SEXP;
pub fn STRING_PTR(x: SEXP) -> *mut SEXP;
pub fn STRING_PTR_RO(x: SEXP) -> *const SEXP;
pub fn VECTOR_PTR_RO(x: SEXP) -> *const SEXP;
pub fn INTEGER_GET_REGION(
sx: SEXP,
i: R_xlen_t,
Expand Down Expand Up @@ -1449,6 +1452,10 @@ extern "C" {
pub fn SET_FORMALS(x: SEXP, v: SEXP);
pub fn SET_BODY(x: SEXP, v: SEXP);
pub fn SET_CLOENV(x: SEXP, v: SEXP);
pub fn R_mkClosure(arg1: SEXP, arg2: SEXP, arg3: SEXP) -> SEXP;
pub fn R_ClosureFormals(arg1: SEXP) -> SEXP;
pub fn R_ClosureBody(arg1: SEXP) -> SEXP;
pub fn R_ClosureEnv(arg1: SEXP) -> SEXP;
#[doc = "Symbol Access Functions"]
pub fn PRINTNAME(x: SEXP) -> SEXP;
pub fn SYMVALUE(x: SEXP) -> SEXP;
Expand All @@ -1459,6 +1466,7 @@ extern "C" {
pub fn ENCLOS(x: SEXP) -> SEXP;
pub fn HASHTAB(x: SEXP) -> SEXP;
pub fn ENVFLAGS(x: SEXP) -> ::std::os::raw::c_int;
pub fn R_ParentEnv(arg1: SEXP) -> SEXP;
#[doc = "Promise Access Functions"]
pub fn PRCODE(x: SEXP) -> SEXP;
pub fn PRENV(x: SEXP) -> SEXP;
Expand Down Expand Up @@ -1603,6 +1611,7 @@ extern "C" {
arg2: ::std::os::raw::c_int,
arg3: ::std::os::raw::c_int,
) -> SEXP;
pub fn Rf_allocLang(arg1: ::std::os::raw::c_int) -> SEXP;
pub fn Rf_allocList(arg1: ::std::os::raw::c_int) -> SEXP;
pub fn Rf_allocS4Object() -> SEXP;
pub fn Rf_allocSExp(arg1: SEXPTYPE) -> SEXP;
Expand Down Expand Up @@ -1712,12 +1721,6 @@ extern "C" {
ce_out: cetype_t,
subst: ::std::os::raw::c_int,
) -> *const ::std::os::raw::c_char;
pub fn Rf_reEnc3(
x: *const ::std::os::raw::c_char,
fromcode: *const ::std::os::raw::c_char,
tocode: *const ::std::os::raw::c_char,
subst: ::std::os::raw::c_int,
) -> *const ::std::os::raw::c_char;
#[doc = "Calling a function with arguments evaluated"]
pub fn R_forceAndCall(e: SEXP, n: ::std::os::raw::c_int, rho: SEXP) -> SEXP;
#[doc = "External pointer interface"]
Expand Down Expand Up @@ -1876,7 +1879,6 @@ extern "C" {
);
pub fn R_Serialize(s: SEXP, ops: R_outpstream_t);
pub fn R_Unserialize(ips: R_inpstream_t) -> SEXP;
pub fn R_SerializeInfo(ips: R_inpstream_t) -> SEXP;
#[doc = "slot management (in attrib.c)"]
pub fn R_do_slot(obj: SEXP, name: SEXP) -> SEXP;
pub fn R_do_slot_assign(obj: SEXP, name: SEXP, value: SEXP) -> SEXP;
Expand Down Expand Up @@ -1907,7 +1909,6 @@ extern "C" {
pub fn R_NewPreciousMSet(arg1: ::std::os::raw::c_int) -> SEXP;
pub fn R_PreserveInMSet(x: SEXP, mset: SEXP);
pub fn R_ReleaseFromMSet(x: SEXP, mset: SEXP);
pub fn R_ReleaseMSet(mset: SEXP, keepSize: ::std::os::raw::c_int);
#[doc = "Shutdown actions"]
pub fn R_dot_Last();
pub fn R_RunExitFinalizers();
Expand Down Expand Up @@ -1936,6 +1937,7 @@ extern "C" {
pub fn Rf_elt(arg1: SEXP, arg2: ::std::os::raw::c_int) -> SEXP;
pub fn Rf_inherits(arg1: SEXP, arg2: *const ::std::os::raw::c_char) -> Rboolean;
pub fn Rf_isArray(arg1: SEXP) -> Rboolean;
pub fn Rf_isDataFrame(arg1: SEXP) -> Rboolean;
pub fn Rf_isFactor(arg1: SEXP) -> Rboolean;
pub fn Rf_isFrame(arg1: SEXP) -> Rboolean;
pub fn Rf_isFunction(arg1: SEXP) -> Rboolean;
Expand Down
24 changes: 13 additions & 11 deletions bindings/bindings-linux-x86_64-R4.5-devel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,9 @@ pub const R_MAJOR: &[u8; 2] = b"4\0";
pub const R_MINOR: &[u8; 4] = b"5.0\0";
pub const R_STATUS: &[u8; 29] = b"Under development (unstable)\0";
pub const R_YEAR: &[u8; 5] = b"2024\0";
pub const R_MONTH: &[u8; 3] = b"05\0";
pub const R_DAY: &[u8; 3] = b"08\0";
pub const R_SVN_REVISION: u32 = 86528;
pub const R_MONTH: &[u8; 3] = b"06\0";
pub const R_DAY: &[u8; 3] = b"12\0";
pub const R_SVN_REVISION: u32 = 86726;
pub const R_GE_definitions: u32 = 13;
pub const R_GE_deviceClip: u32 = 14;
pub const R_GE_group: u32 = 15;
Expand Down Expand Up @@ -1368,6 +1368,8 @@ extern "C" {
pub fn Rf_isEnvironment(s: SEXP) -> Rboolean;
pub fn Rf_isString(s: SEXP) -> Rboolean;
pub fn Rf_isObject(s: SEXP) -> Rboolean;
pub fn MAYBE_SHARED(x: SEXP) -> ::std::os::raw::c_int;
pub fn NO_REFERENCES(x: SEXP) -> ::std::os::raw::c_int;
#[doc = "General Cons Cell Attributes"]
pub fn ATTRIB(x: SEXP) -> SEXP;
pub fn OBJECT(x: SEXP) -> ::std::os::raw::c_int;
Expand Down Expand Up @@ -1402,6 +1404,7 @@ extern "C" {
pub fn SET_VECTOR_ELT(x: SEXP, i: R_xlen_t, v: SEXP) -> SEXP;
pub fn STRING_PTR(x: SEXP) -> *mut SEXP;
pub fn STRING_PTR_RO(x: SEXP) -> *const SEXP;
pub fn VECTOR_PTR_RO(x: SEXP) -> *const SEXP;
pub fn INTEGER_GET_REGION(
sx: SEXP,
i: R_xlen_t,
Expand Down Expand Up @@ -1458,6 +1461,10 @@ extern "C" {
pub fn SET_FORMALS(x: SEXP, v: SEXP);
pub fn SET_BODY(x: SEXP, v: SEXP);
pub fn SET_CLOENV(x: SEXP, v: SEXP);
pub fn R_mkClosure(arg1: SEXP, arg2: SEXP, arg3: SEXP) -> SEXP;
pub fn R_ClosureFormals(arg1: SEXP) -> SEXP;
pub fn R_ClosureBody(arg1: SEXP) -> SEXP;
pub fn R_ClosureEnv(arg1: SEXP) -> SEXP;
#[doc = "Symbol Access Functions"]
pub fn PRINTNAME(x: SEXP) -> SEXP;
pub fn SYMVALUE(x: SEXP) -> SEXP;
Expand All @@ -1468,6 +1475,7 @@ extern "C" {
pub fn ENCLOS(x: SEXP) -> SEXP;
pub fn HASHTAB(x: SEXP) -> SEXP;
pub fn ENVFLAGS(x: SEXP) -> ::std::os::raw::c_int;
pub fn R_ParentEnv(arg1: SEXP) -> SEXP;
#[doc = "Promise Access Functions"]
pub fn PRCODE(x: SEXP) -> SEXP;
pub fn PRENV(x: SEXP) -> SEXP;
Expand Down Expand Up @@ -1612,6 +1620,7 @@ extern "C" {
arg2: ::std::os::raw::c_int,
arg3: ::std::os::raw::c_int,
) -> SEXP;
pub fn Rf_allocLang(arg1: ::std::os::raw::c_int) -> SEXP;
pub fn Rf_allocList(arg1: ::std::os::raw::c_int) -> SEXP;
pub fn Rf_allocS4Object() -> SEXP;
pub fn Rf_allocSExp(arg1: SEXPTYPE) -> SEXP;
Expand Down Expand Up @@ -1721,12 +1730,6 @@ extern "C" {
ce_out: cetype_t,
subst: ::std::os::raw::c_int,
) -> *const ::std::os::raw::c_char;
pub fn Rf_reEnc3(
x: *const ::std::os::raw::c_char,
fromcode: *const ::std::os::raw::c_char,
tocode: *const ::std::os::raw::c_char,
subst: ::std::os::raw::c_int,
) -> *const ::std::os::raw::c_char;
#[doc = "Calling a function with arguments evaluated"]
pub fn R_forceAndCall(e: SEXP, n: ::std::os::raw::c_int, rho: SEXP) -> SEXP;
#[doc = "External pointer interface"]
Expand Down Expand Up @@ -1885,7 +1888,6 @@ extern "C" {
);
pub fn R_Serialize(s: SEXP, ops: R_outpstream_t);
pub fn R_Unserialize(ips: R_inpstream_t) -> SEXP;
pub fn R_SerializeInfo(ips: R_inpstream_t) -> SEXP;
#[doc = "slot management (in attrib.c)"]
pub fn R_do_slot(obj: SEXP, name: SEXP) -> SEXP;
pub fn R_do_slot_assign(obj: SEXP, name: SEXP, value: SEXP) -> SEXP;
Expand Down Expand Up @@ -1916,7 +1918,6 @@ extern "C" {
pub fn R_NewPreciousMSet(arg1: ::std::os::raw::c_int) -> SEXP;
pub fn R_PreserveInMSet(x: SEXP, mset: SEXP);
pub fn R_ReleaseFromMSet(x: SEXP, mset: SEXP);
pub fn R_ReleaseMSet(mset: SEXP, keepSize: ::std::os::raw::c_int);
#[doc = "Shutdown actions"]
pub fn R_dot_Last();
pub fn R_RunExitFinalizers();
Expand Down Expand Up @@ -1945,6 +1946,7 @@ extern "C" {
pub fn Rf_elt(arg1: SEXP, arg2: ::std::os::raw::c_int) -> SEXP;
pub fn Rf_inherits(arg1: SEXP, arg2: *const ::std::os::raw::c_char) -> Rboolean;
pub fn Rf_isArray(arg1: SEXP) -> Rboolean;
pub fn Rf_isDataFrame(arg1: SEXP) -> Rboolean;
pub fn Rf_isFactor(arg1: SEXP) -> Rboolean;
pub fn Rf_isFrame(arg1: SEXP) -> Rboolean;
pub fn Rf_isFunction(arg1: SEXP) -> Rboolean;
Expand Down
2 changes: 1 addition & 1 deletion bindings/bindings-macos-aarch64-R4.3.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* automatically generated by rust-bindgen 0.69.4 */

/* libR-sys version: 0.7.0 */
/* bindgen clang version: Homebrew clang version 17.0.6 */
/* bindgen clang version: Homebrew clang version 18.1.7 */
/* r version: 4.3.3 */

#[repr(C)]
Expand Down
2 changes: 1 addition & 1 deletion bindings/bindings-macos-aarch64-R4.4.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* automatically generated by rust-bindgen 0.69.4 */

/* libR-sys version: 0.7.0 */
/* bindgen clang version: Homebrew clang version 17.0.6 */
/* bindgen clang version: Homebrew clang version 18.1.7 */
/* r version: 4.4.0 */

#[repr(C)]
Expand Down
Loading
Loading