You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by kf...@collab.net on 2005/02/05 23:04:39 UTC

Re: building on osx

Jon Scott Stevens <jo...@latchkey.com> writes:
> This is the script I used to build subversion with Apache 2.x
> integration (with the python bindings) on OSX 10.3.x.

Thanks!

I don't run Mac OS X myself, so pardon me if these are dumb questions:
is this patching over problems in our build system?  Or is it an
improvement that could be incorporated into our build system?  Or
should we just make this script available for people in certain
specific situations?

The subtext here is: I'm trying to figure out what's the right final
destination for this work you've done, so the most people will
benefit.  What's your recommendation?

-Karl

> Notes:
> 
> #1. If you install libintl via fink, then you need to define
> SWIG_LDFLAGS and also make sure to pass that to 'make swig-py'. It
> isn't enough to just export the variable. IMHO, this is a bug in the
> build process and needs to be fixed.
> 
> #2. I'm not sure if one needs to pass the /usr/local/lib as I think
> the system does it for you, but I did it just in case.
> 
> #3. Make sure that when you install SWIG 1.3.21 (do not try to install
> anything newer than that version or you will have problems) that you
> follow all of the steps for building it detailed in
> subversion/bindings/swig/README
> 
> #!/bin/sh
> 
> APP=subversion
> VER=1.1.3
> LDFLAGS="-L/sw/lib -L/usr/local/lib"
> export LDFLAGS
> SWIG_LDFLAGS=$LDFLAGS
> export SWIG_LDFLAGS
> 
> if [ ! -e $APP-$VER ] ; then
> tar -xzf $APP-$VER.tar.gz
> fi
> 
> cd $APP-$VER
> ./configure \
>          --with-apxs=/usr/sbin/apxs \
>          --with-zlib=/usr/local \
>          --with-berkeley-db=/sw \
>          --with-swig \
>          --enable-swig-bindings=python
> 
> make
> make install
> make swig-py SWIG_LDFLAGS=$LDFLAGS
> make install-swig-py
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: users-help@subversion.tigris.org

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: building on osx

Posted by Max Bowsher <ma...@ukf.net>.
Jon Scott Stevens wrote:
> I would do the following:
>
> #1. Bundle SWIG with the src distribution and make it part of the build
> process. It's under a BSD license so that is easily possible and the
> tar.gz is only 2megs (.24 is 3megs).

Several megs is a *lot* for a non-core dependency.

...
> #2. I would consider putting a special case into the build system for
> OSX  to look for libs in "/sw" which is the default fink installation
> path.

Fink's /sw/bin/init.sh is pretty comprehensive about revealing /sw.
I don't think special cases should be needed.

> libiconv is distributed with OSX by default, but for whatever
> reason, the configure system finds the /sw version first but forgets to
> add -L/sw/lib to the build.

Now *that's* a bug.

> #3. I would make SWIG_LDFLAGS settable from environment variables (and
> not just after make) and I would make it default to inheriting the
> LDFLAGS settings...or maybe just this is enough...
>
> [4][ /usr/local/src/subversion/subversion-1.1.3 ]# diff build.conf.bak
> build.conf
> 343c343
> < link-cmd = $(LINK) $(SWIG_LDFLAGS) $(SWIG_PY_LIBS)
> ---
>> link-cmd = $(LINK) $(LDFLAGS) $(SWIG_LDFLAGS) $(SWIG_PY_LIBS)

I'm not in favour of opening up the guts of configure even more, but 
whatever lack of propagation of flags you are seeing is certainly a bug.

Could you give a summary of the environment to cause the failure?
(Sorry if you already have, I've been very busy lately, and unable to follow 
the mailing lists in detail.)


Max.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: building on osx

Posted by Jon Scott Stevens <jo...@latchkey.com>.
I would do the following:

#1. Bundle SWIG with the src distribution and make it part of the build 
process. It's under a BSD license so that is easily possible and the 
tar.gz is only 2megs (.24 is 3megs).

Because SVN has specific version requirements for SWIG, it would be 
easier for end users to just have SVN build SWIG for you (just like 
with apr). 1.3.21 was released over a year ago and 1.3.24 is now a 
couple of months old.

#2. I would consider putting a special case into the build system for 
OSX  to look for libs in "/sw" which is the default fink installation 
path. libiconv is distributed with OSX by default, but for whatever 
reason, the configure system finds the /sw version first but forgets to 
add -L/sw/lib to the build.

#3. I would make SWIG_LDFLAGS settable from environment variables (and 
not just after make) and I would make it default to inheriting the 
LDFLAGS settings...or maybe just this is enough...

[4][ /usr/local/src/subversion/subversion-1.1.3 ]# diff build.conf.bak 
build.conf
343c343
< link-cmd = $(LINK) $(SWIG_LDFLAGS) $(SWIG_PY_LIBS)
---
 > link-cmd = $(LINK) $(LDFLAGS) $(SWIG_LDFLAGS) $(SWIG_PY_LIBS)

If you don't want to do any of those changes, then my script will 
continue to work for people with similar configurations. =)

thanks!

jon

On Feb 5, 2005, at 3:04 PM, kfogel@collab.net wrote:

> Thanks!
>
> I don't run Mac OS X myself, so pardon me if these are dumb questions:
> is this patching over problems in our build system?  Or is it an
> improvement that could be incorporated into our build system?  Or
> should we just make this script available for people in certain
> specific situations?
>
> The subtext here is: I'm trying to figure out what's the right final
> destination for this work you've done, so the most people will
> benefit.  What's your recommendation?
>
> -Karl


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: building on osx

Posted by Jon Scott Stevens <jo...@latchkey.com>.
I would do the following:

#1. Bundle SWIG with the src distribution and make it part of the build 
process. It's under a BSD license so that is easily possible and the 
tar.gz is only 2megs (.24 is 3megs).

Because SVN has specific version requirements for SWIG, it would be 
easier for end users to just have SVN build SWIG for you (just like 
with apr). 1.3.21 was released over a year ago and 1.3.24 is now a 
couple of months old.

#2. I would consider putting a special case into the build system for 
OSX  to look for libs in "/sw" which is the default fink installation 
path. libiconv is distributed with OSX by default, but for whatever 
reason, the configure system finds the /sw version first but forgets to 
add -L/sw/lib to the build.

#3. I would make SWIG_LDFLAGS settable from environment variables (and 
not just after make) and I would make it default to inheriting the 
LDFLAGS settings...or maybe just this is enough...

[4][ /usr/local/src/subversion/subversion-1.1.3 ]# diff build.conf.bak 
build.conf
343c343
< link-cmd = $(LINK) $(SWIG_LDFLAGS) $(SWIG_PY_LIBS)
---
 > link-cmd = $(LINK) $(LDFLAGS) $(SWIG_LDFLAGS) $(SWIG_PY_LIBS)

If you don't want to do any of those changes, then my script will 
continue to work for people with similar configurations. =)

thanks!

jon

On Feb 5, 2005, at 3:04 PM, kfogel@collab.net wrote:

> Thanks!
>
> I don't run Mac OS X myself, so pardon me if these are dumb questions:
> is this patching over problems in our build system?  Or is it an
> improvement that could be incorporated into our build system?  Or
> should we just make this script available for people in certain
> specific situations?
>
> The subtext here is: I'm trying to figure out what's the right final
> destination for this work you've done, so the most people will
> benefit.  What's your recommendation?
>
> -Karl


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org