From: Trent Nelson Date: Thu, 30 Aug 2012 14:52:38 +0000 (+0000) Subject: Issue #15819: Fix out-of-tree builds from a readonly source. X-Git-Tag: v3.3.1rc1~818^2^2~166 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=e60ee2985cfd5e5057da1a6e25e74cf717792fef;p=thirdparty%2FPython%2Fcpython.git Issue #15819: Fix out-of-tree builds from a readonly source. --- diff --git a/Makefile.pre.in b/Makefile.pre.in index e0356e6c7fb2..681286598d9e 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -229,8 +229,8 @@ IO_OBJS= \ ########################################################################## # Grammar -GRAMMAR_H= $(srcdir)/Include/graminit.h -GRAMMAR_C= $(srcdir)/Python/graminit.c +GRAMMAR_H= Include/graminit.h +GRAMMAR_C= Python/graminit.c GRAMMAR_INPUT= $(srcdir)/Grammar/Grammar @@ -296,9 +296,9 @@ PGENOBJS= $(POBJS) $(PGOBJS) ########################################################################## # AST -AST_H_DIR= $(srcdir)/Include +AST_H_DIR= Include AST_H= $(AST_H_DIR)/Python-ast.h -AST_C_DIR= $(srcdir)/Python +AST_C_DIR= Python AST_C= $(AST_C_DIR)/Python-ast.c AST_ASDL= $(srcdir)/Parser/Python.asdl @@ -665,9 +665,11 @@ Parser/printgrammar.o: $(srcdir)/Parser/printgrammar.c Parser/pgenmain.o: $(srcdir)/Include/parsetok.h $(AST_H): $(AST_ASDL) $(ASDLGEN_FILES) + $(MKDIR_P) $(AST_H_DIR) $(ASDLGEN) -h $(AST_H_DIR) $(AST_ASDL) $(AST_C): $(AST_H) $(AST_ASDL) $(ASDLGEN_FILES) + $(MKDIR_P) $(AST_C_DIR) $(ASDLGEN) -c $(AST_C_DIR) $(AST_ASDL) Python/compile.o Python/symtable.o Python/ast.o: $(GRAMMAR_H) $(AST_H) diff --git a/Misc/NEWS b/Misc/NEWS index dad1622c44d5..127669444402 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -25,6 +25,9 @@ Tests Build ----- +- Issue #15819: Make sure we can build Python out-of-tree from a readonly + source directory. (Somewhat related to Issue #9860.) + Documentation -------------