summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile.pre.in7
1 files changed, 6 insertions, 1 deletions
diff --git a/Makefile.pre.in b/Makefile.pre.in
index 3257bf9..f8bcc92 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -344,7 +344,12 @@ $(LIBRARY): $(LIBRARY_OBJS)
$(RANLIB) $@
libpython$(VERSION).so: $(LIBRARY_OBJS)
- $(LDSHARED) -o $@ $(LIBRARY_OBJS) $(SHLIBS) $(LIBC) $(LIBM)
+ if test $INSTSONAME != $LDLIBRARY; then \
+ $(LDSHARED) -Wl,-soname=$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(SHLIBS) $(LIBC) $(LIBM); \
+ $(LN) -f $(INSTSONAME) $@; \
+ else\
+ $(LDSHARED) -o $@ $(LIBRARY_OBJS) $(SHLIBS) $(LIBC) $(LIBM); \
+ fi
libpython$(VERSION).sl: $(LIBRARY_OBJS)
$(LDSHARED) -o $@ $(LIBRARY_OBJS) $(LIBC) $(LIBM)