satip-axe/patches/python3-makefile.patch
2018-09-25 11:16:42 +02:00

58 lines
1.9 KiB
Diff

--- Makefile.orig 2018-09-25 11:01:33.853198226 +0200
+++ Makefile 2018-09-25 11:07:57.416371544 +0200
@@ -587,7 +587,7 @@
*) quiet="";; \
esac; \
$(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' \
- _TCLTK_INCLUDES='$(TCLTK_INCLUDES)' _TCLTK_LIBS='$(TCLTK_LIBS)' \
+ _TCLTK_INCLUDES='$(TCLTK_INCLUDES)' _TCLTK_LIBS='$(TCLTK_LIBS)' EXT_SUFFIX='$(EXT_SUFFIX)' \
$(PYTHON_FOR_BUILD) $(srcdir)/setup.py $$quiet build
# Build static library
@@ -697,6 +697,8 @@
############################################################################
# Importlib
+FREEZE_IMPORTLIB ?= ./Programs/_freeze_importlib
+
Programs/_freeze_importlib.o: Programs/_freeze_importlib.c Makefile
Programs/_freeze_importlib: Programs/_freeze_importlib.o $(LIBRARY_OBJS_OMIT_FROZEN)
@@ -706,12 +708,12 @@
regen-importlib: Programs/_freeze_importlib
# Regenerate Python/importlib_external.h
# from Lib/importlib/_bootstrap_external.py using _freeze_importlib
- ./Programs/_freeze_importlib \
+ $(FREEZE_IMPORTLIB) \
$(srcdir)/Lib/importlib/_bootstrap_external.py \
$(srcdir)/Python/importlib_external.h
# Regenerate Python/importlib.h from Lib/importlib/_bootstrap.py
# using _freeze_importlib
- ./Programs/_freeze_importlib \
+ $(FREEZE_IMPORTLIB) \
$(srcdir)/Lib/importlib/_bootstrap.py \
$(srcdir)/Python/importlib.h
@@ -778,11 +780,8 @@
$(IO_OBJS): $(IO_H)
-$(PGEN): $(PGENOBJS)
- $(CC) $(OPT) $(PY_LDFLAGS) $(PGENOBJS) $(LIBS) -o $(PGEN)
-
.PHONY: regen-grammar
-regen-grammar: $(PGEN)
+regen-grammar:
# Regenerate Include/graminit.h and Python/graminit.c
# from Grammar/Grammar using pgen
@$(MKDIR_P) Include
@@ -1625,7 +1624,7 @@
rm -rf $(COVERAGE_REPORT)
clobber: clean profile-removal
- -rm -f $(BUILDPYTHON) $(PGEN) $(LIBRARY) $(LDLIBRARY) $(DLLLIBRARY) \
+ -rm -f $(BUILDPYTHON) $(LIBRARY) $(LDLIBRARY) $(DLLLIBRARY) \
tags TAGS \
config.cache config.log pyconfig.h Modules/config.c
-rm -rf build platform