]> git.ipfire.org Git - ipfire-3.x.git/blame - python3/patches/Python-3.1.1-rpath.patch
python3: New package.
[ipfire-3.x.git] / python3 / patches / Python-3.1.1-rpath.patch
CommitLineData
bf250edf
MT
1diff -up Python-3.1.1/Lib/distutils/unixccompiler.py.rpath Python-3.1.1/Lib/distutils/unixccompiler.py
2--- Python-3.1.1/Lib/distutils/unixccompiler.py.rpath 2009-09-04 17:29:34.000000000 -0400
3+++ Python-3.1.1/Lib/distutils/unixccompiler.py 2009-09-04 17:49:54.000000000 -0400
4@@ -141,6 +141,16 @@ class UnixCCompiler(CCompiler):
5 if sys.platform == "cygwin":
6 exe_extension = ".exe"
7
8+ def _fix_lib_args(self, libraries, library_dirs, runtime_library_dirs):
9+ """Remove standard library path from rpath"""
10+ libraries, library_dirs, runtime_library_dirs = super(
11+ self.__class__, self)._fix_lib_args(libraries, library_dirs,
12+ runtime_library_dirs)
13+ libdir = sysconfig.get_config_var('LIBDIR')
14+ if runtime_library_dirs and (libdir in runtime_library_dirs):
15+ runtime_library_dirs.remove(libdir)
16+ return libraries, library_dirs, runtime_library_dirs
17+
18 def preprocess(self, source, output_file=None, macros=None,
19 include_dirs=None, extra_preargs=None, extra_postargs=None):
20 fixed_args = self._fix_compile_args(None, macros, include_dirs)