[Python-modules-commits] r19856 - in packages/python-gd/trunk/debian/patches (2 files)
jump-guest at users.alioth.debian.org
jump-guest at users.alioth.debian.org
Tue Jan 3 05:08:59 UTC 2012
Date: Tuesday, January 3, 2012 @ 05:08:57
Author: jump-guest
Revision: 19856
Detect multiarch paths
Added:
packages/python-gd/trunk/debian/patches/02_detect_libs.diff
Modified:
packages/python-gd/trunk/debian/patches/series
Added: packages/python-gd/trunk/debian/patches/02_detect_libs.diff
===================================================================
--- packages/python-gd/trunk/debian/patches/02_detect_libs.diff (rev 0)
+++ packages/python-gd/trunk/debian/patches/02_detect_libs.diff 2012-01-03 05:08:57 UTC (rev 19856)
@@ -0,0 +1,47 @@
+Description: Detect libraries from multiarch paths
+Author: Julián Moreno Patiño <darkjunix at gmail.com>
+Bug-Debian: http://bugs.debian.org/651726
+Bug-Ubuntu: https://launchpad.net/bugs/901525
+Forwarded: no
+Last-Update: 2012-01-02
+--- a/Setup.py
++++ b/Setup.py
+@@ -36,6 +36,20 @@
+ if lst[i] == itm:
+ del lst[i]
+
++# Add multiarch paths
++
++mult_lib = []
++mult_inc = []
++
++try:
++ cmd = os.popen('dpkg-architecture -qDEB_HOST_MULTIARCH')
++ multiarch_path_component = cmd.readline().strip()
++ mult_lib = ['/usr/lib/'+multiarch_path_component]
++ mult_inc = ['/usr/include/'+multiarch_path_component]
++ cmd.close()
++except:
++ print "Can not import multiarch name"
++
+ # library_dirs option is rather non-portable, but since I am targetting
+ # Unixoid OS's I will just look for the usual suspects.
+
+@@ -43,7 +57,7 @@
+ "/usr/local/lib", "/sw/lib", "/usr/lib",
+ "/usr/lib/X11", "/usr/X11R6/lib",
+ "/opt/gnome/lib",
+-])
++]+mult_lib)
+
+ # include_dirs are also non-portable; same trick here.
+
+@@ -51,7 +65,7 @@
+ "/usr/local/include", "/sw/include", "/usr/include",
+ "/usr/include/X11", "/usr/X11R6/include",
+ "/opt/gnome/include",
+-])
++]+mult_inc)
+
+ # Try to identify our libraries
+
Modified: packages/python-gd/trunk/debian/patches/series
===================================================================
--- packages/python-gd/trunk/debian/patches/series 2012-01-03 05:07:38 UTC (rev 19855)
+++ packages/python-gd/trunk/debian/patches/series 2012-01-03 05:08:57 UTC (rev 19856)
@@ -1,3 +1,3 @@
01_fonts.diff
-02_setup.diff
+02_detect_libs.diff
03_fixgccwarnings.diff
More information about the Python-modules-commits
mailing list