summaryrefslogtreecommitdiffstats
path: root/package/ngrep
diff options
context:
space:
mode:
Diffstat (limited to 'package/ngrep')
-rw-r--r--package/ngrep/ngrep.mk8
1 files changed, 7 insertions, 1 deletions
diff --git a/package/ngrep/ngrep.mk b/package/ngrep/ngrep.mk
index 0bb5d7ecdb..18a2e74b48 100644
--- a/package/ngrep/ngrep.mk
+++ b/package/ngrep/ngrep.mk
@@ -10,7 +10,13 @@ NGREP_SITE = http://downloads.sourceforge.net/project/ngrep/ngrep/$(NGREP_VERSIO
NGREP_LICENSE = BSD-4c-like
NGREP_LICENSE_FILES = LICENSE.txt
NGREP_INSTALL_STAGING = YES
-NGREP_CONF_ENV = LIBS="-lpcre"
+
+NGREP_LIBS = -lpcap -lpcre
+ifeq ($(BR2_PREFER_STATIC_LIB),y)
+NGREP_LIBS += $(shell $(STAGING_DIR)/usr/bin/pcap-config --static --additional-libs)
+endif
+NGREP_CONF_ENV += LIBS+="$(NGREP_LIBS)"
+
NGREP_CONF_OPT = \
--with-pcap-includes=$(STAGING_DIR)/usr/include \
--enable-pcre \
OpenPOWER on IntegriCloud