summaryrefslogtreecommitdiffstats
path: root/Makefile.pre.in
diff options
context:
space:
mode:
authorJason Tishler <jason@tishler.net>2003-09-04 11:04:06 (GMT)
committerJason Tishler <jason@tishler.net>2003-09-04 11:04:06 (GMT)
commit3076559ea5d36d9795edc32e2fae7949b875d7ef (patch)
treee49bc5e2702644ded35d213f91a6465ada389523 /Makefile.pre.in
parent8ad1dd7df11454abf51354e4f6ddef69167088f9 (diff)
downloadcpython-3076559ea5d36d9795edc32e2fae7949b875d7ef.zip
cpython-3076559ea5d36d9795edc32e2fae7949b875d7ef.tar.gz
cpython-3076559ea5d36d9795edc32e2fae7949b875d7ef.tar.bz2
This patch enables the building of Cygwin Python with a static core
which still supports shared extensions. It takes advantage the latest Cygwin binutils (i.e., 20030901-1) which can export symbols from executables: http://cygwin.com/ml/cygwin-announce/2003-09/msg00002.html Additionally, it finally lays to rest the following mailing list subthread: http://mail.python.org/pipermail/python-list/2002-May/102500.html I tested the patch under Red Hat Linux 8.0 too
Diffstat (limited to 'Makefile.pre.in')
-rw-r--r--Makefile.pre.in12
1 files changed, 8 insertions, 4 deletions
diff --git a/Makefile.pre.in b/Makefile.pre.in
index a91e36c..82073fe 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -379,10 +379,14 @@ $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK): \
$(LN) -fsn Versions/Current/Headers $(PYTHONFRAMEWORKDIR)/Headers
$(LN) -fsn Versions/Current/Resources $(PYTHONFRAMEWORKDIR)/Resources
-# This rule builds the Cygwin Python DLL
-libpython$(VERSION).dll.a: $(LIBRARY_OBJS)
- $(LDSHARED) -Wl,--out-implib=$@ -o $(DLLLIBRARY) $^ \
- $(LIBS) $(MODLIBS) $(SYSLIBS)
+# This rule builds the Cygwin Python DLL and import library if configured
+# for a shared core library; otherwise, this rule is a noop.
+$(DLLLIBRARY) libpython$(VERSION).dll.a: $(LIBRARY_OBJS)
+ if test -n "$(DLLLIBRARY)"; then \
+ $(LDSHARED) -Wl,--out-implib=$@ -o $(DLLLIBRARY) $^ \
+ $(LIBS) $(MODLIBS) $(SYSLIBS); \
+ else true; \
+ fi
oldsharedmods: $(SHAREDMODS)