Comment 8 for bug 738213

Revision history for this message
Dmitry Tantsur (divius) wrote :

I ended up with the following (leaving here for someone with the same trouble):

--- setup.py.orig 2011-03-23 11:30:58.000000000 +0300
+++ setup.py 2011-03-23 11:34:46.000000000 +0300
@@ -349,6 +349,14 @@
         # Ensure that /usr/local is always used
         add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
         add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
+ try:
+ triplet = os.popen('dpkg-architecture -qDEB_HOST_MULTIARCH').readline()[:-1]
+ except EnvironmentError:
+ pass
+ else:
+ add_dir_to_list(self.compiler.library_dirs, '/usr/lib/%s' % triplet)
+ add_dir_to_list(self.compiler.include_dirs, '/usr/include/%s' % triplet)
+

         # Add paths specified in the environment variables LDFLAGS and
         # CPPFLAGS for header and library files.

Apply:
cd Python-2.7.1
patch ./setup.py /path/to/patches/python-setup.py-natty.diff