diff options
author | Victor Stinner <vstinner@redhat.com> | 2019-04-24 22:56:28 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-24 22:56:28 (GMT) |
commit | f4e4703e746067d6630410408d414b11003334d6 (patch) | |
tree | ce2b2d0476b42da4c287dd686dbe499c93d92c33 /configure | |
parent | 888f37bc2826d9ab2cbec6f153e7f58a34785c4a (diff) | |
download | cpython-f4e4703e746067d6630410408d414b11003334d6.zip cpython-f4e4703e746067d6630410408d414b11003334d6.tar.gz cpython-f4e4703e746067d6630410408d414b11003334d6.tar.bz2 |
bpo-36465: Make release and debug ABI compatible (GH-12615)
Release build and debug build are now ABI compatible: the Py_DEBUG
define no longer implies Py_TRACE_REFS define which introduces the
only ABI incompatibility.
A new "./configure --with-trace-refs" build option is now required to
get Py_TRACE_REFS define which adds sys.getobjects() function and
PYTHONDUMPREFS environment variable.
Changes:
* Add ./configure --with-trace-refs
* Py_DEBUG no longer implies Py_TRACE_REFS
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 28 |
1 files changed, 26 insertions, 2 deletions
@@ -814,6 +814,7 @@ with_suffix enable_shared enable_profiling with_pydebug +with_trace_refs with_assertions enable_optimizations with_lto @@ -1500,6 +1501,7 @@ Optional Packages: compiler --with-suffix=.exe set executable suffix --with-pydebug build with Py_DEBUG defined + --with-trace-refs enable tracing references for debugging purpose --with-assertions build with C assertions enabled --with-lto Enable Link Time Optimization in any build. Disabled by default. @@ -6333,8 +6335,30 @@ $as_echo "no" >&6; } fi -# Check for --with-assertions. Py_DEBUG implies assertions, but also changes -# the ABI. This allows enabling assertions without changing the ABI. +# Check for --with-trace-refs +# --with-trace-refs +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-trace-refs" >&5 +$as_echo_n "checking for --with-trace-refs... " >&6; } + +# Check whether --with-trace-refs was given. +if test "${with_trace_refs+set}" = set; then : + withval=$with_trace_refs; +else + with_trace_refs=no +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_trace_refs" >&5 +$as_echo "$with_trace_refs" >&6; } + +if test "$with_trace_refs" = "yes" +then + +$as_echo "#define Py_TRACE_REFS 1" >>confdefs.h + +fi + +# Check for --with-assertions. +# This allows enabling assertions without Py_DEBUG. assertions='false' { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-assertions" >&5 $as_echo_n "checking for --with-assertions... " >&6; } |