From 5ad448df3a8848ed870b1efafefd5166eaacd2c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Mon, 10 Aug 2015 09:10:35 +0200 Subject: [PATCH] enableDebugging: use more suitable gcc flags -ggdb is supposed to provide better symbol information when used with gdb -Og is the recommended optimization level for debugging purposes --- pkgs/stdenv/adapters.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/stdenv/adapters.nix b/pkgs/stdenv/adapters.nix index 480801d0d01..836dedf1cb1 100644 --- a/pkgs/stdenv/adapters.nix +++ b/pkgs/stdenv/adapters.nix @@ -224,7 +224,7 @@ rec { keepDebugInfo = stdenv: stdenv // { mkDerivation = args: stdenv.mkDerivation (args // { dontStrip = true; - NIX_CFLAGS_COMPILE = toString (args.NIX_CFLAGS_COMPILE or "") + " -g -O0"; + NIX_CFLAGS_COMPILE = toString (args.NIX_CFLAGS_COMPILE or "") + " -ggdb -Og"; }); };