arp-scan: fix static link when libnl is selected
authorArnout Vandecappelle <arnout@mind.be>
Sat, 8 Apr 2017 14:17:36 +0000 (16:17 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Sat, 8 Apr 2017 19:43:02 +0000 (21:43 +0200)
When libnl is selected, libpcap links with it. Since libpcap doesn't
provide a .pc file and arp-scan doesn't use its libpcap-config script,
we must provide the additional options explicilty.

Fixes
http://autobuild.buildroot.net/results/c605c8cc36348f199a36e2652851b8d02ee222c0

Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/arp-scan/arp-scan.mk

index fc3740bf5746dd2f56032a3532882ae49f98adf9..b46e941d103b342a10c26cd2a8015f2e89f9c86c 100644 (file)
@@ -13,6 +13,10 @@ ARP_SCAN_DEPENDENCIES = libpcap
 # 0001-configure-try-linking-to-detect-stack-protector-supp.patch touches acinclude.m4
 ARP_SCAN_AUTORECONF = YES
 
+ifeq ($(BR2_STATIC_LIBS),y)
+ARP_SCAN_CONF_OPTS = LIBS="`$(STAGING_DIR)/usr/bin/pcap-config --static --additional-libs`"
+endif
+
 ARP_SCAN_CONF_ENV = pgac_cv_snprintf_long_long_int_format='%lld'
 
 $(eval $(autotools-package))