# Description: Remove duplicate CFLAGS, CPPFLAGS, LDFLAGS by stripping CONFIGURE_* # Submitted by: koobs (r326729) # TODO: Upstream # Description: Fix out-of-tree build as a result of upstream #15819 # Submitted by: rm (r318353) # Issue ID: http://bugs.python.org/issue15819#msg203348 # Description: Run ranlib before installing the library read-only # Submitted by: antoine@ (r350207) # TODO: Upstream --- ./Makefile.pre.in.orig 2014-03-09 19:40:23.000000000 +1100 +++ ./Makefile.pre.in 2014-04-20 23:28:30.086226530 +1000 @@ -70,18 +70,18 @@ OPT= @OPT@ BASECFLAGS= @BASECFLAGS@ BASECPPFLAGS= @BASECPPFLAGS@ -CONFIGURE_CFLAGS= @CFLAGS@ -CONFIGURE_CPPFLAGS= @CPPFLAGS@ -CONFIGURE_LDFLAGS= @LDFLAGS@ +CFLAGS= @CFLAGS@ +CPPFLAGS= @CPPFLAGS@ +LDFLAGS= @LDFLAGS@ # Avoid assigning CFLAGS, LDFLAGS, etc. so users can use them on the # command line to append to these values without stomping the pre-set # values. -PY_CFLAGS= $(BASECFLAGS) $(OPT) $(CONFIGURE_CFLAGS) $(CFLAGS) $(EXTRA_CFLAGS) +PY_CFLAGS= $(BASECFLAGS) $(OPT) $(CFLAGS) $(EXTRA_CFLAGS) # Both CPPFLAGS and LDFLAGS need to contain the shell's value for setup.py to # be able to build extension modules using the directories specified in the # environment variables -PY_CPPFLAGS= $(BASECPPFLAGS) -I. -IInclude -I$(srcdir)/Include $(CONFIGURE_CPPFLAGS) $(CPPFLAGS) -PY_LDFLAGS= $(CONFIGURE_LDFLAGS) $(LDFLAGS) +PY_CPPFLAGS= $(BASECPPFLAGS) -I. -IInclude -I$(srcdir)/Include $(CPPFLAGS) +PY_LDFLAGS= $(LDFLAGS) NO_AS_NEEDED= @NO_AS_NEEDED@ LDLAST= @LDLAST@ SGI_ABI= @SGI_ABI@ @@ -310,21 +310,21 @@ ########################################################################## # AST -AST_H_DIR= Include +AST_H_DIR= $(srcdir)/Include AST_H= $(AST_H_DIR)/Python-ast.h -AST_C_DIR= Python +AST_C_DIR= $(srcdir)/Python AST_C= $(AST_C_DIR)/Python-ast.c AST_ASDL= $(srcdir)/Parser/Python.asdl ASDLGEN_FILES= $(srcdir)/Parser/asdl.py $(srcdir)/Parser/asdl_c.py # XXX Note that a build now requires Python exist before the build starts -ASDLGEN= @ASDLGEN@ $(srcdir)/Parser/asdl_c.py +ASDLGEN= @DISABLE_ASDLGEN@ $(srcdir)/Parser/asdl_c.py ########################################################################## # Python OPCODETARGETS_H= \ - Python/opcode_targets.h + $(srcdir)/Python/opcode_targets.h OPCODETARGETGEN= \ $(srcdir)/Python/makeopcodetargets.py @@ -747,7 +747,7 @@ Objects/setobject.o: $(srcdir)/Objects/stringlib/eq.h $(OPCODETARGETS_H): $(OPCODETARGETGEN_FILES) - $(OPCODETARGETGEN) $(OPCODETARGETS_H) +# $(OPCODETARGETGEN) $(OPCODETARGETS_H) Python/ceval.o: $(OPCODETARGETS_H) $(srcdir)/Python/ceval_gil.h @@ -758,7 +758,7 @@ Objects/typeobject.o: Objects/typeslots.inc Objects/typeslots.inc: $(srcdir)/Include/typeslots.h $(srcdir)/Objects/typeslots.py - $(PYTHON) $(srcdir)/Objects/typeslots.py < $(srcdir)/Include/typeslots.h > Objects/typeslots.inc +# $(PYTHON) $(srcdir)/Objects/typeslots.py < $(srcdir)/Include/typeslots.h > Objects/typeslots.inc ############################################################################ # Header files @@ -1205,8 +1205,8 @@ if test "$(SHLIB_SUFFIX)" = .dll; then \ $(INSTALL_DATA) $(LDLIBRARY) $(DESTDIR)$(LIBPL) ; \ else \ + $(RANLIB) $(LIBRARY) ; \ $(INSTALL_DATA) $(LIBRARY) $(DESTDIR)$(LIBPL)/$(LIBRARY) ; \ - $(RANLIB) $(DESTDIR)$(LIBPL)/$(LIBRARY) ; \ fi; \ else \ echo Skip install of $(LIBRARY) - use make frameworkinstall; \