commit | 06fe77a84bd29d51506ab2ff703ae585a6121af2 | [log] [tgz] |
---|---|---|
author | Victor Stinner <vstinner@redhat.com> | Tue Jun 19 18:24:58 2018 +0200 |
committer | GitHub <noreply@github.com> | Tue Jun 19 18:24:58 2018 +0200 |
tree | 4ee6795aeb1826c12c39b6eba1f71e81abf5509a | |
parent | c44d8e5db6fb9d3847c49e9c9718f2b4cf71f506 [diff] [blame] |
bpo-30345: Add -g to LDFLAGS for LTO (GH-7709) Add -g to LDFLAGS when compiling with LTO to get debug symbols.
diff --git a/configure b/configure index 5187c6f..d427703 100755 --- a/configure +++ b/configure
@@ -6427,6 +6427,14 @@ esac ;; esac + + if test "$ac_cv_prog_cc_g" = "yes" + then + # bpo-30345: Add -g to LDFLAGS when compiling with LTO + # to get debug symbols. + LTOFLAGS="$LTOFLAGS -g" + fi + CFLAGS="$CFLAGS $LTOFLAGS" LDFLAGS="$LDFLAGS $LTOFLAGS" fi