Fix generating of python3 wrappers (#830660)

Signed-off-by: Adam Tkac <atkac@redhat.com>
This commit is contained in:
Adam Tkac 2012-06-12 15:07:43 +02:00
parent a794465bf3
commit 7650f2a07d
2 changed files with 18 additions and 1 deletions

View File

@ -10,13 +10,14 @@
Summary: Connects C/C++/Objective C to some high-level programming languages
Name: swig
Version: 2.0.7
Release: 1%{?dist}
Release: 2%{?dist}
License: GPLv3+ and BSD
Group: Development/Tools
URL: http://swig.sourceforge.net/
Source: http://downloads.sourceforge.net/project/swig/swig/swig-%{version}/swig-%{version}.tar.gz
Patch4: swig203-rh706140.patch
Patch6: swig204-rh752054.patch
Patch7: swig207-rh830660.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: perl, python-devel, pcre-devel
@ -55,6 +56,8 @@ This package contains documentation for SWIG and useful examples
# Apply patch 6 when guile2 gets into distro
#%patch6 -p1 -b .rh752054
%patch7 -p1 -b .rh830660
# as written on https://fedoraproject.org/wiki/Packaging_talk:Perl, section 2
# (specific req/prov filtering). Before you remove this hack make sure you don't
# reintroduce https://bugzilla.redhat.com/show_bug.cgi?id=489421
@ -129,6 +132,9 @@ rm -rf %{buildroot}
%doc Doc Examples LICENSE LICENSE-GPL LICENSE-UNIVERSITIES COPYRIGHT
%changelog
* Tue Jun 12 2012 Adam Tkac <atkac redhat com> 2.0.7-2
- fix generating of python3 wrappers (#830660)
* Thu Jun 07 2012 Adam Tkac <atkac redhat com> 2.0.7-1
- update to 2.0.7
- swig-1.3.23-pylib.patch is no longer needed

11
swig207-rh830660.patch Normal file
View File

@ -0,0 +1,11 @@
diff -up swig-2.0.7/Lib/python/pyhead.swg.rh830660 swig-2.0.7/Lib/python/pyhead.swg
--- swig-2.0.7/Lib/python/pyhead.swg.rh830660 2012-06-12 15:04:54.360670826 +0200
+++ swig-2.0.7/Lib/python/pyhead.swg 2012-06-12 15:05:24.119620754 +0200
@@ -5,6 +5,7 @@
#define PyInt_Check(x) PyLong_Check(x)
#define PyInt_AsLong(x) PyLong_AsLong(x)
#define PyInt_FromLong(x) PyLong_FromLong(x)
+#define PyInt_FromSize_t(x) PyLong_FromSize_t(x)
#define PyString_Check(name) PyBytes_Check(name)
#define PyString_FromString(x) PyUnicode_FromString(x)
#define PyString_Format(fmt, args) PyUnicode_Format(fmt, args)