Skip to content

Commit

Permalink
build: zig 0.11 compatible [skip skia]
Browse files Browse the repository at this point in the history
  • Loading branch information
Brooooooklyn committed Sep 18, 2023
1 parent e4ad24d commit ba7aec5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
6 changes: 4 additions & 2 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,9 @@ fn main() {
.static_crt(true);
}
"linux" => {
println!("cargo:rustc-cdylib-link-arg=-Wl,--allow-multiple-definition");
if compile_target_arch != "arm" {
println!("cargo:rustc-cdylib-link-arg=-Wl,--allow-multiple-definition");
}
if compile_target_env != "gnu" {
build.cpp_set_stdlib("stdc++");
} else {
Expand Down Expand Up @@ -221,6 +223,6 @@ fn main() {

println!("cargo:rustc-link-search={skia_lib_dir}");
println!("cargo:rustc-link-search={}", &out_dir);
println!("cargo:rustc-link-lib=skshaper");
println!("cargo:rustc-link-lib=static=skshaper");
napi_build::setup();
}
1 change: 1 addition & 0 deletions scripts/release-skia-binary.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ async function download() {
})
for (const lib of LIB) {
const { downloadUrl, binary } = libPath(lib, PLATFORM_NAME, TARGET_TRIPLE)
console.info(`downloading ${downloadUrl} to ${binary}`)
execSync(`curl -J -L -H "Accept: application/octet-stream" ${downloadUrl} -o ${binary}`, {
stdio: 'inherit',
})
Expand Down

1 comment on commit ba7aec5

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark

Benchmark suite Current: ba7aec5 Previous: 969d8eb Ratio
Draw house#skia-canvas 21 ops/sec (±0.59%) 24 ops/sec (±0.06%) 1.14
Draw house#node-canvas 25 ops/sec (±0.71%) 29 ops/sec (±0.29%) 1.16
Draw house#@napi-rs/skia 20 ops/sec (±1.49%) 23 ops/sec (±0.24%) 1.15
Draw gradient#skia-canvas 20 ops/sec (±0.43%) 23 ops/sec (±0.05%) 1.15
Draw gradient#node-canvas 24 ops/sec (±0.39%) 27 ops/sec (±0.31%) 1.13
Draw gradient#@napi-rs/skia 19 ops/sec (±0.94%) 22 ops/sec (±0.31%) 1.16

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.