build.mk: Add option for debug symbols
authorBen Gamari <ben@smart-cactus.org>
Tue, 21 Feb 2017 00:08:59 +0000 (19:08 -0500)
committerBen Gamari <ben@smart-cactus.org>
Tue, 21 Feb 2017 00:19:46 +0000 (19:19 -0500)
mk/build.mk.sample

index 4175dc7..6bceca3 100644 (file)
@@ -79,6 +79,13 @@ endif
 # working on stage 2 and want to freeze stage 1 and the libraries for
 # a while.
 
+# Enable these if you would like DWARF debugging symbols for your libraries.
+# This is necessary, for instance, to get DWARF stack traces out of programs
+# built by the produced compiler. You must also pass --enable-dwarf-unwind to
+# `configure` to enable the runtime system's builtin unwinding support.
+#GhcLibHcOpts += -g3
+#GhcRtsHcOpts += -g3
+
 # Build the "extra" packages (see ./packages). This enables more tests. See:
 # https://ghc.haskell.org/trac/ghc/wiki/Building/RunningTests/Running#AdditionalPackages
 #BUILD_EXTRA_PKGS=YES