summaryrefslogtreecommitdiffstats
path: root/Makefile.pre.in
diff options
context:
space:
mode:
authorChristian Heimes <christian@python.org>2021-12-06 16:13:53 (GMT)
committerGitHub <noreply@github.com>2021-12-06 16:13:53 (GMT)
commit612e59b53f0c730ce1b881f7c08dc6d49f02c123 (patch)
tree175bec8ab0204e65dbecc6aed19e09265439b9eb /Makefile.pre.in
parent98fac8bc183c113903403793ffe411358ee40d8a (diff)
downloadcpython-612e59b53f0c730ce1b881f7c08dc6d49f02c123.zip
cpython-612e59b53f0c730ce1b881f7c08dc6d49f02c123.tar.gz
cpython-612e59b53f0c730ce1b881f7c08dc6d49f02c123.tar.bz2
bpo-45950: Fix macOS framework builds of _bootstrap_python (GH-29936)
Diffstat (limited to 'Makefile.pre.in')
-rw-r--r--Makefile.pre.in16
1 files changed, 14 insertions, 2 deletions
diff --git a/Makefile.pre.in b/Makefile.pre.in
index 8e6e553..94fc5c3 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -954,9 +954,9 @@ BOOTSTRAP_HEADERS = \
Programs/_bootstrap_python.o: Programs/_bootstrap_python.c $(BOOTSTRAP_HEADERS) $(PYTHON_HEADERS)
-_bootstrap_python: $(LIBRARY_OBJS_OMIT_FROZEN) Programs/_bootstrap_python.o Modules/getpath.o Modules/Setup.local
+_bootstrap_python: $(LIBRARY_OBJS_OMIT_FROZEN) Programs/_bootstrap_python.o Modules/getpath_bootstrap.o Modules/Setup.local
$(LINKCC) $(PY_LDFLAGS_NOLTO) -o $@ $(LIBRARY_OBJS_OMIT_FROZEN) \
- Programs/_bootstrap_python.o Modules/getpath.o $(LIBS) $(MODLIBS) $(SYSLIBS)
+ Programs/_bootstrap_python.o Modules/getpath_bootstrap.o $(LIBS) $(MODLIBS) $(SYSLIBS)
############################################################################
# Deepfreeze targets
@@ -1205,6 +1205,18 @@ Modules/getpath.o: $(srcdir)/Modules/getpath.c Python/frozen_modules/getpath.h M
-DPLATLIBDIR='"$(PLATLIBDIR)"' \
-o $@ $(srcdir)/Modules/getpath.c
+# like getpath.o with additional -DPY_BOOTSTRAP_PYTHON=1
+Modules/getpath_bootstrap.o: $(srcdir)/Modules/getpath.c Python/frozen_modules/getpath.h Makefile $(PYTHON_HEADERS)
+ $(CC) -c $(PY_CORE_CFLAGS) -DPYTHONPATH='"$(PYTHONPATH)"' \
+ -DPREFIX='"$(prefix)"' \
+ -DEXEC_PREFIX='"$(exec_prefix)"' \
+ -DVERSION='"$(VERSION)"' \
+ -DVPATH='"$(VPATH)"' \
+ -DPLATLIBDIR='"$(PLATLIBDIR)"' \
+ -DPY_BOOTSTRAP_PYTHON=1 \
+ -o $@ $(srcdir)/Modules/getpath.c
+
+
Programs/python.o: $(srcdir)/Programs/python.c
$(MAINCC) -c $(PY_CORE_CFLAGS) -o $@ $(srcdir)/Programs/python.c