LOG New version 2.0.8, update patchset

This commit is contained in:
Andrey Bondrov 2012-09-15 12:11:39 +11:00
parent a41c9f8fb5
commit ed67ebb4de
5 changed files with 72 additions and 9 deletions

View file

@ -1,2 +1,2 @@
sources:
"swig-2.0.7.tar.gz": 307020fb6437092e32c9c1bd9af8bccb1645b529
"swig-2.0.8.tar.gz": 763305da320163903c69c1cdfbf9a942117d9ace

View file

@ -1,6 +1,12 @@
--- swig-2.0.7/configure.in.orig 2012-09-02 10:12:44.000000000 +0400
+++ swig-2.0.7/configure.in 2012-09-02 10:13:09.000000000 +0400
@@ -668,7 +668,7 @@
--- swig-2.0.7/configure.in.pylib 2012-05-23 19:10:44.000000000 +0000
+++ swig-2.0.7/configure.in 2012-05-31 23:21:24.000000000 +0000
@@ -664,11 +664,13 @@
fi
AC_MSG_RESULT($PYLIBDIR)
+ PYLIB=`$PYTHON -c "import sys; print sys.path[[1]]"`
+
# Set the include directory
AC_MSG_CHECKING(for Python header files)
if test -r $PYPREFIX/include/$PYVERSION/Python.h; then
@ -9,10 +15,11 @@
fi
if test -z "$PYINCLUDE"; then
if test -r $PYPREFIX/include/Py/Python.h; then
@@ -680,12 +680,6 @@
@@ -679,13 +681,6 @@
# Set the library directory blindly. This probably won't work with older versions
AC_MSG_CHECKING(for Python library)
dirs="$PYVERSION/config $PYVERSION/$PYLIBDIR python/$PYLIBDIR"
- dirs="$PYVERSION/config $PYVERSION/$PYLIBDIR python/$PYLIBDIR"
- for i in $dirs; do
- if test -d $PYEPREFIX/$PYLIBDIR/$i; then
- PYLIB="$PYEPREFIX/$PYLIBDIR/$i"

View file

@ -10,7 +10,7 @@
%{?_with_mono: %{expand: %%global with_mono 1}}
Name: swig
Version: 2.0.7
Version: 2.0.8
Release: 1
Epoch: 1
Summary: Simplified Wrapper and Interface Generator (SWIG)
@ -19,6 +19,8 @@ Group: Development/Other
URL: http://www.swig.org/
Source0: http://download.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
Patch0: swig-2.0.7-pylib.patch
Patch1: swig203-rh706140.patch
Patch2: swig204-rh752054.patch
BuildRequires: bison
BuildRequires: imake
%if %{with_guile}
@ -41,7 +43,7 @@ BuildRequires: python-devel
BuildRequires: ruby-devel
BuildRequires: tcl-devel
BuildRequires: autoconf automake libtool
Obsoletes: swig-devel
Obsoletes: swig-devel < 2.0.7
%description
SWIG takes an interface description file written in a combination of C/C++
@ -52,7 +54,7 @@ It allows scripting languages to use C/C++ code with minimal effort.
%package doc
Summary: Documentation and examples for %{name}
Group: Development/C
Requires: %{name} = %{epoch}:%{version}-%{release}
Requires: %{name} = %{EVRD}
%description doc
SWIG takes an interface description file written in a combination of C/C++
@ -65,6 +67,8 @@ documentation.
%prep
%setup -q
%patch0 -p1 -b .pylib
%patch1 -p1
%patch2 -p1
%build
./autogen.sh

30
swig203-rh706140.patch Normal file
View file

@ -0,0 +1,30 @@
diff -up swig-2.0.3/Lib/guile/guile_gh_run.swg.rh706140 swig-2.0.3/Lib/guile/guile_gh_run.swg
--- swig-2.0.3/Lib/guile/guile_gh_run.swg.rh706140 2011-05-20 15:16:42.300658987 +0200
+++ swig-2.0.3/Lib/guile/guile_gh_run.swg 2011-05-20 15:17:08.609658991 +0200
@@ -15,7 +15,11 @@
extern "C" {
#endif
+#if SCM_MAJOR_VERSION >= 2
+typedef scm_t_subr swig_guile_proc;
+#else
typedef SCM (*swig_guile_proc)();
+#endif
#define SWIG_malloc(size) \
SCM_MUST_MALLOC(size)
diff -up swig-2.0.3/Lib/guile/guile_scm_run.swg.rh706140 swig-2.0.3/Lib/guile/guile_scm_run.swg
--- swig-2.0.3/Lib/guile/guile_scm_run.swg.rh706140 2011-05-20 15:17:22.057658991 +0200
+++ swig-2.0.3/Lib/guile/guile_scm_run.swg 2011-05-20 15:17:46.183658997 +0200
@@ -12,7 +12,11 @@
extern "C" {
#endif
+#if SCM_MAJOR_VERSION >= 2
+typedef scm_t_subr swig_guile_proc;
+#else
typedef SCM (*swig_guile_proc)();
+#endif
typedef SCM (*guile_destructor)(SCM);
typedef struct swig_guile_clientdata {

22
swig204-rh752054.patch Normal file
View file

@ -0,0 +1,22 @@
--- swig-2.0.4/Lib/guile/guile_scm_run.swg 2011-11-14 14:44:35.688597584 +0100
+++ swig-2.0.4/Lib/guile/guile_scm_run.swg.rh752054 2011-11-14 14:45:15.879594778 +0100
@@ -64,7 +64,7 @@ static swig_module_info *SWIG_Guile_GetM
SWIGINTERN char *
SWIG_Guile_scm2newstr(SCM str, size_t *len) {
#define FUNC_NAME "SWIG_Guile_scm2newstr"
- char *ret;
+ char *ret, *tmp;
size_t l;
SCM_ASSERT (SCM_STRINGP(str), str, 1, FUNC_NAME);
@@ -73,7 +73,9 @@ SWIG_Guile_scm2newstr(SCM str, size_t *l
ret = (char *) SWIG_malloc( (l + 1) * sizeof(char));
if (!ret) return NULL;
- memcpy(ret, SCM_STRING_CHARS(str), l);
+ tmp = scm_to_utf8_string(str);
+ memcpy(ret, tmp, l);
+ free(tmp);
ret[l] = '\0';
if (len) *len = l;
return ret;