summaryrefslogtreecommitdiff
path: root/python3
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2013-04-19 15:33:57 +0200
committerMichael Stahl <mstahl@redhat.com>2013-04-19 16:16:34 +0200
commitb865ff3d75a4611eaefe1f35b0dc9c7d9256f1ff (patch)
tree152ea51574bbd96d1be60ad617cd75dc36d6ae86 /python3
parent9dd52eb86a9122e34c307a9160ae3ccd5706c94e (diff)
python3: put an RPATH into python binary ...
... and get rid of LD_LIBRARY_PATH hack in wrapper shell script. Change-Id: I7d91c6086460504d656de7b018087264165f396b
Diffstat (limited to 'python3')
-rw-r--r--python3/UnpackedTarball_python3.mk6
-rw-r--r--python3/python-3.3.0-elf-rpath.patch.113
2 files changed, 19 insertions, 0 deletions
diff --git a/python3/UnpackedTarball_python3.mk b/python3/UnpackedTarball_python3.mk
index 696c8691106d..0d5fce5e6236 100644
--- a/python3/UnpackedTarball_python3.mk
+++ b/python3/UnpackedTarball_python3.mk
@@ -40,4 +40,10 @@ $(eval $(call gb_UnpackedTarball_add_patches,python3,\
))
endif
+ifneq ($(filter DRAGONFLY FREEBSD LINUX NETBSD OPENBSD SOLARIS,$(OS)),)
+$(eval $(call gb_UnpackedTarball_add_patches,python3,\
+ python3/python-3.3.0-elf-rpath.patch.1 \
+))
+endif
+
# vim: set noet sw=4 ts=4:
diff --git a/python3/python-3.3.0-elf-rpath.patch.1 b/python3/python-3.3.0-elf-rpath.patch.1
new file mode 100644
index 000000000000..0007d6b2e71e
--- /dev/null
+++ b/python3/python-3.3.0-elf-rpath.patch.1
@@ -0,0 +1,13 @@
+set RPATH (only to be used on ELF platforms)
+
+--- python3/Makefile.pre.in 2013-04-19 15:08:43.637715422 +0200
++++ python3/Makefile.pre.in 2013-04-19 15:07:32.685711138 +0200
+@@ -464,7 +464,7 @@
+
+ # Build the interpreter
+ $(BUILDPYTHON): Modules/python.o $(LIBRARY) $(LDLIBRARY) $(PY3LIBRARY)
+- $(LINKCC) $(PY_LDFLAGS) $(LINKFORSHARED) -o $@ Modules/python.o $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST)
++ $(LINKCC) $(PY_LDFLAGS) $(LINKFORSHARED) -o $@ Modules/python.o $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST) -Wl,-rpath,\$$ORIGIN
+
+ platform: $(BUILDPYTHON) $(SYSCONFIGDATA)
+ $(RUNSHARED) $(PYTHON_FOR_BUILD) -c 'import sys ; from sysconfig import get_platform ; print(get_platform()+"-"+sys.version[0:3])' >platform