All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
@ 2016-11-17 15:26 Fabio Berton
  2016-11-17 16:00 ` Christopher Larson
  2016-11-17 22:50 ` Martin Jansa
  0 siblings, 2 replies; 11+ messages in thread
From: Fabio Berton @ 2016-11-17 15:26 UTC (permalink / raw)
  To: openembedded-core

Add patches to fix error:
/
| ERROR: oe_runmake failed
| config.status: creating pcap-config.tmp
| mv pcap-config.tmp pcap-config
| chmod a+x pcap-config
| ../libpcap-1.8.1/gencode.c: In function 'pcap_compile':
| ../libpcap-1.8.1/gencode.c:693:8: error: 'compiler_state_t
| {aka struct _compiler_state}' has no member named 'ai'
|   cstate.ai = NULL;
|         ^
| ../libpcap-1.8.1/gencode.c: In function 'gen_gateway':
| ../libpcap-1.8.1/gencode.c:4914:13: error: 'cstate' undeclared
| (first use in this function)
|    bpf_error(cstate, "direction applied to 'gateway'");
|              ^~~~~~
| ../libpcap-1.8.1/gencode.c:4914:13: note: each undeclared identifier is
| reported only once for each function it appears in
\

Patches were submitted to upstream [1]

[1] https://github.com/the-tcpdump-group/libpcap/pull/541

Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
---
 ...r_state_t.ai-usage-when-INET6-is-not-defi.patch | 41 +++++++++++++
 ...02-Add-missing-compiler_state_t-parameter.patch | 67 ++++++++++++++++++++++
 meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb |  2 +
 3 files changed, 110 insertions(+)
 create mode 100644 meta/recipes-connectivity/libpcap/libpcap/0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch
 create mode 100644 meta/recipes-connectivity/libpcap/libpcap/0002-Add-missing-compiler_state_t-parameter.patch

