b.a.t.m.a.n.lists.open-mesh.org archive mirror
 help / color / mirror / Atom feed
* [B.A.T.M.A.N.] [PATCH v2 0/2] batctl: musl build fixes
@ 2015-04-06 14:28 Alex Suykov
  2015-04-06 14:28 ` [B.A.T.M.A.N.] [PATCH v2 1/2] batctl: update packet.h to match batman-adv Alex Suykov
  2015-04-06 14:29 ` [B.A.T.M.A.N.] [PATCH v2 2/2] batctl: use netinet/if_ether.h instead of linux/if_ether.h Alex Suykov
  0 siblings, 2 replies; 6+ messages in thread
From: Alex Suykov @ 2015-04-06 14:28 UTC (permalink / raw)
  To: b.a.t.m.a.n

batctl fails to build with musl, mostly because of somewhat weird
netinet/*.h headers musl provides, but the problem turns out to be
easy to fix.

The changes follow this series:
https://lists.open-mesh.org:443/pipermail/b.a.t.m.a.n/2015-April/012960.html
https://lists.open-mesh.org:443/pipermail/b.a.t.m.a.n/2015-April/012961.html
https://lists.open-mesh.org:443/pipermail/b.a.t.m.a.n/2015-April/012962.html
https://lists.open-mesh.org:443/pipermail/b.a.t.m.a.n/2015-April/012963.html

-- 
2.0.3


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [B.A.T.M.A.N.] [PATCH v2 1/2] batctl: update packet.h to match batman-adv
  2015-04-06 14:28 [B.A.T.M.A.N.] [PATCH v2 0/2] batctl: musl build fixes Alex Suykov
@ 2015-04-06 14:28 ` Alex Suykov
  2015-04-20  7:28   ` Sven Eckelmann
  2015-04-06 14:29 ` [B.A.T.M.A.N.] [PATCH v2 2/2] batctl: use netinet/if_ether.h instead of linux/if_ether.h Alex Suykov
  1 sibling, 1 reply; 6+ messages in thread
From: Alex Suykov @ 2015-04-06 14:28 UTC (permalink / raw)
  To: b.a.t.m.a.n

Changes from
https://lists.open-mesh.org:443/pipermail/b.a.t.m.a.n/2015-April/012961.html
ported to batctl.

Signed-off-by: Alex Suykov <alex.suykov at gmail.com>
---
 packet.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/packet.h b/packet.h
index b81fbbf..7a9cb7a 100644
--- a/packet.h
+++ b/packet.h
@@ -18,6 +18,9 @@
 #ifndef _NET_BATMAN_ADV_PACKET_H_
 #define _NET_BATMAN_ADV_PACKET_H_
 
+#include <asm/byteorder.h>
+#include <linux/types.h>
+
 /**
  * enum batadv_packettype - types for batman-adv encapsulated packets
  * @BATADV_IV_OGM: originator messages for B.A.T.M.A.N. IV
-- 
2.0.3


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [B.A.T.M.A.N.] [PATCH v2 2/2] batctl: use netinet/if_ether.h instead of linux/if_ether.h
  2015-04-06 14:28 [B.A.T.M.A.N.] [PATCH v2 0/2] batctl: musl build fixes Alex Suykov
  2015-04-06 14:28 ` [B.A.T.M.A.N.] [PATCH v2 1/2] batctl: update packet.h to match batman-adv Alex Suykov
@ 2015-04-06 14:29 ` Alex Suykov
  2015-04-20  7:27   ` Sven Eckelmann
  2015-04-21  4:06   ` Marek Lindner
  1 sibling, 2 replies; 6+ messages in thread
From: Alex Suykov @ 2015-04-06 14:29 UTC (permalink / raw)
  To: b.a.t.m.a.n

musl does not allow including netinet/* and linux/* headers together.
batctl includes netinet/if_ether.h indirectly via net/ethernet.h,
so netinet/if_ether.h must be used instead of linux/if_ether.h.

Signed-off-by: Alex Suykov <alex.suykov at gmail.com>
---
v2: updated to work with #include <linux/types.h> in packet.h introduced by
https://lists.open-mesh.org:443/pipermail/b.a.t.m.a.n/2015-April/012961.html
and ported to batctl by patch 1/2 in this set.

 ping.c       | 2 +-
 tcpdump.h    | 2 +-
 traceroute.c | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/ping.c b/ping.c
index bdca222..7880a82 100644
--- a/ping.c
+++ b/ping.c
@@ -34,7 +34,7 @@
 #include <stdint.h>
 #include <sys/select.h>
 #include <sys/time.h>
-#include <linux/if_ether.h>
+#include <netinet/if_ether.h>
 
 #include "main.h"
 #include "ping.h"
diff --git a/tcpdump.h b/tcpdump.h
index 5d936f2..3c9126c 100644
--- a/tcpdump.h
+++ b/tcpdump.h
@@ -23,7 +23,7 @@
 #define _BATCTL_TCPDUMP_H
 
 #include <netpacket/packet.h>
-#include <linux/if_ether.h>
+#include <netinet/if_ether.h>
 #include <net/if_arp.h>
 #include <sys/types.h>
 #include "main.h"
diff --git a/traceroute.c b/traceroute.c
index 4ebfec2..373fe90 100644
--- a/traceroute.c
+++ b/traceroute.c
@@ -22,13 +22,13 @@
 
 
 #include <netinet/in.h>
+#include <netinet/if_ether.h>
 #include <errno.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <unistd.h>
 #include <fcntl.h>
 #include <string.h>
-#include <linux/if_ether.h>
 #include <stddef.h>
 #include <sys/select.h>
 #include <sys/time.h>
-- 
2.0.3


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCH v2 2/2] batctl: use netinet/if_ether.h instead of linux/if_ether.h
  2015-04-06 14:29 ` [B.A.T.M.A.N.] [PATCH v2 2/2] batctl: use netinet/if_ether.h instead of linux/if_ether.h Alex Suykov
@ 2015-04-20  7:27   ` Sven Eckelmann
  2015-04-21  4:06   ` Marek Lindner
  1 sibling, 0 replies; 6+ messages in thread
From: Sven Eckelmann @ 2015-04-20  7:27 UTC (permalink / raw)
  To: b.a.t.m.a.n

On Monday 06 April 2015 17:29:13 Alex Suykov wrote:
> musl does not allow including netinet/* and linux/* headers together.
> batctl includes netinet/if_ether.h indirectly via net/ethernet.h,
> so netinet/if_ether.h must be used instead of linux/if_ether.h.
> 
> Signed-off-by: Alex Suykov <alex.suykov at gmail.com>

Acked-by: Sven Eckelmann <sven@narfation.org>

> ---
> v2: updated to work with #include <linux/types.h> in packet.h introduced by
> https://lists.open-mesh.org:443/pipermail/b.a.t.m.a.n/2015-April/012961.html
> and ported to batctl by patch 1/2 in this set.
> 
>  ping.c       | 2 +-
>  tcpdump.h    | 2 +-
>  traceroute.c | 2 +-
>  3 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/ping.c b/ping.c
> index bdca222..7880a82 100644
> --- a/ping.c
> +++ b/ping.c
> @@ -34,7 +34,7 @@
>  #include <stdint.h>
>  #include <sys/select.h>
>  #include <sys/time.h>
> -#include <linux/if_ether.h>
> +#include <netinet/if_ether.h>
> 
>  #include "main.h"
>  #include "ping.h"
> diff --git a/tcpdump.h b/tcpdump.h
> index 5d936f2..3c9126c 100644
> --- a/tcpdump.h
> +++ b/tcpdump.h
> @@ -23,7 +23,7 @@
>  #define _BATCTL_TCPDUMP_H
> 
>  #include <netpacket/packet.h>
> -#include <linux/if_ether.h>
> +#include <netinet/if_ether.h>
>  #include <net/if_arp.h>
>  #include <sys/types.h>
>  #include "main.h"
> diff --git a/traceroute.c b/traceroute.c
> index 4ebfec2..373fe90 100644
> --- a/traceroute.c
> +++ b/traceroute.c
> @@ -22,13 +22,13 @@
> 
> 
>  #include <netinet/in.h>
> +#include <netinet/if_ether.h>
>  #include <errno.h>
>  #include <stdio.h>
>  #include <stdlib.h>
>  #include <unistd.h>
>  #include <fcntl.h>
>  #include <string.h>
> -#include <linux/if_ether.h>
>  #include <stddef.h>
>  #include <sys/select.h>
>  #include <sys/time.h>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCH v2 1/2] batctl: update packet.h to match batman-adv
  2015-04-06 14:28 ` [B.A.T.M.A.N.] [PATCH v2 1/2] batctl: update packet.h to match batman-adv Alex Suykov
@ 2015-04-20  7:28   ` Sven Eckelmann
  0 siblings, 0 replies; 6+ messages in thread
From: Sven Eckelmann @ 2015-04-20  7:28 UTC (permalink / raw)
  To: b.a.t.m.a.n

On Monday 06 April 2015 17:28:48 Alex Suykov wrote:
> Changes from
> https://lists.open-mesh.org:443/pipermail/b.a.t.m.a.n/2015-April/012961.html
> ported to batctl.
> 
> Signed-off-by: Alex Suykov <alex.suykov at gmail.com>

I think we should wait with this one until the actual patch is in batman-adv.

Kind regards,
	Sven

> ---
>  packet.h | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/packet.h b/packet.h
> index b81fbbf..7a9cb7a 100644
> --- a/packet.h
> +++ b/packet.h
> @@ -18,6 +18,9 @@
>  #ifndef _NET_BATMAN_ADV_PACKET_H_
>  #define _NET_BATMAN_ADV_PACKET_H_
> 
> +#include <asm/byteorder.h>
> +#include <linux/types.h>
> +
>  /**
>   * enum batadv_packettype - types for batman-adv encapsulated packets
>   * @BATADV_IV_OGM: originator messages for B.A.T.M.A.N. IV


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCH v2 2/2] batctl: use netinet/if_ether.h instead of linux/if_ether.h
  2015-04-06 14:29 ` [B.A.T.M.A.N.] [PATCH v2 2/2] batctl: use netinet/if_ether.h instead of linux/if_ether.h Alex Suykov
  2015-04-20  7:27   ` Sven Eckelmann
@ 2015-04-21  4:06   ` Marek Lindner
  1 sibling, 0 replies; 6+ messages in thread
From: Marek Lindner @ 2015-04-21  4:06 UTC (permalink / raw)
  To: b.a.t.m.a.n

[-- Attachment #1: Type: text/plain, Size: 700 bytes --]

On Monday, April 06, 2015 17:29:13 Alex Suykov wrote:
> musl does not allow including netinet/* and linux/* headers together.
> batctl includes netinet/if_ether.h indirectly via net/ethernet.h,
> so netinet/if_ether.h must be used instead of linux/if_ether.h.
> 
> Signed-off-by: Alex Suykov <alex.suykov at gmail.com>
> ---
> v2: updated to work with #include <linux/types.h> in packet.h introduced by
> https://lists.open-mesh.org:443/pipermail/b.a.t.m.a.n/2015-April/012961.html
> and ported to batctl by patch 1/2 in this set.
> 
>  ping.c       | 2 +-
>  tcpdump.h    | 2 +-
>  traceroute.c | 2 +-
>  3 files changed, 3 insertions(+), 3 deletions(-)

Applied in revision 6423e3e.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-04-21  4:06 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-04-06 14:28 [B.A.T.M.A.N.] [PATCH v2 0/2] batctl: musl build fixes Alex Suykov
2015-04-06 14:28 ` [B.A.T.M.A.N.] [PATCH v2 1/2] batctl: update packet.h to match batman-adv Alex Suykov
2015-04-20  7:28   ` Sven Eckelmann
2015-04-06 14:29 ` [B.A.T.M.A.N.] [PATCH v2 2/2] batctl: use netinet/if_ether.h instead of linux/if_ether.h Alex Suykov
2015-04-20  7:27   ` Sven Eckelmann
2015-04-21  4:06   ` Marek Lindner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).