Skip to content

windows: Upload release binary #99

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

Merged
merged 2 commits into from
Apr 10, 2025
Merged
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
10 changes: 7 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,20 +91,24 @@ jobs:
- name: Setup Rust toolchain
run: rustup show

# Build debug library first to fail fast
- name: Build library (Windows)
run: cargo build -p framework_lib --no-default-features --features "windows"

- name: Build Windows tool
run: cargo build -p framework_tool --no-default-features --features "windows"
run: |
cargo build -p framework_tool --no-default-features --features "windows"
cargo build -p framework_tool --no-default-features --features "windows" --release

- name: Check if Windows tool can start
run: cargo run --no-default-features --features "windows" -- --help
run: cargo run --no-default-features --features "windows" -- --help --release

# Upload release build so that vcruntime is statically linked
- name: Upload Windows App
uses: actions/upload-artifact@v4
with:
name: framework_tool.exe
path: target/debug/framework_tool.exe
path: target/release/framework_tool.exe


test:
Expand Down
2 changes: 1 addition & 1 deletion framework_lib/src/chromium_ec/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -916,7 +916,7 @@ impl CrosEc {
let mut request = EcRequestGpioGetV0 { name: [0; MAX_LEN] };

let end = MAX_LEN.min(name.len());
request.name[..end].copy_from_slice(name[..end].as_bytes());
request.name[..end].copy_from_slice(&name.as_bytes()[..end]);

let res = request.send_command(self)?;
Ok(res.val == 1)
Expand Down
1 change: 1 addition & 0 deletions framework_tool/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ path = "../framework_lib"
default-features = false

[build-dependencies]
# Note: Only takes effect in release builds
static_vcruntime = "2.0"