[Libreoffice-commits] core.git: 3 commits - external/coinmp external/liblangtag external/python3 pyuno/README

Michael Stahl mstahl at redhat.com
Wed Sep 21 22:03:41 UTC 2016


 external/coinmp/ExternalProject_coinmp.mk         |    1 +
 external/liblangtag/UnpackedTarball_langtag.mk    |    1 +
 external/liblangtag/langtag-libtool-rpath.patch.0 |   12 ++++++++++++
 external/python3/ExternalPackage_python3.mk       |    5 ++---
 external/python3/UnpackedTarball_python3.mk       |    2 +-
 external/python3/python-3.3.3-aix.patch.1         |    7 ++-----
 external/python3/python-3.3.3-elf-rpath.patch.1   |   14 ++++++++++++++
 pyuno/README                                      |    2 +-
 8 files changed, 34 insertions(+), 10 deletions(-)

New commits:
commit b078e0d638514b298616838fae090b8294bac32f
Author: Michael Stahl <mstahl at redhat.com>
Date:   Wed Sep 21 23:42:52 2016 +0200

    python3: put a RPATH into libpython3.so
    
    libpython3.so is the "ABI compatible" wrapper library around
    libpython3.5m.so - it is not actually used by anything in LO right now,
    but let's ensure it has RPATH $ORIGIN just in case.
    
    This revealed that the AIX patch in python3 accidentally changed the
    SONAME of libpython3.5m.so from upstream's libpython3.5m.so.1.0
    on ELF platforms, because the SONAME variable was set in the shell
    command but read as a make variable in the next line, which is actually
    evaluated earlier.
    
    So rename a few files in packages to use the upstream SONAME.
    
    Change-Id: I3611f75eee62b0993b853230521a2fa41ac5cd9c

diff --git a/external/python3/ExternalPackage_python3.mk b/external/python3/ExternalPackage_python3.mk
index 347b13a..045b4c1 100644
--- a/external/python3/ExternalPackage_python3.mk
+++ b/external/python3/ExternalPackage_python3.mk
@@ -45,9 +45,8 @@ $(eval $(call gb_ExternalPackage_add_file,python3,$(LIBO_BIN_FOLDER)/python$(PYT
 else
 $(eval $(call gb_ExternalPackage_add_file,python3,$(LIBO_BIN_FOLDER)/python.bin,python))
 $(eval $(call gb_ExternalPackage_add_file,python3,$(LIBO_BIN_FOLDER)/libpython$(PYTHON_VERSION_MAJOR).so,libpython$(PYTHON_VERSION_MAJOR).so))
-$(eval $(call gb_ExternalPackage_add_file,python3,$(LIBO_BIN_FOLDER)/libpython$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)m.so,libpython$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)m.so))
-$(eval $(call gb_ExternalPackage_add_file,python3,$(LIBO_BIN_FOLDER)/libpython$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)m.so-gdb.py,Tools/gdb/libpython.py))
-# versioned lib/libpython3.3m.so.1.0 appears to be unnecessary?
+$(eval $(call gb_ExternalPackage_add_file,python3,$(LIBO_BIN_FOLDER)/libpython$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)m.so.1.0,libpython$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)m.so))
+$(eval $(call gb_ExternalPackage_add_file,python3,$(LIBO_BIN_FOLDER)/libpython$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)m.so.1.0-gdb.py,Tools/gdb/libpython.py))
 
 # Unfortunately the python build system does not allow to explicitly enable or
 # disable these, it just tries to build them and then prints which did not
