Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: vita-rust/vitasdk-sys
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 80aa52ec1ece48c452e8c25ea95d7dbe944b9f3d
Choose a base ref
..
head repository: vita-rust/vitasdk-sys
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: d6bc3016312910170f368049f271d5f8d3424679
Choose a head ref
Showing with 1,978 additions and 412 deletions.
  1. +68 −0 .github/workflows/build.yml
  2. +3 −4 .github/workflows/update-bindings.yml
  3. +1 −0 Cargo.toml
  4. +1,905 −407 src/bindings.rs
  5. +1 −1 vita-headers
68 changes: 68 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -243,6 +243,74 @@ jobs:
context: Check missing libs
sha: ${{ github.sha }}

# Checks if there's no diff when regenerating bindings
check-bindings:
name: Check bindings
runs-on: ubuntu-latest
needs: install-vitasdk
timeout-minutes: 10
steps:
- name: Set commit status as pending
uses: myrotvorets/set-commit-status-action@v1.1.7
with:
token: ${{ secrets.GITHUB_TOKEN }}
status: pending
context: Check bindings
sha: ${{ github.sha }}

- uses: actions/checkout@v3
with:
submodules: true
- name: Restore vitasdk cache
uses: actions/cache/restore@v3
with:
path: /opt/vitasdk
key: ${{ runner.os }}-vitasdk
fail-on-cache-miss: true

- name: Cache LLVM and Clang
id: cache-llvm
uses: actions/cache@v3
with:
path: |
${{ runner.temp }}/llvm
key: llvm

- name: Install LLVM and Clang
uses: KyleMayes/install-llvm-action@v1
with:
version: ${{ env.LLVM_VERSION }}
directory: ${{ runner.temp }}/llvm
cached: ${{ steps.cache-llvm.outputs.cache-hit }}

- uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
override: true

- name: Regenerate bindings
env:
VITASDK: /opt/vitasdk
# From clang-sys
LIBCLANG_PATH: ${{ runner.temp }}/llvm/lib
LLVM_CONFIG_PATH: ${{ runner.temp }}/llvm/bin/llvm-config
run: |
cargo run -p vitasdk-sys-build-util -- bindgen
- name: Check diff
run: |
git add . && git diff --quiet && git diff --cached --quiet
- name: Set final commit status
uses: myrotvorets/set-commit-status-action@v1.1.7
if: always()
with:
token: ${{ secrets.GITHUB_TOKEN }}
status: ${{ job.status }}
context: Check bindings
sha: ${{ github.sha }}

doc:
name: Doc
runs-on: ubuntu-latest
7 changes: 3 additions & 4 deletions .github/workflows/update-bindings.yml
Original file line number Diff line number Diff line change
@@ -59,8 +59,8 @@ jobs:

- name: Update vita-headers
run: |
echo "VITA_HEADERS_HASH=$(git submodule status | grep vita-headers | cut -d ' ' -f 2)" >> $GITHUB_ENV
git submodule update --recursive --remote vita-headers
echo "VITA_HEADERS_HASH=$(git submodule status | grep vita-headers | cut -d ' ' -f 2)" >> $GITHUB_ENV
- uses: actions-rs/toolchain@v1
with:
@@ -76,15 +76,14 @@ jobs:
LIBCLANG_PATH: ${{ runner.temp }}/llvm/lib
LLVM_CONFIG_PATH: ${{ runner.temp }}/llvm/bin/llvm-config
run: |
cd build-util
cargo run -- bindgen
cargo run -p vitasdk-sys-build-util -- bindgen
- name: Commit and create pull request
id: create-pull-request
uses: peter-evans/create-pull-request@v5
with:
title: Update vita-headers bindings
body: Created by the action at [/.workflows/update-bindings.yml](../tree/main/.workflows/update-bindings.yml)
body: Created by the action at [.github/workflows/update-bindings.yml](../tree/main/.github/workflows/update-bindings.yml)
branch: ${{ env.PR_BRANCH }}
delete-branch: true
commit-message: Update vita-headers to ${{ env.VITA_HEADERS_HASH }}
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -114,6 +114,7 @@ SceIftuForDriver_stub = []
SceIme_stub = []
SceIncomingDialog_stub = []
SceIntrmgrForDriver_stub = []
SceIntrmgrForKernel_363_stub = []
SceIntrmgrForKernel_stub = []
SceIofilemgrForDriver_stub = []
SceIofilemgr_stub = []
Loading