]> granicus.if.org Git - python/commitdiff
Build and install libpython3.so.
authorMartin v. Löwis <martin@v.loewis.de>
Thu, 30 Dec 2010 14:55:47 +0000 (14:55 +0000)
committerMartin v. Löwis <martin@v.loewis.de>
Thu, 30 Dec 2010 14:55:47 +0000 (14:55 +0000)
Makefile.pre.in
configure
configure.in
pyconfig.h.in

index 3a179f6145025dd1d735a7363a0d044d9230b548..323f68dba4ee2c2dcac69643f813ce0f94afde28 100644 (file)
@@ -166,6 +166,7 @@ DIST=               $(DISTFILES) $(DISTDIRS)
 LIBRARY=       @LIBRARY@
 LDLIBRARY=      @LDLIBRARY@
 BLDLIBRARY=     @BLDLIBRARY@
+PY3LIBRARY=     @PY3LIBRARY@
 DLLLIBRARY=    @DLLLIBRARY@
 LDLIBRARYDIR=   @LDLIBRARYDIR@
 INSTSONAME=    @INSTSONAME@
@@ -420,7 +421,7 @@ coverage:
 
 
 # Build the interpreter
-$(BUILDPYTHON):        Modules/python.o $(LIBRARY) $(LDLIBRARY)
+$(BUILDPYTHON):        Modules/python.o $(LIBRARY) $(LDLIBRARY) $(PY3LIBRARY)
        $(LINKCC) $(PY_LDFLAGS) $(LINKFORSHARED) -o $@ Modules/python.o $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST)
 
 platform: $(BUILDPYTHON)
@@ -454,6 +455,9 @@ libpython$(LDVERSION).so: $(LIBRARY_OBJS)
                $(BLDSHARED) -o $@ $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
        fi
 
+libpython3.so: libpython$(LDVERSION).so
+       $(BLDSHARED) -o $@ -Wl,-hl$@ $^
+
 libpython$(VERSION).dylib: $(LIBRARY_OBJS)
         $(CC) -dynamiclib -Wl,-single_module $(PY_LDFLAGS) -undefined dynamic_lookup -Wl,-install_name,$(prefix)/lib/libpython$(VERSION).dylib -Wl,-compatibility_version,$(VERSION) -Wl,-current_version,$(VERSION) -o $@ $(LIBRARY_OBJS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
 
@@ -851,6 +855,9 @@ altbininstall: $(BUILDPYTHON)
                                (cd $(DESTDIR)$(LIBDIR); $(LN) -sf $(INSTSONAME) $(LDLIBRARY)) \
                        fi \
                fi; \
+               if test -n "$(PY3LIBRARY)"; then \
+                       $(INSTALL_SHARED) $(PY3LIBRARY) $(DESTDIR)$(LIBDIR)/$(PY3LIBRARY); \
+               fi; \
        else    true; \
        fi
 
index 284617077685351aa3b0850e7b76563c47668688..8d01bc17f8f109b92658e071e64e2d16e1b9914c 100755 (executable)
--- a/configure
+++ b/configure
@@ -647,6 +647,7 @@ LDVERSION
 RUNSHARED
 INSTSONAME
 LDLIBRARYDIR
+PY3LIBRARY
 BLDLIBRARY
 DLLLIBRARY
 LDLIBRARY
@@ -4710,6 +4711,7 @@ $as_echo "$LIBRARY" >&6; }
 
 
 
+
 LDLIBRARY="$LIBRARY"
 BLDLIBRARY='$(LDLIBRARY)'
 INSTSONAME='$(LDLIBRARY)'
@@ -4906,6 +4908,10 @@ $as_echo "#define Py_ENABLE_SHARED 1" >>confdefs.h
          BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(LDVERSION)'
          RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
          INSTSONAME="$LDLIBRARY".$SOVERSION
+         if test $with_pydebug == no
+         then
+             PY3LIBRARY=libpython3.so
+         fi
           ;;
     Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*)
          LDLIBRARY='libpython$(LDVERSION).so'
@@ -4917,6 +4923,11 @@ $as_echo "#define Py_ENABLE_SHARED 1" >>confdefs.h
                ;;
          esac
          INSTSONAME="$LDLIBRARY".$SOVERSION
+         PY3LIBRARY=libpython3.so
+         if test $with_pydebug == no
+          then
+             PY3LIBRARY=libpython3.so
+         fi
          ;;
     hp*|HP*)
          case `uname -m` in
index fe030b37a7f380166275fc3d7ce745a9d33b676b..dad37c5367cc6dcb761b66d6d20391ef4eb1f390 100644 (file)
@@ -608,6 +608,7 @@ AC_MSG_RESULT($LIBRARY)
 AC_SUBST(LDLIBRARY)
 AC_SUBST(DLLLIBRARY)
 AC_SUBST(BLDLIBRARY)
+AC_SUBST(PY3LIBRARY)
 AC_SUBST(LDLIBRARYDIR)
 AC_SUBST(INSTSONAME)
 AC_SUBST(RUNSHARED)
@@ -737,6 +738,10 @@ if test $enable_shared = "yes"; then
          BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(LDVERSION)'
          RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
          INSTSONAME="$LDLIBRARY".$SOVERSION
+         if test $with_pydebug == no
+         then
+             PY3LIBRARY=libpython3.so
+         fi
           ;;
     Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*)
          LDLIBRARY='libpython$(LDVERSION).so'
@@ -748,6 +753,11 @@ if test $enable_shared = "yes"; then
                ;;
          esac
          INSTSONAME="$LDLIBRARY".$SOVERSION
+         PY3LIBRARY=libpython3.so
+         if test $with_pydebug == no
+          then
+             PY3LIBRARY=libpython3.so
+         fi
          ;;
     hp*|HP*)
          case `uname -m` in
index 9fbcef8ab18c6943ab510e95dc5f39f4e4880df5..f86621b3f80fd8f0eef57154ad654b2aaaf13589 100644 (file)
 /* Define to 1 if you have the `pause' function. */
 #undef HAVE_PAUSE
 
+/* Define if the OS supports pipe2() */
+#undef HAVE_PIPE2
+
 /* Define to 1 if you have the `plock' function. */
 #undef HAVE_PLOCK