aboutsummaryrefslogtreecommitdiff
path: root/xmake.lua
diff options
context:
space:
mode:
authorStefan Boberg <[email protected]>2023-09-22 15:01:56 +0200
committerGitHub <[email protected]>2023-09-22 15:01:56 +0200
commit8a0bea5a9ce33439a04b566719ace108afcc51df (patch)
tree2d580cdc2eb99d972431971feb0e54f3a9bad98b /xmake.lua
parentadded name to http.sys request queue (#417) (diff)
downloadzen-8a0bea5a9ce33439a04b566719ace108afcc51df.tar.xz
zen-8a0bea5a9ce33439a04b566719ace108afcc51df.zip
added linker/compile options for determinism (#420)
Diffstat (limited to 'xmake.lua')
-rw-r--r--xmake.lua8
1 files changed, 6 insertions, 2 deletions
diff --git a/xmake.lua b/xmake.lua
index 10118d13f..df44dc7e6 100644
--- a/xmake.lua
+++ b/xmake.lua
@@ -76,8 +76,12 @@ if is_os("windows") then
"WIN32_LEAN_AND_MEAN", -- cut down Windows.h
"_WIN32_WINNT=0x0A00"
)
- add_cxxflags("/d1trimfile:$(curdir)\\")
- add_cxxflags("/Zc:preprocessor") -- Enable preprocessor conformance mode
+ -- Make builds more deterministic and portable
+ add_cxxflags("/d1trimfile:$(curdir)\\") -- eliminates the base path from __FILE__ paths
+ add_cxxflags("/experimental:deterministic") -- (more) deterministic compiler output
+ add_ldflags("/PDBALTPATH:%_PDB%") -- deterministic pdb reference in exe
+
+ add_cxxflags("/Zc:preprocessor") -- Enable preprocessor conformance mode
-- add_ldflags("/MAP")
end