From 095ff1cb4ab3923ac31fb269df8e390438e492b4 Mon Sep 17 00:00:00 2001 From: Todd Gamblin Date: Tue, 12 May 2015 14:52:41 -0700 Subject: Add debug handler to print a stacktrace on Ctrl-C in debug mode. --- bin/spack | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'bin') diff --git a/bin/spack b/bin/spack index 013acf4db8..7dd3dbabbb 100755 --- a/bin/spack +++ b/bin/spack @@ -93,6 +93,10 @@ def main(): tty.set_debug(args.debug) spack.debug = args.debug + if spack.debug: + import spack.util.debug as debug + debug.register_interrupt_handler() + spack.spack_working_dir = working_dir if args.mock: from spack.packages import PackageDB -- cgit v1.2.3-60-g2f50