[Python-modules-commits] r17386 - in packages/ply/trunk/debian/patches (1 file)

eriol-guest at users.alioth.debian.org eriol-guest at users.alioth.debian.org
Thu Jun 9 22:48:26 UTC 2011


    Date: Thursday, June 9, 2011 @ 22:48:25
  Author: eriol-guest
Revision: 17386

Proper fixing _tabversion if ply version is 3.3 or 3.4. Many thanks to Jakub Wilk for pointing out

Modified:
  packages/ply/trunk/debian/patches/02_relax-lex-tabversion-check.patch

Modified: packages/ply/trunk/debian/patches/02_relax-lex-tabversion-check.patch
===================================================================
--- packages/ply/trunk/debian/patches/02_relax-lex-tabversion-check.patch	2011-06-09 21:48:27 UTC (rev 17385)
+++ packages/ply/trunk/debian/patches/02_relax-lex-tabversion-check.patch	2011-06-09 22:48:25 UTC (rev 17386)
@@ -3,14 +3,15 @@
 Forwarded: not-needed
 --- a/ply/lex.py
 +++ b/ply/lex.py
-@@ -222,6 +222,12 @@
+@@ -222,6 +222,13 @@
                  exec("import %s as lextab" % tabfile, env,env)
                  lextab = env['lextab']
  
 +        # python-ply 3.3-1 is shipped by Debian since Squeeze, so
 +        # to not brake packages that were built with wrong
 +        # _tabversion we need to explicitly fix it.
-+        if __version__ in ('3.3', '3.4'):
++        actual_tabversion = float(getattr(lextab,"_tabversion"))
++        if actual_tabversion > 3.2 and __version__ in ('3.3', '3.4'):
 +            setattr(lextab, '_tabversion', '3.2')
 +
          if getattr(lextab,"_tabversion","0.0") != __tabversion__:




More information about the Python-modules-commits mailing list