[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Fix build errors in bindings with SWIG 3.0.4

From: Philip Martin <philip.martin_at_wandisco.com>
Date: Thu, 29 Jan 2015 15:05:14 +0000

Andreas Stieger <andreas.stieger_at_gmx.de> writes:

> When removing comments which throw SWIG 3.0.4 errors as this:

What errors do you get if you leave the comments in? We don't really
want to delete the comments from our source code. Which version of
Python are you using?

> I get the following error:
>> import mergeinfo, core, client, delta, checksum, pool, ra, wc, repository, \
>> File "~/subversion/subversion/bindings/swig/python/tests/mergeinfo.py", line 22, in <module>
>> from svn import core, repos, fs
>> File "~/subversion/subversion/bindings/swig/python/svn/core.py", line 26, in <module>
>> from libsvn.core import *
>> File "~/subversion/subversion/bindings/swig/python/libsvn/core.py", line 6386, in <module>
>> svn_pool_create()
>> TypeError: svn_pool_create() takes exactly 2 arguments (0 given)
>> make: *** [check-swig-py] Error 1
> Andreas

The file subversion/bindings/swig/python/libsvn/core.py is generated by
SWIG. In my SWIG 2.0.7 build the call to svn_pool_create() occurs at line
6819 while there is a definition of svn_pool_create() at line 1631:

def svn_pool_create(*args):
  """svn_pool_create(apr_pool_t parent_pool, apr_allocator_t * allocator) -> apr
  return _core.svn_pool_create(*args)

The file subversion/bindings/swig/python/svn/core.py is not generated
and it defines _core.svn_pool_create() as

def svn_pool_create(parent_pool=None):
  """Deprecated. Use Pool() instead. This is a compatibility
  wrapper providing the interface of the Subversion 1.2.x and
  earlier bindings."""
  return Pool(parent_pool)

Philip Martin | Subversion Committer
WANdisco // *Non-Stop Data*
Received on 2015-01-29 16:06:31 CET

This is an archived mail posted to the Subversion Dev mailing list.