diff options
author | Trent Nelson <trent@trent.me> | 2012-10-16 12:53:13 (GMT) |
---|---|---|
committer | Trent Nelson <trent@trent.me> | 2012-10-16 12:53:13 (GMT) |
commit | cd02b3f781b0a0d545bffb47741a2f5bb37c9a41 (patch) | |
tree | a42cb2b46823328c22b3065e1c4442c02ff78cab /configure | |
parent | b16269e375ec3b9dd656d64469f3810b4a0eec81 (diff) | |
parent | 4d4ec6502d6aec31284cf2f68d81c64fcedb1049 (diff) | |
download | cpython-cd02b3f781b0a0d545bffb47741a2f5bb37c9a41.zip cpython-cd02b3f781b0a0d545bffb47741a2f5bb37c9a41.tar.gz cpython-cd02b3f781b0a0d545bffb47741a2f5bb37c9a41.tar.bz2 |
Merge issue #15819: additional fixes for out-of-tree builds from read-only src.
Specifically, make sure the 'Object', 'Python' and 'Include' directories
in the build directory take precedence over the source directory if we're
an out-of-tree build.
Fix typeslots.inc so that it gets generated into the build directory.
In addition, for 3.3, make sure importlib.h gets generated into the
build directory.
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 20 |
1 files changed, 20 insertions, 0 deletions
@@ -714,6 +714,8 @@ HAS_HG HGBRANCH HGTAG HGVERSION +BASECPPFLAGS +BUILDDIR target_alias host_alias build_alias @@ -2719,6 +2721,24 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu +BUILDDIR="`pwd`" + + +if test "$srcdir" != "$BUILDDIR"; then + # If we're building out-of-tree, we need to make sure the following + # resources get picked up before their $srcdir counterparts. + # Objects/ -> typeslots.inc + # Include/ -> Python-ast.h, graminit.h + # Python/ -> importlib.h + # (A side effect of this is that these resources will automatically be + # regenerated when building out-of-tree, regardless of whether or not + # the $srcdir counterpart is up-to-date. This is an acceptable trade + # off.) + BASECPPFLAGS="-IObjects -IInclude -IPython" +else + BASECPPFLAGS="" +fi + |