zeromq.mk 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. ################################################################################
  2. #
  3. # zeromq
  4. #
  5. ################################################################################
  6. ZEROMQ_VERSION = 4.3.5
  7. ZEROMQ_SITE = https://github.com/zeromq/libzmq/releases/download/v$(ZEROMQ_VERSION)
  8. ZEROMQ_INSTALL_STAGING = YES
  9. ZEROMQ_CONF_OPTS = --disable-perf --disable-Werror --without-documentation
  10. ZEROMQ_LICENSE = MPL-2.0
  11. ZEROMQ_LICENSE_FILES = LICENSE
  12. ZEROMQ_CPE_ID_VENDOR = zeromq
  13. ZEROMQ_CPE_ID_PRODUCT = libzmq
  14. # Assume these flags are always available. It is true, at least for
  15. # SOCK_CLOEXEC, since linux v2.6.27.
  16. # Note: the flag TCP_KEEPALIVE is NOT available so we do not include it.
  17. ZEROMQ_CONF_ENV = libzmq_cv_sock_cloexec=yes \
  18. libzmq_cv_o_cloexec=yes \
  19. libzmq_cv_so_keepalive=yes \
  20. libzmq_cv_so_priority=yes \
  21. libzmq_cv_so_bindtodevice=yes \
  22. libzmq_cv_tcp_keepcnt=yes \
  23. libzmq_cv_tcp_keepidle=yes \
  24. libzmq_cv_tcp_keepintvl=yes
  25. # Internal error, aborting at dwarf2cfi.c:2752 in connect_traces
  26. # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58864
  27. ifeq ($(BR2_m68k_cf),y)
  28. ZEROMQ_CONF_OPTS += CXXFLAGS="$(TARGET_CXXFLAGS) -fno-defer-pop"
  29. endif
  30. # Only tools/curve_keygen.c needs this, but it doesn't hurt to pass it
  31. # for the rest of the build as well (which automatically includes stdc++).
  32. ifeq ($(BR2_STATIC_LIBS),y)
  33. ZEROMQ_CONF_OPTS += LIBS=-lstdc++
  34. endif
  35. ifeq ($(BR2_PACKAGE_ZEROMQ_NORM),y)
  36. ZEROMQ_CONF_OPTS += --with-norm
  37. ZEROMQ_DEPENDENCIES += norm
  38. else
  39. ZEROMQ_CONF_OPTS += --without-norm
  40. endif
  41. ifeq ($(BR2_PACKAGE_ZEROMQ_PGM),y)
  42. ZEROMQ_DEPENDENCIES += host-pkgconf openpgm
  43. ZEROMQ_CONF_OPTS += --with-pgm
  44. else
  45. ZEROMQ_CONF_OPTS += --without-pgm
  46. endif
  47. ifeq ($(BR2_PACKAGE_ZEROMQ_DRAFTS),y)
  48. ZEROMQ_CONF_OPTS += --enable-drafts
  49. else
  50. ZEROMQ_CONF_OPTS += --disable-drafts
  51. endif
  52. ifeq ($(BR2_PACKAGE_ZEROMQ_WEBSOCKET),y)
  53. ZEROMQ_CONF_OPTS += --enable-ws
  54. else
  55. ZEROMQ_CONF_OPTS += --disable-ws
  56. endif
  57. ifeq ($(BR2_PACKAGE_GNUTLS),y)
  58. ZEROMQ_DEPENDENCIES += host-pkgconf gnutls
  59. ZEROMQ_CONF_OPTS += --with-tls
  60. else
  61. ZEROMQ_CONF_OPTS += --without-tls
  62. endif
  63. ifeq ($(BR2_PACKAGE_LIBBSD),y)
  64. ZEROMQ_DEPENDENCIES += host-pkgconf libbsd
  65. ZEROMQ_CONF_OPTS += --enable-libbsd
  66. else
  67. ZEROMQ_CONF_OPTS += --disable-libbsd
  68. endif
  69. ifeq ($(BR2_PACKAGE_LIBNSS),y)
  70. ZEROMQ_DEPENDENCIES += host-pkgconf libnss
  71. ZEROMQ_CONF_OPTS += --with-nss
  72. else
  73. ZEROMQ_CONF_OPTS += --without-nss
  74. endif
  75. # ZeroMQ uses libsodium if it's available.
  76. ifeq ($(BR2_PACKAGE_LIBSODIUM),y)
  77. ZEROMQ_DEPENDENCIES += libsodium
  78. ZEROMQ_CONF_OPTS += --with-libsodium="$(STAGING_DIR)/usr"
  79. else
  80. ZEROMQ_CONF_OPTS += --without-libsodium
  81. endif
  82. ifeq ($(BR2_PACKAGE_LIBUNWIND),y)
  83. ZEROMQ_DEPENDENCIES += libunwind
  84. ZEROMQ_CONF_OPTS += --enable-libunwind
  85. else
  86. ZEROMQ_CONF_OPTS += --disable-libunwind
  87. endif
  88. $(eval $(autotools-package))