Skip to content

Commit

Permalink
-O2
Browse files Browse the repository at this point in the history
  • Loading branch information
ripperi committed Sep 27, 2024
1 parent 2ca1300 commit 3e37f41
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions ext/urcrypt/build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ pub fn build(b: *std.Build) void {
"util.c",
},
.flags = &.{
"-O2",
"-fno-sanitize=all",
"-g",
"-Wall",
Expand Down Expand Up @@ -101,6 +102,7 @@ fn libaes_siv(
"aes_siv.c",
},
.flags = &.{
"-O2",
"-fno-sanitize=all",
},
});
Expand Down Expand Up @@ -195,6 +197,7 @@ fn libargon2(
lib.linkLibC();

const flags = .{
"-O2",
"-fno-sanitize=all",
"-Wno-unused-value",
"-Wno-unused-function",
Expand Down Expand Up @@ -267,12 +270,17 @@ fn libblake3(
"blake3_avx2_x86-64_unix.S",
"blake3_avx512_x86-64_unix.S",
}),
.flags = &.{
"-O2",
"-fno-sanitize=all",
},
});
} else {
lib.addCSourceFiles(.{
.root = dep_c.path("blake3"),
.files = &(common_files ++ .{"blake3_neon.c"}),
.flags = &.{
"-O2",
"-fno-sanitize=all",
"-DBLAKE3_USE_NEON=1",
},
Expand Down Expand Up @@ -320,6 +328,7 @@ fn libed25519(
"src/verify.c",
},
.flags = &.{
"-O2",
"-fno-sanitize=all",
"-Wno-unused-result",
},
Expand Down Expand Up @@ -357,6 +366,7 @@ fn libge_additions(
.root = dep_c.path("ge-additions"),
.files = &.{"ge-additions.c"},
.flags = &.{
"-O2",
"-fno-sanitize=all",
"-Werror",
"-pedantic",
Expand Down Expand Up @@ -393,6 +403,7 @@ fn libkeccak_tiny(
.root = dep_c.path("keccak-tiny"),
.files = &.{"keccak-tiny.c"},
.flags = &.{
"-O2",
"-fno-sanitize=all",
"-std=c11",
"-Wextra",
Expand Down

0 comments on commit 3e37f41

Please sign in to comment.