Bug 151263

Summary: [patch] Make net/arping compilable again
Product: Ports & Packages Reporter: Lucius Windschuh <lwindschuh>
Component: Individual Port(s)Assignee: Philip M. Gollucci <pgollucci>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff none

Description Lucius Windschuh 2010-10-06 15:10:02 UTC
On my machine, 9-CURRENT i386 with libpcap installed from the ports tree, arping fails to compile with:
In file included from arping.c:84:
/usr/include/net/bpf.h:65: error: redefinition of 'struct bpf_program'
/usr/include/net/bpf.h:89: error: redefinition of 'struct bpf_version'
/usr/include/net/bpf.h:913: error: redefinition of 'struct bpf_insn'

The cause is that net/bpf.h is included after pcap.h.
Strangely, pcap.h does not include net/bpf.h although it uses types from this file. It would definitely be a better solution to fix net/bpf.h and libpcap (as there are DLTs in libpcap's pcap-bpf.h that our net/bpf.h doesn't have), but this involves much more work.

Fix: Put the attached file into files/

Patch attached with submission follows:
How-To-Repeat: 1. install libpcap from ports
2. try to compile net/arping on a 9-CURRENT system
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2010-10-06 15:10:14 UTC
Responsible Changed
From-To: freebsd-ports-bugs->gavin

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 Philip M. Gollucci freebsd_committer freebsd_triage 2010-12-12 02:56:20 UTC
Responsible Changed
From-To: gavin->pgollucci

committer&maintainer timeout (gavin ; 67 days) / last commit: 248 days 
ago
Comment 3 Philip M. Gollucci freebsd_committer freebsd_triage 2010-12-13 00:12:59 UTC
State Changed
From-To: open->feedback

Request Feedback: have you sent this upstream?
Comment 4 Philip M. Gollucci freebsd_committer freebsd_triage 2010-12-13 18:22:37 UTC
State Changed
From-To: feedback->open

Feedback received
Comment 5 Philip M. Gollucci freebsd_committer freebsd_triage 2010-12-15 02:43:18 UTC
State Changed
From-To: open->closed

Committed, Thanks!