-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Submodule, api_gen rework * Renormalize line endings before `git diff` * ci: Work around `regex` compilation failure in MSRV check * Cleanup
- Loading branch information
Showing
3,143 changed files
with
6,305 additions
and
425,647 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,5 +28,27 @@ jobs: | |
- name: Generate minimal-version dependencies | ||
run: cargo -Zminimal-versions generate-lockfile | ||
- uses: dtolnay/[email protected] | ||
- name: Upgrade to [email protected] | ||
# Workaround for: | ||
# https://github.com/rust-lang/regex/issues/931 | ||
# https://github.com/rust-lang/rust-bindgen/pull/2714 | ||
run: cargo update -p regex --precise 1.5.1 | ||
- name: Cargo check | ||
run: cargo check --workspace --all-targets | ||
|
||
generate: | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Checkout submodule | ||
# Manually update submodules with --checkout because they are configured with update=none and will be skipped otherwise | ||
run: git submodule update --recursive --init --force --checkout | ||
- name: Run generator | ||
run: cargo r -p api_gen | ||
- name: Normalize line endings | ||
run: | | ||
git add --renormalize -u | ||
git reset | ||
- name: Diff autogen result | ||
shell: bash | ||
run: test -z "$(git status --porcelain)" || (echo "::error::Generated files are different, please regenerate with cargo run -p api_gen!"; git diff; false) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
[submodule "ADLX"] | ||
path = vendor/ADLX | ||
url = https://github.com/GPUOpen-LibrariesAndSDKs/ADLX | ||
depth = 1 | ||
update = none |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
[package] | ||
name = "api_gen" | ||
version = "0.0.0" | ||
edition = "2021" | ||
publish = false | ||
|
||
[dependencies] | ||
bindgen = "0.69.2" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
use std::path::Path; | ||
|
||
fn main() { | ||
let crate_root = Path::new(env!("CARGO_MANIFEST_DIR")); | ||
|
||
let header_path = crate_root.join("wrapper.h"); | ||
|
||
let bindings = bindgen::Builder::default() | ||
.header(header_path.to_string_lossy()) | ||
.clang_arg(format!( | ||
"-I{}", | ||
crate_root.join("../vendor/ADLX/SDK/Include/").display() | ||
)) | ||
.allowlist_item("I?ADLX\\w+") | ||
.generate() | ||
.expect("failed to generate adlx bindings"); | ||
|
||
bindings | ||
.write_to_file(crate_root.join("../src/ffi.rs")) | ||
.expect("Couldn't write bindings!"); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#include <ADLX.h> | ||
|
||
// Interfaces to generate bindings for | ||
#include <ISystem1.h> | ||
#include <IPerformanceMonitoring.h> | ||
#include <IPerformanceMonitoring1.h> |
This file was deleted.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.