# Subversion - Enterprise-class centralized version control for the masses
# http://subversion.apache.org/

[buildout]
extends =
  ../apache/buildout.cfg
  ../libexpat/buildout.cfg
  ../libuuid/buildout.cfg
  ../neon/buildout.cfg
  ../perl/buildout.cfg
  ../pkgconfig/buildout.cfg
  ../sqlite3/buildout.cfg
  ../zlib/buildout.cfg
  ../swig/buildout.cfg
parts =
  subversion

[subversion]
recipe = slapos.recipe.cmmi
url = http://subversion.tigris.org/downloads/subversion-1.6.17.tar.bz2
md5sum = 81e5dc5beee4b3fc025ac70c0b6caa14
# Patch available thanks to gentoo developpers
# http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/dev-vcs/subversion/files/subversion-1.6.0-disable_linking_against_unneeded_libraries.patch?revision=1.1
patches =
  ${:_profile_base_location_}/subversion-1.6.0-disable_linking_against_unneeded_libraries.patch#8d911ec2422dc4c08a00693ac915a07a
configure-options =
  --disable-static
  --with-apr=${apache:location}/bin/apr-1-config
  --with-apr-util=${apache:location}/bin/apu-1-config
  --without-apxs
  --with-zlib=${zlib:location}
  --with-sqlite=${sqlite3:location}
  --with-neon=${neon:location}
  --without-berkeley-db
  --without-sasl
  --without-apr_memcache
  --without-gnome-keyring
  --without-kwallet
  --without-jdk
  --without-jikes
  --without-swig
  --without-junit
  --without-ctypesgen
  --without-ruby-sitedir
  --without-ruby-test-verbose
  --disable-nls

# it seems that parallel build sometimes fails.
make-options =
  -j1

environment =
  PATH=${perl:location}/bin:${pkgconfig:location}/bin:${neon:location}/bin:%(PATH)s
  PKG_CONFIG_PATH=${apache:location}/lib/pkgconfig:${sqlite3:location}/lib/pkgconfig:${openssl:location}/lib/pkgconfig:${neon:location}/lib/pkgconfig
  CPPFLAGS=-I${libexpat:location}/include -I${libuuid:location}/include
  LDFLAGS=-L${libexpat:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${sqlite3:location}/lib -Wl,-rpath=${neon:location}/lib -Wl,-rpath=${apache:location}/lib -L${libuuid:location}/lib -Wl,-rpath=${libuuid:location}/lib


[subversion-1.9]
recipe = hexagonit.recipe.cmmi
url = http://www.apache.org/dist/subversion/subversion-1.7.9.tar.gz
md5sum = dfb083e8bfac88aa28d606168b08e4ff
configure-options =
  --disable-static
  --with-apr=${apache:location}/bin/apr-1-config
  --with-apr-util=${apache:location}/bin/apu-1-config
  --with-apxs=${apache:location}/bin/apxs
  --with-zlib=${zlib:location}
  --with-sqlite=${sqlite3:location}
  --with-neon=${neon:location}
  --with-swig=${swig:location}/bin/swig
  --without-berkeley-db
  --without-sasl
  --without-apr_memcache
  --without-gnome-keyring
  --without-kwallet
  --without-jdk
  --without-jikes
  --without-junit
  --without-ctypesgen
  --without-ruby-sitedir
  --without-ruby-test-verbose
  --disable-nls

# it seems that parallel build sometimes fails.
make-options =
  -j1

make-targets = 
  install
  swig-py
  install-swig-py

environment =
  PATH=${pkgconfig:location}/bin:${neon:location}/bin:%(PATH)s
  PKG_CONFIG_PATH=${apache:location}/lib/pkgconfig:${sqlite3:location}/lib/pkgconfig:${openssl:location}/lib/pkgconfig:${neon:location}/lib/pkgconfig
  CPPFLAGS=-I${libexpat:location}/include -I${libuuid:location}/include
  LDFLAGS=-L${libexpat:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${sqlite3:location}/lib -Wl,-rpath=${neon:location}/lib -Wl,-rpath=${apache:location}/lib -L${libuuid:location}/lib -Wl,-rpath=${libuuid:location}/lib