diff --git a/meta/recipes-connectivity/libpcap/libpcap/0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch b/meta/recipes-connectivity/libpcap/libpcap/0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch
new file mode 100644
index 0000000..edb6ae5
--- /dev/null
+++ b/meta/recipes-connectivity/libpcap/libpcap/0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch
@@ -0,0 +1,41 @@
+From 64aa033a061c43fc15c711f2490ae41d23b868c3 Mon Sep 17 00:00:00 2001
+From: Fabio Berton <fabio.berton@ossystems.com.br>
+Date: Thu, 17 Nov 2016 09:44:42 -0200
+Subject: [PATCH 1/2] Fix compiler_state_t.ai usage when INET6 is not defined
+Organization: O.S. Systems Software LTDA.
+
+Fix error:
+
+/
+| ../libpcap-1.8.1/gencode.c: In function 'pcap_compile':
+| ../libpcap-1.8.1/gencode.c:693:8: error: 'compiler_state_t
+| {aka struct _compiler_state}' has no member named 'ai'
+|   cstate.ai = NULL;
+\
+
+Upstream-Status: Submitted [1]
+
+[1] https://github.com/the-tcpdump-group/libpcap/pull/541
+
+Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
+---
+ gencode.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/gencode.c b/gencode.c
+index a887f27..e103c70 100644
+--- a/gencode.c
++++ b/gencode.c
+@@ -690,7 +690,9 @@ pcap_compile(pcap_t *p, struct bpf_program *program,
+ 	}
+ 	initchunks(&cstate);
+ 	cstate.no_optimize = 0;
++#ifdef INET6
+ 	cstate.ai = NULL;
++#endif
+ 	cstate.ic.root = NULL;
+ 	cstate.ic.cur_mark = 0;
+ 	cstate.bpf_pcap = p;
+-- 
+2.1.4
+
diff --git a/meta/recipes-connectivity/libpcap/libpcap/0002-Add-missing-compiler_state_t-parameter.patch b/meta/recipes-connectivity/libpcap/libpcap/0002-Add-missing-compiler_state_t-parameter.patch
new file mode 100644
index 0000000..032b265
--- /dev/null
+++ b/meta/recipes-connectivity/libpcap/libpcap/0002-Add-missing-compiler_state_t-parameter.patch
@@ -0,0 +1,67 @@
+From 50ec0a088d5924a8305b2d70dcba71b0942dee1a Mon Sep 17 00:00:00 2001
+From: Fabio Berton <fabio.berton@ossystems.com.br>
+Date: Thu, 17 Nov 2016 09:47:29 -0200
+Subject: [PATCH 2/2] Add missing compiler_state_t parameter
+Organization: O.S. Systems Software LTDA.
+
+Fix error:
+
+/
+|../libpcap-1.8.1/gencode.c: In function 'gen_gateway':
+|../libpcap-1.8.1/gencode.c:4914:13: error: 'cstate' undeclared
+| (first use in this function)
+|    bpf_error(cstate, "direction applied to 'gateway'");
+\
+
+Upstream-Status: Submitted [1]
+
+[1] https://github.com/the-tcpdump-group/libpcap/pull/541
+
+Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
+---
+ gencode.c | 15 ++++++++-------
+ 1 file changed, 8 insertions(+), 7 deletions(-)
+
+diff --git a/gencode.c b/gencode.c
+index e103c70..f07c0be 100644
+--- a/gencode.c
++++ b/gencode.c
+@@ -523,7 +523,7 @@ static struct block *gen_host6(compiler_state_t *, struct in6_addr *,
+     struct in6_addr *, int, int, int);
+ #endif
+ #ifndef INET6
+-static struct block *gen_gateway(const u_char *, bpf_u_int32 **, int, int);
++static struct block *gen_gateway(compiler_state_t *, const u_char *, bpf_u_int32 **, int, int);
+ #endif
+ static struct block *gen_ipfrag(compiler_state_t *);
+ static struct block *gen_portatom(compiler_state_t *, int, bpf_int32);
+@@ -4904,11 +4904,12 @@ gen_host6(compiler_state_t *cstate, struct in6_addr *addr,
+ 
+ #ifndef INET6
+ static struct block *
+-gen_gateway(eaddr, alist, proto, dir)
+-	const u_char *eaddr;
+-	bpf_u_int32 **alist;
+-	int proto;
+-	int dir;
++gen_gateway(cstate, eaddr, alist, proto, dir)
++    compiler_state_t *cstate;
++    const u_char *eaddr;
++    bpf_u_int32 **alist;
++    int proto;
++    int dir;
+ {
+ 	struct block *b0, *b1, *tmp;
+ 
+@@ -6472,7 +6473,7 @@ gen_scode(compiler_state_t *cstate, const char *name, struct qual q)
+ 		alist = pcap_nametoaddr(name);
+ 		if (alist == NULL || *alist == NULL)
+ 			bpf_error(cstate, "unknown host '%s'", name);
+-		b = gen_gateway(eaddr, alist, proto, dir);
++		b = gen_gateway(cstate, eaddr, alist, proto, dir);
+ 		free(eaddr);
+ 		return b;
+ #else
+-- 
+2.1.4
+
diff --git a/meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb b/meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb
index 9072fe0..e9db28a 100644
--- a/meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb
+++ b/meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb
@@ -2,6 +2,8 @@ require libpcap.inc
 
 SRC_URI += " \
     file://libpcap-pkgconfig-support.patch \
+    file://0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch \
+    file://0002-Add-missing-compiler_state_t-parameter.patch \
 "
 
 SRC_URI[md5sum] = "3d48f9cd171ff12b0efd9134b52f1447"
-- 
2.1.4



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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-17 15:26 [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable Fabio Berton
@ 2016-11-17 16:00 ` Christopher Larson
  2016-11-17 16:11   ` Fabio Berton
  2016-11-17 22:50 ` Martin Jansa
  1 sibling, 1 reply; 11+ messages in thread
From: Christopher Larson @ 2016-11-17 16:00 UTC (permalink / raw)
  To: Fabio Berton; +Cc: Patches and discussions about the oe-core layer

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

On Thu, Nov 17, 2016 at 8:26 AM, Fabio Berton <fabio.berton@ossystems.com.br
> wrote:

> Add patches to fix error:
> /
> | ERROR: oe_runmake failed
> | config.status: creating pcap-config.tmp
> | mv pcap-config.tmp pcap-config
> | chmod a+x pcap-config
> | ../libpcap-1.8.1/gencode.c: In function 'pcap_compile':
> | ../libpcap-1.8.1/gencode.c:693:8: error: 'compiler_state_t
> | {aka struct _compiler_state}' has no member named 'ai'
> |   cstate.ai = NULL;
> |         ^
> | ../libpcap-1.8.1/gencode.c: In function 'gen_gateway':
> | ../libpcap-1.8.1/gencode.c:4914:13: error: 'cstate' undeclared
> | (first use in this function)
> |    bpf_error(cstate, "direction applied to 'gateway'");
> |              ^~~~~~
> | ../libpcap-1.8.1/gencode.c:4914:13: note: each undeclared identifier is
> | reported only once for each function it appears in
> \
>
> Patches were submitted to upstream [1]
>
> [1] https://github.com/the-tcpdump-group/libpcap/pull/541
>
> Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
>

This is fairly common, but afaik the Upstream-Status is an artifact of the
patch, not the commit that generated the patch, so belongs outside (above)
the commit message in the patch file.
-- 
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics

[-- Attachment #2: Type: text/html, Size: 2205 bytes --]

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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-17 16:00 ` Christopher Larson
@ 2016-11-17 16:11   ` Fabio Berton
  2016-11-17 16:15     ` Christopher Larson
  0 siblings, 1 reply; 11+ messages in thread
From: Fabio Berton @ 2016-11-17 16:11 UTC (permalink / raw)
  To: Christopher Larson; +Cc: Patches and discussions about the oe-core layer

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

Hi Chistopher,

Patches in this commit have Upstream-Status: Submitted tag.

Thanks.

On Thu, Nov 17, 2016 at 2:00 PM, Christopher Larson <clarson@kergoth.com>
wrote:

>
> On Thu, Nov 17, 2016 at 8:26 AM, Fabio Berton <
> fabio.berton@ossystems.com.br> wrote:
>
>> Add patches to fix error:
>> /
>> | ERROR: oe_runmake failed
>> | config.status: creating pcap-config.tmp
>> | mv pcap-config.tmp pcap-config
>> | chmod a+x pcap-config
>> | ../libpcap-1.8.1/gencode.c: In function 'pcap_compile':
>> | ../libpcap-1.8.1/gencode.c:693:8: error: 'compiler_state_t
>> | {aka struct _compiler_state}' has no member named 'ai'
>> |   cstate.ai = NULL;
>> |         ^
>> | ../libpcap-1.8.1/gencode.c: In function 'gen_gateway':
>> | ../libpcap-1.8.1/gencode.c:4914:13: error: 'cstate' undeclared
>> | (first use in this function)
>> |    bpf_error(cstate, "direction applied to 'gateway'");
>> |              ^~~~~~
>> | ../libpcap-1.8.1/gencode.c:4914:13: note: each undeclared identifier is
>> | reported only once for each function it appears in
>> \
>>
>> Patches were submitted to upstream [1]
>>
>> [1] https://github.com/the-tcpdump-group/libpcap/pull/541
>>
>> Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
>>
>
> This is fairly common, but afaik the Upstream-Status is an artifact of the
> patch, not the commit that generated the patch, so belongs outside (above)
> the commit message in the patch file.
> --
> Christopher Larson
> clarson at kergoth dot com
> Founder - BitBake, OpenEmbedded, OpenZaurus
> Maintainer - Tslib
> Senior Software Engineer, Mentor Graphics
>

[-- Attachment #2: Type: text/html, Size: 3155 bytes --]

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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-17 16:11   ` Fabio Berton
@ 2016-11-17 16:15     ` Christopher Larson
  2016-11-17 16:21       ` Fabio Berton
  0 siblings, 1 reply; 11+ messages in thread
From: Christopher Larson @ 2016-11-17 16:15 UTC (permalink / raw)
  To: Fabio Berton; +Cc: Patches and discussions about the oe-core layer

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

On Thu, Nov 17, 2016 at 9:11 AM, Fabio Berton <fabio.berton@ossystems.com.br
> wrote:

> Patches in this commit have Upstream-Status: Submitted tag.
>

I know, the point was the tag was within the commit message in the patch,
not just the patch file — wrong location within the patch file. Is the
Upstream-Status tag in the commits you submitted upstream? Unlikely, it’s
oe-specific metadata.
-- 
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics

[-- Attachment #2: Type: text/html, Size: 1031 bytes --]

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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-17 16:15     ` Christopher Larson
@ 2016-11-17 16:21       ` Fabio Berton
  2016-11-17 16:24         ` Christopher Larson
  0 siblings, 1 reply; 11+ messages in thread
From: Fabio Berton @ 2016-11-17 16:21 UTC (permalink / raw)
  To: Christopher Larson; +Cc: Patches and discussions about the oe-core layer

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

No, I created a patch, git format-patch and then edit generated files with
Upstream-Status tag and added to recipe. Is this wrong?

On Thu, Nov 17, 2016 at 2:15 PM, Christopher Larson <clarson@kergoth.com>
wrote:

>
> On Thu, Nov 17, 2016 at 9:11 AM, Fabio Berton <
> fabio.berton@ossystems.com.br> wrote:
>
>> Patches in this commit have Upstream-Status: Submitted tag.
>>
>
> I know, the point was the tag was within the commit message in the patch,
> not just the patch file — wrong location within the patch file. Is the
> Upstream-Status tag in the commits you submitted upstream? Unlikely, it’s
> oe-specific metadata.
> --
> Christopher Larson
> clarson at kergoth dot com
> Founder - BitBake, OpenEmbedded, OpenZaurus
> Maintainer - Tslib
> Senior Software Engineer, Mentor Graphics
>

[-- Attachment #2: Type: text/html, Size: 1703 bytes --]

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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-17 16:21       ` Fabio Berton
@ 2016-11-17 16:24         ` Christopher Larson
  2016-11-18 12:34           ` Patrick Ohly
  2016-11-23 10:00           ` Otavio Salvador
  0 siblings, 2 replies; 11+ messages in thread
From: Christopher Larson @ 2016-11-17 16:24 UTC (permalink / raw)
  To: Fabio Berton; +Cc: Patches and discussions about the oe-core layer

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

On Thu, Nov 17, 2016 at 9:21 AM, Fabio Berton <fabio.berton@ossystems.com.br
> wrote:

> No, I created a patch, git format-patch and then edit generated files with
> Upstream-Status tag and added to recipe. Is this wrong?


As I indicated in my first reply, it’s best to put the tag outside the
generated patch (above it, or below the —-), as it isn’t part of the
commit, only part of the patch file. It’s minor, and you don’t need to
re-submit, but in general the tag is not part of the commit message. For
example, if your patch was applied to a git repository with git-am, it’d be
in the commit message, which should not be the case.
-- 
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics

[-- Attachment #2: Type: text/html, Size: 1189 bytes --]

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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-17 15:26 [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable Fabio Berton
  2016-11-17 16:00 ` Christopher Larson
@ 2016-11-17 22:50 ` Martin Jansa
  1 sibling, 0 replies; 11+ messages in thread
From: Martin Jansa @ 2016-11-17 22:50 UTC (permalink / raw)
  To: Fabio Berton; +Cc: openembedded-core

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

On Thu, Nov 17, 2016 at 01:26:34PM -0200, Fabio Berton wrote:
> Add patches to fix error:
> /
> | ERROR: oe_runmake failed
> | config.status: creating pcap-config.tmp
> | mv pcap-config.tmp pcap-config
> | chmod a+x pcap-config
> | ../libpcap-1.8.1/gencode.c: In function 'pcap_compile':
> | ../libpcap-1.8.1/gencode.c:693:8: error: 'compiler_state_t
> | {aka struct _compiler_state}' has no member named 'ai'
> |   cstate.ai = NULL;
> |         ^
> | ../libpcap-1.8.1/gencode.c: In function 'gen_gateway':
> | ../libpcap-1.8.1/gencode.c:4914:13: error: 'cstate' undeclared
> | (first use in this function)
> |    bpf_error(cstate, "direction applied to 'gateway'");
> |              ^~~~~~
> | ../libpcap-1.8.1/gencode.c:4914:13: note: each undeclared identifier is
> | reported only once for each function it appears in
> \

Thanks!

> 
> Patches were submitted to upstream [1]
> 
> [1] https://github.com/the-tcpdump-group/libpcap/pull/541
> 
> Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
> ---
>  ...r_state_t.ai-usage-when-INET6-is-not-defi.patch | 41 +++++++++++++
>  ...02-Add-missing-compiler_state_t-parameter.patch | 67 ++++++++++++++++++++++
>  meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb |  2 +
>  3 files changed, 110 insertions(+)
>  create mode 100644 meta/recipes-connectivity/libpcap/libpcap/0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch
>  create mode 100644 meta/recipes-connectivity/libpcap/libpcap/0002-Add-missing-compiler_state_t-parameter.patch
> 
> diff --git a/meta/recipes-connectivity/libpcap/libpcap/0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch b/meta/recipes-connectivity/libpcap/libpcap/0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch
> new file mode 100644
> index 0000000..edb6ae5
> --- /dev/null
> +++ b/meta/recipes-connectivity/libpcap/libpcap/0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch
> @@ -0,0 +1,41 @@
> +From 64aa033a061c43fc15c711f2490ae41d23b868c3 Mon Sep 17 00:00:00 2001
> +From: Fabio Berton <fabio.berton@ossystems.com.br>
> +Date: Thu, 17 Nov 2016 09:44:42 -0200
> +Subject: [PATCH 1/2] Fix compiler_state_t.ai usage when INET6 is not defined
> +Organization: O.S. Systems Software LTDA.
> +
> +Fix error:
> +
> +/
> +| ../libpcap-1.8.1/gencode.c: In function 'pcap_compile':
> +| ../libpcap-1.8.1/gencode.c:693:8: error: 'compiler_state_t
> +| {aka struct _compiler_state}' has no member named 'ai'
> +|   cstate.ai = NULL;
> +\
> +
> +Upstream-Status: Submitted [1]
> +
> +[1] https://github.com/the-tcpdump-group/libpcap/pull/541
> +
> +Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
> +---
> + gencode.c | 2 ++
> + 1 file changed, 2 insertions(+)
> +
> +diff --git a/gencode.c b/gencode.c
> +index a887f27..e103c70 100644
> +--- a/gencode.c
> ++++ b/gencode.c
> +@@ -690,7 +690,9 @@ pcap_compile(pcap_t *p, struct bpf_program *program,
> + 	}
> + 	initchunks(&cstate);
> + 	cstate.no_optimize = 0;
> ++#ifdef INET6
> + 	cstate.ai = NULL;
> ++#endif
> + 	cstate.ic.root = NULL;
> + 	cstate.ic.cur_mark = 0;
> + 	cstate.bpf_pcap = p;
> +-- 
> +2.1.4
> +
> diff --git a/meta/recipes-connectivity/libpcap/libpcap/0002-Add-missing-compiler_state_t-parameter.patch b/meta/recipes-connectivity/libpcap/libpcap/0002-Add-missing-compiler_state_t-parameter.patch
> new file mode 100644
> index 0000000..032b265
> --- /dev/null
> +++ b/meta/recipes-connectivity/libpcap/libpcap/0002-Add-missing-compiler_state_t-parameter.patch
> @@ -0,0 +1,67 @@
> +From 50ec0a088d5924a8305b2d70dcba71b0942dee1a Mon Sep 17 00:00:00 2001
> +From: Fabio Berton <fabio.berton@ossystems.com.br>
> +Date: Thu, 17 Nov 2016 09:47:29 -0200
> +Subject: [PATCH 2/2] Add missing compiler_state_t parameter
> +Organization: O.S. Systems Software LTDA.
> +
> +Fix error:
> +
> +/
> +|../libpcap-1.8.1/gencode.c: In function 'gen_gateway':
> +|../libpcap-1.8.1/gencode.c:4914:13: error: 'cstate' undeclared
> +| (first use in this function)
> +|    bpf_error(cstate, "direction applied to 'gateway'");
> +\
> +
> +Upstream-Status: Submitted [1]
> +
> +[1] https://github.com/the-tcpdump-group/libpcap/pull/541
> +
> +Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
> +---
> + gencode.c | 15 ++++++++-------
> + 1 file changed, 8 insertions(+), 7 deletions(-)
> +
> +diff --git a/gencode.c b/gencode.c
> +index e103c70..f07c0be 100644
> +--- a/gencode.c
> ++++ b/gencode.c
> +@@ -523,7 +523,7 @@ static struct block *gen_host6(compiler_state_t *, struct in6_addr *,
> +     struct in6_addr *, int, int, int);
> + #endif
> + #ifndef INET6
> +-static struct block *gen_gateway(const u_char *, bpf_u_int32 **, int, int);
> ++static struct block *gen_gateway(compiler_state_t *, const u_char *, bpf_u_int32 **, int, int);
> + #endif
> + static struct block *gen_ipfrag(compiler_state_t *);
> + static struct block *gen_portatom(compiler_state_t *, int, bpf_int32);
> +@@ -4904,11 +4904,12 @@ gen_host6(compiler_state_t *cstate, struct in6_addr *addr,
> + 
> + #ifndef INET6
> + static struct block *
> +-gen_gateway(eaddr, alist, proto, dir)
> +-	const u_char *eaddr;
> +-	bpf_u_int32 **alist;
> +-	int proto;
> +-	int dir;
> ++gen_gateway(cstate, eaddr, alist, proto, dir)
> ++    compiler_state_t *cstate;
> ++    const u_char *eaddr;
> ++    bpf_u_int32 **alist;
> ++    int proto;
> ++    int dir;
> + {
> + 	struct block *b0, *b1, *tmp;
> + 
> +@@ -6472,7 +6473,7 @@ gen_scode(compiler_state_t *cstate, const char *name, struct qual q)
> + 		alist = pcap_nametoaddr(name);
> + 		if (alist == NULL || *alist == NULL)
> + 			bpf_error(cstate, "unknown host '%s'", name);
> +-		b = gen_gateway(eaddr, alist, proto, dir);
> ++		b = gen_gateway(cstate, eaddr, alist, proto, dir);
> + 		free(eaddr);
> + 		return b;
> + #else
> +-- 
> +2.1.4
> +
> diff --git a/meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb b/meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb
> index 9072fe0..e9db28a 100644
> --- a/meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb
> +++ b/meta/recipes-connectivity/libpcap/libpcap_1.8.1.bb
> @@ -2,6 +2,8 @@ require libpcap.inc
>  
>  SRC_URI += " \
>      file://libpcap-pkgconfig-support.patch \
> +    file://0001-Fix-compiler_state_t.ai-usage-when-INET6-is-not-defi.patch \
> +    file://0002-Add-missing-compiler_state_t-parameter.patch \
>  "
>  
>  SRC_URI[md5sum] = "3d48f9cd171ff12b0efd9134b52f1447"
> -- 
> 2.1.4
> 
> -- 
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 169 bytes --]

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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-17 16:24         ` Christopher Larson
@ 2016-11-18 12:34           ` Patrick Ohly
  2016-11-23 10:00           ` Otavio Salvador
  1 sibling, 0 replies; 11+ messages in thread
From: Patrick Ohly @ 2016-11-18 12:34 UTC (permalink / raw)
  To: Christopher Larson; +Cc: Patches and discussions about the oe-core layer

On Thu, 2016-11-17 at 09:24 -0700, Christopher Larson wrote:
> 
> On Thu, Nov 17, 2016 at 9:21 AM, Fabio Berton
> <fabio.berton@ossystems.com.br> wrote:
>         No, I created a patch, git format-patch and then edit
>         generated files with Upstream-Status tag and added to recipe.
>         Is this wrong?
> 
> As I indicated in my first reply, it’s best to put the tag outside the
> generated patch (above it, or below the —-), as it isn’t part of the
> commit, only part of the patch file.

Now I'm confused. My understanding was that
http://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines#Patch_Header_Recommendations explicitly asks for Upstream-Status in the patch header.

Taking an existing example, is
http://cgit.openembedded.org/openembedded-core/tree/meta/recipes-core/systemd/systemd/0001-core-device.c-Change-the-default-device-timeout-to-2.patch doing it wrong?

>  It’s minor, and you don’t need to re-submit, but in general the tag
> is not part of the commit message. For example, if your patch was
> applied to a git repository with git-am, it’d be in the commit
> message, which should not be the case.

Yes, that's indeed the effect. That has pros (the Upstream-Status tag is
preserved when working with devtool) and cons (patch as attached to a
recipe is not the same as the patch upstream).

-- 
Best Regards, Patrick Ohly

The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.





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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-17 16:24         ` Christopher Larson
  2016-11-18 12:34           ` Patrick Ohly
@ 2016-11-23 10:00           ` Otavio Salvador
  2016-11-23 13:41             ` Christopher Larson
  1 sibling, 1 reply; 11+ messages in thread
From: Otavio Salvador @ 2016-11-23 10:00 UTC (permalink / raw)
  To: Christopher Larson; +Cc: Patches and discussions about the oe-core layer

On Thu, Nov 17, 2016 at 2:24 PM, Christopher Larson <clarson@kergoth.com> wrote:
>
> On Thu, Nov 17, 2016 at 9:21 AM, Fabio Berton
> <fabio.berton@ossystems.com.br> wrote:
>>
>> No, I created a patch, git format-patch and then edit generated files with
>> Upstream-Status tag and added to recipe. Is this wrong?
>
>
> As I indicated in my first reply, it’s best to put the tag outside the
> generated patch (above it, or below the —-), as it isn’t part of the commit,
> only part of the patch file. It’s minor, and you don’t need to re-submit,
> but in general the tag is not part of the commit message. For example, if
> your patch was applied to a git repository with git-am, it’d be in the
> commit message, which should not be the case.

To be honest, there a many files which does as Fabio did and I also
personally do as well. I don't like it outside of the commit log as it
looks out of context.

If someone is getting the patch file, it is expected they will review
it and not blindly apply it on upstream repository.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750


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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-23 10:00           ` Otavio Salvador
@ 2016-11-23 13:41             ` Christopher Larson
  2016-11-23 13:57               ` Otavio Salvador
  0 siblings, 1 reply; 11+ messages in thread
From: Christopher Larson @ 2016-11-23 13:41 UTC (permalink / raw)
  To: Otavio Salvador; +Cc: Patches and discussions about the oe-core layer

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

On Wed, Nov 23, 2016 at 3:00 AM, Otavio Salvador <
otavio.salvador@ossystems.com.br> wrote:

> On Thu, Nov 17, 2016 at 2:24 PM, Christopher Larson <clarson@kergoth.com>
> wrote:
> >
> > On Thu, Nov 17, 2016 at 9:21 AM, Fabio Berton
> > <fabio.berton@ossystems.com.br> wrote:
> >>
> >> No, I created a patch, git format-patch and then edit generated files
> with
> >> Upstream-Status tag and added to recipe. Is this wrong?
> >
> >
> > As I indicated in my first reply, it’s best to put the tag outside the
> > generated patch (above it, or below the —-), as it isn’t part of the
> commit,
> > only part of the patch file. It’s minor, and you don’t need to re-submit,
> > but in general the tag is not part of the commit message. For example, if
> > your patch was applied to a git repository with git-am, it’d be in the
> > commit message, which should not be the case.
>
> To be honest, there a many files which does as Fabio did and I also
> personally do as well. I don't like it outside of the commit log as it
> looks out of context.
>
> If someone is getting the patch file, it is expected they will review
> it and not blindly apply it on upstream repository.


I don’t feel too strongly about it, if that’s the consensus, that’s fine, I
just wanted to open up a dialogue on the subject. Thanks.
-- 
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics

[-- Attachment #2: Type: text/html, Size: 2111 bytes --]

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

* Re: [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable
  2016-11-23 13:41             ` Christopher Larson
@ 2016-11-23 13:57               ` Otavio Salvador
  0 siblings, 0 replies; 11+ messages in thread
From: Otavio Salvador @ 2016-11-23 13:57 UTC (permalink / raw)
  To: Christopher Larson; +Cc: Patches and discussions about the oe-core layer

On Wed, Nov 23, 2016 at 11:41 AM, Christopher Larson
<clarson@kergoth.com> wrote:
>
> On Wed, Nov 23, 2016 at 3:00 AM, Otavio Salvador
> <otavio.salvador@ossystems.com.br> wrote:
>>
>> On Thu, Nov 17, 2016 at 2:24 PM, Christopher Larson <clarson@kergoth.com>
>> wrote:
>> >
>> > On Thu, Nov 17, 2016 at 9:21 AM, Fabio Berton
>> > <fabio.berton@ossystems.com.br> wrote:
>> >>
>> >> No, I created a patch, git format-patch and then edit generated files
>> >> with
>> >> Upstream-Status tag and added to recipe. Is this wrong?
>> >
>> >
>> > As I indicated in my first reply, it’s best to put the tag outside the
>> > generated patch (above it, or below the —-), as it isn’t part of the
>> > commit,
>> > only part of the patch file. It’s minor, and you don’t need to
>> > re-submit,
>> > but in general the tag is not part of the commit message. For example,
>> > if
>> > your patch was applied to a git repository with git-am, it’d be in the
>> > commit message, which should not be the case.
>>
>> To be honest, there a many files which does as Fabio did and I also
>> personally do as well. I don't like it outside of the commit log as it
>> looks out of context.
>>
>> If someone is getting the patch file, it is expected they will review
>> it and not blindly apply it on upstream repository.
>
>
> I don’t feel too strongly about it, if that’s the consensus, that’s fine, I
> just wanted to open up a dialogue on the subject. Thanks.

Me too; but if this need change we need:

 - update the guidelines
 - migrate current patches to use the new format
 - ask Richard and other reviewers to start to enforce the new policy

In any case, I think this is not needed. The current way is good enough for me.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750


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

end of thread, other threads:[~2016-11-23 13:57 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-17 15:26 [PATCH] libpcap: Fix build when PACKAGECONFIG ipv6 is not enable Fabio Berton
2016-11-17 16:00 ` Christopher Larson
2016-11-17 16:11   ` Fabio Berton
2016-11-17 16:15     ` Christopher Larson
2016-11-17 16:21       ` Fabio Berton
2016-11-17 16:24         ` Christopher Larson
2016-11-18 12:34           ` Patrick Ohly
2016-11-23 10:00           ` Otavio Salvador
2016-11-23 13:41             ` Christopher Larson
2016-11-23 13:57               ` Otavio Salvador
2016-11-17 22:50 ` Martin Jansa

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.