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

Re: [PATCH] Use swig binary from --with-swig configure switch

From: Daniel Rall <dlr_at_finemaltcoding.com>
Date: 2002-11-07 21:10:02 CET

cmpilato@collab.net writes:

> Daniel Rall <dlr@finemaltcoding.com> writes:
>
> > Hmmm. The --build-base flag is not listed in setup.py's getopts. I'm
> > think it is a distutils-specific option. I noticed that the usual
> > distutils commandline processing seems to be obscured by what's in our
> > setup.py:
>
> It's not a distutils problem. I got so fed up with distutils that I
> stole its cmd-line processing from it, and let setup.py use only the
> things we seemed to need at the time.

Well, I can still trigger the distutils getopt processing -- looks
like it was only partially stolen.

> > $ python2 ./subversion/bindings/swig/python/setup.py --help install
> > Usage: setup.py [OPTIONS] build
> > setup.py install [--prefix PREFIX]
> > setup.py install_lib [--install-dir DIR]
> >
> > Options:
> > -I dir search DIR for includes (multiple instances allowed)
> > -L dir search DIR for libraries (multiple instances allowed)
> > -S dir the DIR for the source of the subversion swig bindings
> > -s path use the swig binary found at PATH
>
> For example: the -s option seems to be what you need. :-)

The patch which started this thread used the -s flag. Here's the
relevant half of it again:

Index: Makefile.in
===================================================================
--- Makefile.in (revision 3678)
+++ Makefile.in (working copy)
@@ -65,6 +65,7 @@
 APACHE_TARGET = @APACHE_TARGET@
 APACHE_LIBEXECDIR = $(DESTDIR)@APACHE_LIBEXECDIR@
 
+SWIG = @SWIG@
 SWIG_PY_INCLUDES = @SWIG_PY_INCLUDES@
 
 SVN_APR_INCLUDES = @SVN_APR_INCLUDES@
@@ -266,6 +267,7 @@
             -I$(abs_srcdir)/subversion/include $(SVN_APR_INCLUDES) \
             -S$(SWIG_SRC_DIR) \
             -L$(DESTDIR)$(prefix)/lib -L$(SVN_APR_PREFIX)/lib \
+ -s$(SWIG) \
             build --build-base=$(SWIG_BUILD_DIR)/python/build)
 
 install-swig-py-ext:

Unfortunately, when $(SWIG) isn't defined (I'm assuming this happens
when you don't pass --with-swig, I triggered it in testing by
explicitly commenting out the SWIG= bit in the patch above), your
getopt from setup.py seems to think that it should handle
--bulid-base, which it doesn't define. I'm guessing that --build-base
is handled by distutils' getopt processing.

-- 
Daniel Rall <dlr@finemaltcoding.com>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Nov 7 21:10:41 2002

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.