[buildout]
extends =
  ../gettext/buildout.cfg
  ../gmp/buildout.cfg
  ../nettle/buildout.cfg
  ../p11-kit/buildout.cfg

parts = gnutls

[gpg-common]
recipe = slapos.recipe.cmmi
url = http://www.gnupg.org/ftp/gcrypt/${:_buildout_section_name_}/${:_buildout_section_name_}-${:version}.tar.bz2
# we'd like to combine <= and +=
configure-options = ${:configure-options-extra}
  --enable-option-checking=fatal
  --disable-dependency-tracking
environment = ${:environment-extra}
  PATH=${gettext:location}/bin:%(PATH)s
environment-extra =

[libgpg-error]
<= gpg-common
version = 1.27
md5sum = 5217ef3e76a7275a2a3b569a12ddc989
configure-options-extra =
  --disable-doc
  --disable-tests

[libgcrypt]
<= gpg-common
version = 1.7.7
md5sum = d1769481b1b506a632fd66c5e5f62e41
configure-options-extra =
  --with-gpg-error-prefix=${libgpg-error:location}
  --disable-doc
environment-extra =
  LDFLAGS=-Wl,-rpath=${libgpg-error:location}/lib

[gnutls]
<= gpg-common
url = http://www.gnupg.org/ftp/gcrypt/gnutls/v3.5/gnutls-3.5.13.tar.xz
md5sum = 4fd41ad86572933c2379b4cc321a0959
configure-options-extra =
  --disable-doc
  --disable-static
  --disable-libdane
  --disable-guile
  --without-tpm
  --with-included-unistring
pkg-config-path = ${libtasn1:location}/lib/pkgconfig:${nettle:location}/lib/pkgconfig:${p11-kit:location}/lib/pkgconfig:${zlib:location}/lib/pkgconfig
environment =
  PATH=${pkgconfig:location}/bin:${xz-utils:location}/bin:%(PATH)s
  PKG_CONFIG_PATH=${:pkg-config-path}
  CPPFLAGS=-I${gmp:location}/include -I${libtasn1:location}/include
  LDFLAGS=-L${gmp:location}/lib -Wl,-rpath=${gmp:location}/lib -Wl,-rpath=${nettle:location}/lib -Wl,-rpath=${zlib:location}/lib
