From 243bb87db0a793dbc6c3b11226244816cc3d9937 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20R=C3=B8nne=20Petersen?= Date: Sun, 28 Jul 2024 15:41:35 +0200 Subject: [PATCH 1/2] musl: Build with `-fno-strict-aliasing` like upstream. --- src/musl.zig | 1 + 1 file changed, 1 insertion(+) diff --git a/src/musl.zig b/src/musl.zig index 96caf3d1932d..8ab05ee28c5d 100644 --- a/src/musl.zig +++ b/src/musl.zig @@ -395,6 +395,7 @@ fn addCcArgs( // Musl adds these args to builds with gcc but clang does not support them. //"-fexcess-precision=standard", //"-frounding-math", + "-fno-strict-aliasing", "-Wa,--noexecstack", "-D_XOPEN_SOURCE=700", From b03a04c7fca587af0f1caf59881def3c91596728 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20R=C3=B8nne=20Petersen?= Date: Sun, 28 Jul 2024 15:42:02 +0200 Subject: [PATCH 2/2] musl: Build with `-fexcess-precision=standard -frounding-math`. Clang supports these now. --- src/musl.zig | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/musl.zig b/src/musl.zig index 8ab05ee28c5d..acbb159cb0ae 100644 --- a/src/musl.zig +++ b/src/musl.zig @@ -392,9 +392,8 @@ fn addCcArgs( try args.appendSlice(&[_][]const u8{ "-std=c99", "-ffreestanding", - // Musl adds these args to builds with gcc but clang does not support them. - //"-fexcess-precision=standard", - //"-frounding-math", + "-fexcess-precision=standard", + "-frounding-math", "-fno-strict-aliasing", "-Wa,--noexecstack", "-D_XOPEN_SOURCE=700",