diff --git a/cocci-pythondetect.diff b/cocci-pythondetect.diff new file mode 100644 index 0000000..0401919 --- /dev/null +++ b/cocci-pythondetect.diff @@ -0,0 +1,17 @@ +--- + configure | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +Index: coccinelle-0.2.5-rc2/configure +=================================================================== +--- coccinelle-0.2.5-rc2.orig/configure ++++ coccinelle-0.2.5-rc2/configure +@@ -198,7 +198,7 @@ We need 3.XX", + if($python) { + if(check_config( + "python --version 2>&1 |", +- "Python 2\.[567]\..*", ++ qr/Python 2\.[567]\b/, + "python is present", + "python is missing or is not a good version." + )) diff --git a/coccinelle.changes b/coccinelle.changes index 773cbd8..28c5362 100644 --- a/coccinelle.changes +++ b/coccinelle.changes @@ -8,6 +8,7 @@ Thu Jan 20 13:41:16 UTC 2011 - jengelh@medozas.de * support matching and removing some preprocessor directives * support for ocaml scripting * print rule name when a script rule crashes +- Fix python x.y.0 detection ------------------------------------------------------------------- Sat Apr 24 19:14:40 UTC 2010 - jengelh@medozas.de diff --git a/coccinelle.spec b/coccinelle.spec index 31c1b44..1668528 100644 --- a/coccinelle.spec +++ b/coccinelle.spec @@ -10,6 +10,7 @@ Source: %name-%rversion.tar.xz BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: ncurses-devel ocaml python-devel xz Patch1: cocci-cast.diff +Patch2: cocci-pythondetect.diff %description Coccinelle is a program matching and transformation engine which @@ -25,7 +26,7 @@ used (by us and others) for finding and fixing bugs in systems code. %prep %setup -qn %name-%rversion -%patch -P 1 -p1 +%patch -P 1 -P 2 -p1 %build # not autotools configure, don't use macro