diff options
author | Jeffrey Yasskin <jyasskin@google.com> | 2009-09-25 16:46:09 +0000 |
---|---|---|
committer | Jeffrey Yasskin <jyasskin@google.com> | 2009-09-25 16:46:09 +0000 |
commit | e2de471c77ff3baeac8e535fffc28de1e57799a9 (patch) | |
tree | b1e67e5facc6e2860b831e58e3996577ec729776 /Makefile.rules | |
parent | e55e52532c4a76b7ec83e530e3fe3b0bc0b8c00c (diff) | |
download | external_llvm-e2de471c77ff3baeac8e535fffc28de1e57799a9.zip external_llvm-e2de471c77ff3baeac8e535fffc28de1e57799a9.tar.gz external_llvm-e2de471c77ff3baeac8e535fffc28de1e57799a9.tar.bz2 |
This patch causes the --enable-debug-runtime configure flag and the
DEBUG_RUNTIME Makefile variable to pass -g to gcc when building LLVM's objects.
Without this, it's very hard to debug crashes that happen in Release-Asserts
mode but not Debug mode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82775 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'Makefile.rules')
-rw-r--r-- | Makefile.rules | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Makefile.rules b/Makefile.rules index 6cc4bd3..48cb690 100644 --- a/Makefile.rules +++ b/Makefile.rules @@ -313,6 +313,13 @@ ifeq ($(ENABLE_OPTIMIZED),1) CXX.Flags += $(OPTIMIZE_OPTION) $(OmitFramePointer) C.Flags += $(OPTIMIZE_OPTION) $(OmitFramePointer) LD.Flags += $(OPTIMIZE_OPTION) + ifdef DEBUG_RUNTIME + BuildMode := $(BuildMode)+Debug + CXX.Flags += -g + C.Flags += -g + LD.Flags += -g + KEEP_SYMBOLS := 1 + endif else BuildMode := Debug CXX.Flags += -g |