diff mbox

arp-scan: fix static link when libnl is selected

Message ID 20170408141736.18554-1-arnout@mind.be
State Accepted
Headers show

Commit Message

Arnout Vandecappelle April 8, 2017, 2:17 p.m. UTC
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>
---
 package/arp-scan/arp-scan.mk | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Thomas Petazzoni April 8, 2017, 7:43 p.m. UTC | #1
Hello,

On Sat, 8 Apr 2017 16:17:36 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:
> 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>
> ---
>  package/arp-scan/arp-scan.mk | 4 ++++
>  1 file changed, 4 insertions(+)

Applied to master, thanks.

Thomas
diff mbox

Patch

diff --git a/package/arp-scan/arp-scan.mk b/package/arp-scan/arp-scan.mk
index fc3740bf57..b46e941d10 100644
--- a/package/arp-scan/arp-scan.mk
+++ b/package/arp-scan/arp-scan.mk
@@ -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))