Blame SOURCES/00191-add-RPATH-to-elementtree.patch
|
|
6e8c2f |
diff -up Python-2.7.5/setup.py.orig Python-2.7.5/setup.py
|
|
|
6e8c2f |
--- Python-2.7.5/setup.py.orig 2013-11-07 01:36:18.853604232 +0100
|
|
|
6e8c2f |
+++ Python-2.7.5/setup.py 2013-11-07 01:39:22.163305821 +0100
|
|
|
6e8c2f |
@@ -1483,6 +1483,9 @@ class PyBuildExt(build_ext):
|
|
|
6e8c2f |
# Fredrik Lundh's cElementTree module. Note that this also
|
|
|
6e8c2f |
# uses expat (via the CAPI hook in pyexpat).
|
|
|
6e8c2f |
|
|
|
6e8c2f |
+ # Add an explicit RPATH to _elementtree.so (rhbz#1019345)
|
|
|
6e8c2f |
+ EXPAT_RPATH = '/usr/lib64' if sys.maxint == 0x7fffffffffffffff else '/usr/lib'
|
|
|
6e8c2f |
+
|
|
|
6e8c2f |
if os.path.isfile(os.path.join(srcdir, 'Modules', '_elementtree.c')):
|
|
|
6e8c2f |
define_macros.append(('USE_PYEXPAT_CAPI', None))
|
|
|
6e8c2f |
exts.append(Extension('_elementtree',
|
|
|
6e8c2f |
@@ -1492,6 +1495,7 @@ class PyBuildExt(build_ext):
|
|
|
6e8c2f |
sources = ['_elementtree.c'],
|
|
|
6e8c2f |
depends = ['pyexpat.c'] + expat_sources +
|
|
|
6e8c2f |
expat_depends,
|
|
|
6e8c2f |
+ extra_link_args = ['-Wl,-rpath,%s' % EXPAT_RPATH]
|
|
|
6e8c2f |
))
|
|
|
6e8c2f |
else:
|
|
|
6e8c2f |
missing.append('_elementtree')
|