xref: /OK3568_Linux_fs/buildroot/package/sngrep/sngrep.mk (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1################################################################################
2#
3# sngrep
4#
5################################################################################
6
7SNGREP_VERSION = 1.4.7
8SNGREP_SITE = $(call github,irontec,sngrep,v$(SNGREP_VERSION))
9SNGREP_LICENSE = GPL-3.0+
10SNGREP_LICENSE_FILES = LICENSE
11SNGREP_AUTORECONF = YES
12SNGREP_DEPENDENCIES = libpcap ncurses host-pkgconf
13
14SNGREP_CONF_ENV += \
15	$(if $(BR2_STATIC_LIBS),LIBS="`$(STAGING_DIR)/usr/bin/pcap-config --static --libs`")
16
17SNGREP_CONF_OPTS += --disable-unicode
18
19# openssl and gnutls can't be enabled at the same time.
20ifeq ($(BR2_PACKAGE_OPENSSL),y)
21SNGREP_DEPENDENCIES += openssl
22SNGREP_CONF_OPTS += --with-openssl --without-gnutls
23# gnutls support also requires libgcrypt
24else ifeq ($(BR2_PACKAGE_GNUTLS)$(BR2_PACKAGE_LIBGCRYPT),yy)
25SNGREP_CONF_ENV += LIBGCRYPT_CONFIG=$(STAGING_DIR)/usr/bin/libgcrypt-config
26SNGREP_DEPENDENCIES += gnutls libgcrypt
27SNGREP_CONF_OPTS += --with-gnutls --without-openssl
28else
29SNGREP_CONF_OPTS += --without-gnutls --without-openssl
30endif
31
32ifeq ($(BR2_PACKAGE_PCRE),y)
33SNGREP_DEPENDENCIES += pcre
34SNGREP_CONF_OPTS += --with-pcre
35else
36SNGREP_CONF_OPTS += --without-pcre
37endif
38
39$(eval $(autotools-package))
40