From 44c933da5d8e364d6cd755071f629c05444191df Mon Sep 17 00:00:00 2001 From: psykose Date: Sat, 6 May 2023 19:02:47 +0000 Subject: [PATCH] default.conf: enable _GLIBCXX_ASSERTIONS these have a slight runtime hit (like fortify-source), but help find bugs early, by making programs crash on invariants that would corrupt memory and lead to hard to debug crashes/bugs later. --- default.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/default.conf b/default.conf index 951a82f..8141af5 100644 --- a/default.conf +++ b/default.conf @@ -1,5 +1,5 @@ export CFLAGS="-Os -Wformat -Werror=format-security" -export CXXFLAGS="-Os -Wformat -Werror=format-security" +export CXXFLAGS="-Os -Wformat -Werror=format-security -D_GLIBCXX_ASSERTIONS=1" export LDFLAGS="-Wl,--as-needed,-O1,--sort-common" export GOFLAGS="-buildmode=pie -modcacherw -trimpath -buildvcs=false" # Do note that these should work with at least GDC and LDC