diff --git a/external/python3/UnpackedTarball_python3.mk b/external/python3/UnpackedTarball_python3.mk
index 0c471f0..a70005b 100644
--- a/external/python3/UnpackedTarball_python3.mk
+++ b/external/python3/UnpackedTarball_python3.mk
@@ -17,7 +17,7 @@ $(eval $(call gb_UnpackedTarball_fix_end_of_line,python3,\
 
 $(eval $(call gb_UnpackedTarball_add_patches,python3,\
 	external/python3/i100492-freebsd.patch.1 \
-	external/python3/python-3.3.3-aix.patch.1 \
+	$(if $(filter AIX,$(OS)),external/python3/python-3.3.3-aix.patch.1) \
 	external/python3/python-3.3.0-darwin.patch.1 \
 	external/python3/python-3.3.0-msvc-disable.patch.1 \
 	external/python3/python-3.3.0-ssl.patch.1 \
diff --git a/external/python3/python-3.3.3-aix.patch.1 b/external/python3/python-3.3.3-aix.patch.1
index 1387e9c..571d69a 100644
--- a/external/python3/python-3.3.3-aix.patch.1
+++ b/external/python3/python-3.3.3-aix.patch.1
@@ -103,15 +103,12 @@ diff -ru python3.orig/configure.ac python3/configure.ac
 diff -ru python3.orig/Makefile.pre.in python3/Makefile.pre.in
 --- python3.orig/Makefile.pre.in	2015-07-05 18:50:07.000000000 +0200
 +++ python3/Makefile.pre.in	2015-07-26 17:34:00.386488960 +0200
-@@ -598,14 +598,20 @@
+@@ -598,14 +598,17 @@
  
  libpython$(LDVERSION).so: $(LIBRARY_OBJS)
  	if test $(INSTSONAME) != $(LDLIBRARY); then \
 -		$(BLDSHARED) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
-+		if [ "`echo $(MACHDEP) | sed 's/^\(...\).*/\1/'`" != "aix" ]; then \
-+			SONAME="-Wl,-h$(INSTSONAME)"; \
-+		fi; \
-+		$(BLDSHARED) $(SONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
++		$(BLDSHARED) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
  		$(LN) -f $(INSTSONAME) $@; \
  	else \
  		$(BLDSHARED) -o $@ $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
diff --git a/external/python3/python-3.3.3-elf-rpath.patch.1 b/external/python3/python-3.3.3-elf-rpath.patch.1
index 945f7a5..029d98c 100644
--- a/external/python3/python-3.3.3-elf-rpath.patch.1
+++ b/external/python3/python-3.3.3-elf-rpath.patch.1
@@ -1,5 +1,7 @@
 set RPATH (only to be used on ELF platforms)
 
+(currently nothing in LO actually links libpython3.so)
+
 diff -ru python3.orig/Makefile.pre.in python3/Makefile.pre.in
 --- python3.orig/Makefile.pre.in	2015-07-26 20:29:07.126194320 +0200
 +++ python3/Makefile.pre.in	2015-07-26 20:37:21.814227530 +0200
@@ -12,3 +14,15 @@ diff -ru python3.orig/Makefile.pre.in python3/Makefile.pre.in
  
  platform: $(BUILDPYTHON) pybuilddir.txt
  	$(RUNSHARED) $(PYTHON_FOR_BUILD) -c 'import sys ; from sysconfig import get_platform ; print(get_platform()+"-"+sys.version[0:3])' >platform
+--- python3.orig/Makefile.pre.in	2015-07-05 18:50:07.000000000 +0200
++++ python3/Makefile.pre.in	2015-07-26 17:34:00.386488960 +0200
+@@ -607,7 +607,7 @@
+ 	fi
+ 
+ libpython3.so:	libpython$(LDVERSION).so
+-	$(BLDSHARED) $(NO_AS_NEEDED) -o $@ -Wl,-h$@ $^
++	$(BLDSHARED) $(NO_AS_NEEDED) -o $@ -Wl,-h$@ $^ -Wl,-rpath,\$$ORIGIN
+ 
+ libpython$(LDVERSION).dylib: $(LIBRARY_OBJS)
+ 	 $(CC) -dynamiclib -Wl,-single_module $(PY_LDFLAGS) -undefined dynamic_lookup -Wl,-install_name,$(prefix)/lib/libpython$(LDVERSION).dylib -Wl,-compatibility_version,$(VERSION) -Wl,-current_version,$(VERSION) -o $@ $(LIBRARY_OBJS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
+
diff --git a/pyuno/README b/pyuno/README
index a0a4002..26f929a 100644
--- a/pyuno/README
+++ b/pyuno/README
@@ -8,7 +8,7 @@ Then you'll start to see your exceptions on the console instead of them getting
 lost at the UNO interface.
 
 Python also comes with a gdb script
-libpython$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)m.so-gdb.py
+libpython$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)m.so.1.0-gdb.py
 that is copied to instdir and will be auto-loaded by gdb;
 it provides commands like "py-bt" to get a python-level backtrace,
 and "py-print" to print python variables.
commit 3d31cf66bb0c3f628cd175b50373f746ec45645f
Author: Michael Stahl <mstahl at redhat.com>
Date:   Wed Sep 21 22:40:44 2016 +0200

    coinmp: no need for bzip2 library
    
    Change-Id: I1f5115defa3619f13ce00d64d5532d2b08dc2ccb

diff --git a/external/coinmp/ExternalProject_coinmp.mk b/external/coinmp/ExternalProject_coinmp.mk
index 714171b..c2090d7 100644
--- a/external/coinmp/ExternalProject_coinmp.mk
+++ b/external/coinmp/ExternalProject_coinmp.mk
@@ -29,6 +29,7 @@ $(call gb_ExternalProject_get_state_target,coinmp,build) :
 		./configure COIN_SKIP_PROJECTS="Data/Sample" \
 			$(if $(CROSS_COMPILING),--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)) \
 			$(if $(DISABLE_DYNLOADING),--disable-shared) \
+			--disable-bzlib \
 			$(if $(filter MACOSX,$(OS)),--prefix=/@.__________________________________________________OOO) \
 			--enable-dependency-linking F77=unavailable \
 			$(if $(filter LINUX,$(OS)), \
commit ecd5d49dc30d11845ccc1a14e26bf37d73959463
Author: Michael Stahl <mstahl at redhat.com>
Date:   Wed Sep 21 22:19:31 2016 +0200

    liblangtag: prevent libtool from adding annoying stuff to RPATH
    
    Change-Id: I699e84614f09c6e1edad5bcd51eae73d1ab8123f

diff --git a/external/liblangtag/UnpackedTarball_langtag.mk b/external/liblangtag/UnpackedTarball_langtag.mk
index 69bc045..47505f8 100644
--- a/external/liblangtag/UnpackedTarball_langtag.mk
+++ b/external/liblangtag/UnpackedTarball_langtag.mk
@@ -32,6 +32,7 @@ endif
 endif
 
 $(eval $(call gb_UnpackedTarball_add_patches,langtag, \
+	$(if $(SYSTEM_LIBXML),,external/liblangtag/langtag-libtool-rpath.patch.0) \
     external/liblangtag/clang-cl.patch.0 \
 ))
 
diff --git a/external/liblangtag/langtag-libtool-rpath.patch.0 b/external/liblangtag/langtag-libtool-rpath.patch.0
new file mode 100644
index 0000000..905516f
--- /dev/null
+++ b/external/liblangtag/langtag-libtool-rpath.patch.0
@@ -0,0 +1,12 @@
+Prevent libtool from adding annoying stuff to RPATH
+
+--- configure
++++ configure
+@@ -10730,6 +10730,7 @@
+       else
+         ld_shlibs=no
+       fi
++hardcode_libdir_flag_spec=
+       ;;
+ 
+     netbsd*)


More information about the Libreoffice-commits mailing list