mirror of
https://github.com/ziglang/zig.git
synced 2025-02-16 17:40:21 +00:00
compiler: Enable -Werror=date-time for C/C++ code in release builds.
We advertise reproducible builds for release modes, so let's help users achieve that in C/C++ code. Users can still override this manually if they really want.
This commit is contained in:
parent
c37fe4b678
commit
27507ad971
@ -5734,6 +5734,10 @@ pub fn addCCArgs(
|
||||
},
|
||||
}
|
||||
|
||||
if (mod.optimize_mode != .Debug) {
|
||||
try argv.append("-Werror=date-time");
|
||||
}
|
||||
|
||||
if (target_util.supports_fpic(target) and mod.pic) {
|
||||
try argv.append("-fPIC");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user