nix-super/src
Jade Lovelace 2625e9fb0a Ban building Nix with NDEBUG
When reviewing old PRs, I found that #9997 adds some code to ensure one
particular assert is always present. But, removing asserts isn't
something we do in our own release builds either in the flake here or in
nixpkgs, and is plainly a bad idea that increases support burden,
especially if other distros make bad choices of build flags in their Nix
packaging.

For context, the assert macro in the C standard is defined to do nothing
if NDEBUG is set.

There is no way in our build system to set -DNDEBUG without manually
adding it to CFLAGS, so this is simply a configuration we do not use.
Let's ban it at compile time.

I put this preprocessor directive in src/libutil.cc because it is not
obvious where else to put it, and it seems like the most logical file
since you are not getting a usable nix without it.
2024-03-02 11:22:46 -08:00
..
build-remote Rename hintfmt to HintFmt 2024-02-08 11:58:25 -08:00
libcmd Merge pull request #10010 from 9999years/fix-9941 2024-02-28 14:25:58 +01:00
libexpr Merge pull request #9915 from 9999years/evaluating-attribute-position 2024-02-28 18:11:07 -05:00
libfetchers Merge pull request #10038 from edolstra/tarball-git-cache 2024-02-21 15:47:02 -05:00
libmain :quit in the debugger should quit the whole program 2024-02-20 10:01:13 -08:00
libstore Fix gcc 12 warnings 2024-02-28 22:59:20 +01:00
libutil Ban building Nix with NDEBUG 2024-03-02 11:22:46 -08:00
nix Merge pull request #10090 from bobvanderlinden/profile-error-install-twice 2024-02-29 10:04:08 +01:00
nix-build Get rid of CanonPath::fromCwd 2024-02-08 11:01:41 -05:00
nix-channel Say how many channels were unpacked 2024-02-20 19:17:18 -05:00
nix-collect-garbage Split up util.{hh,cc} 2023-11-05 12:20:02 -05:00
nix-copy-closure Restrict some code to StoreDirConfig 2023-11-04 19:05:36 -04:00
nix-env Avoid creating temporary store object for git over the wire 2024-02-27 11:27:34 -05:00
nix-instantiate Get rid of CanonPath::fromCwd 2024-02-08 11:01:41 -05:00
nix-store Add Git object hashing to the store layer 2024-02-27 11:27:34 -05:00
resolve-system-dependencies Remove FormatOrString and remaining uses of format() 2023-03-02 15:57:54 +01:00
toml11 Replace cpptoml with toml11 2021-12-17 22:03:33 +01:00