title: invalid application of 'sizeof' to incomplete type 'struct ether_arp'
body: <p>i'm trying to compile batctl-2012.0.0 from open-mesh.org, with android-ndk, but, in progress, tcpdump.c give invalid application of 'sizeof' to incomplete type 'struct ether_arp'. Please tell me where or how to solve it. thank you very much</p>
  
  <pre><code>static void dump_arp(unsigned char *packet_buff, ssize_t buff_len, int time_printed)
  {
  struct ether_arp *arphdr;
  
  LEN_CHECK((size_t)buff_len, (long)sizeof(struct ether_arp), "ARP");
  
  if (!time_printed)
      print_time();
  
  arphdr = (struct ether_arp *)packet_buff;
  
  switch (ntohs(arphdr-&gt;arp_op)) {
  case ARPOP_REQUEST:
      printf("ARP, Request who-has %s", inet_ntoa(*(struct in_addr *)&amp;arphdr-&gt;arp_tpa));
      printf(" tell %s (%s), length %zd\n", inet_ntoa(*(struct in_addr *)&amp;arphdr-&gt;arp_spa),
          ether_ntoa_long((struct ether_addr *)&amp;arphdr-&gt;arp_sha), buff_len);
      break;
  case ARPOP_REPLY:
      printf("ARP, Reply %s is-at %s, length %zd\n", inet_ntoa(*(struct in_addr *)&amp;arphdr-&gt;arp_spa),
          ether_ntoa_long((struct ether_addr *)&amp;arphdr-&gt;arp_sha), buff_len);
      break;
  default:
      printf("ARP, unknown op code: %i\n", ntohs(arphdr-&gt;arp_op));
      break;
  }
  }
  </code></pre>
  
  <p>and this in terminal</p>
  
  <pre><code>/home/renanto/workspace/androidbatctl/jni/tcpdump.c: In function 'dump_arp':
  /home/renanto/workspace/androidbatctl/jni/tcpdump.c:96: error: invalid application of 'sizeof' to incomplete type 'struct ether_arp' 
  /home/renanto/workspace/androidbatctl/jni/tcpdump.c:96: error: invalid application of 'sizeof' to incomplete type 'struct ether_arp' 
  </code></pre>