Makefile 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. # $OpenBSD: Makefile,v 1.137 2017/06/08 07:33:37 ajacoutot Exp $
  2. COMMENT= GNU Transport Layer Security library
  3. V= 3.5.13
  4. DISTNAME= gnutls-${V}
  5. EXTRACT_SUFX= .tar.xz
  6. CATEGORIES= security
  7. SHARED_LIBS += gnutls 44.1 # 44.5
  8. SHARED_LIBS += gnutlsxx 29.1 # 29.0
  9. HOMEPAGE= http://www.gnutls.org/
  10. MAINTAINER= Antoine Jacoutot <ajacoutot@openbsd.org>
  11. # LGPLv2.1+ - GPLv3+
  12. PERMIT_PACKAGE_CDROM= Yes
  13. WANTLIB += c ffi gmp hogweed iconv idn2 intl m nettle p11-kit pthread
  14. WANTLIB += tasn1 unistring z
  15. MASTER_SITES= ftp://ftp.gnutls.org/gcrypt/gnutls/v${V:R}/ \
  16. http://ftp.heanet.ie/mirrors/ftp.gnupg.org/gcrypt/gnutls/v${V:R}/
  17. .include <bsd.port.arch.mk>
  18. .if ${PROPERTIES:Mclang} || ${MACHINE_ARCH} != amd64
  19. WANTLIB += ${LIBCXX}
  20. .else
  21. # assembly instructions
  22. MODULES += lang/clang
  23. MODCLANG_ARCHS= amd64
  24. MODCLANG_LANGS= c++
  25. .endif
  26. # needed for tests
  27. BUILD_DEPENDS= devel/cmocka
  28. LIB_DEPENDS= converters/libunistring \
  29. devel/libidn2 \
  30. security/libtasn1 \
  31. security/libnettle \
  32. security/p11-kit
  33. USE_GMAKE= Yes
  34. # regression tests need this
  35. PORTHOME= ${WRKDIR}
  36. CONFIGURE_STYLE= gnu
  37. CONFIGURE_ARGS= --disable-guile \
  38. --disable-ssl3-support \
  39. --disable-valgrind-tests \
  40. --with-default-trust-store-file=/etc/ssl/cert.pem \
  41. --with-unbound-root-key-file=/var/unbound/db/root.key
  42. # OpenBSD's unbound does not provide libdane
  43. CONFIGURE_ARGS += --disable-libdane
  44. # requires security/trousers: not committed (aja@), needs kernel support
  45. # for tpm(4): http://bsssd.sourceforge.net/
  46. CONFIGURE_ARGS += --without-tpm
  47. # prevents dependency on devel/autogen
  48. CONFIGURE_ARGS += --enable-local-libopts
  49. CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
  50. LDFLAGS="-L${LOCALBASE}/lib"
  51. post-install:
  52. ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/gnutls
  53. ${INSTALL_DATA_DIR} ${PREFIX}/share/examples/gnutls
  54. ${INSTALL_DATA} ${WRKSRC}/doc/examples/*.c \
  55. ${PREFIX}/share/examples/gnutls
  56. # warning: implicit declaration of function 'kill'
  57. # error: 'SIGTERM' undeclared (first use in this function)
  58. pre-test:
  59. perl -i -pe 's,#include <stdlib.h>,$$&\n#include <signal.h>,' \
  60. ${WRKSRC}/tests/*.c
  61. .include <bsd.port.mk>