Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] package/ngrep: fix implicit function declaration
@ 2025-08-02 11:37 Thomas Bonnefille via buildroot
  2025-08-02 20:03 ` Thomas Perale via buildroot
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Thomas Bonnefille via buildroot @ 2025-08-02 11:37 UTC (permalink / raw)
  To: buildroot
  Cc: Thomas Petazzoni, Miquèl Raynal, Wade Berrier,
	Florian Weimer, Thomas Bonnefille

Fixes: https://autobuild.buildroot.org/results/20b/20b924c5c96b3f43e381d87e59fb160ba8d3dcd0//

Signed-off-by: Thomas Bonnefille <thomas.bonnefille@bootlin.com>
---
This patch can be backported to 2025.02.x as this issue is reproducible
on the current version of the LTS.
---
 ....h-and-tcpkill.h-to-avoid-implicit-functi.patch | 44 ++++++++++++++++++++++
 1 file changed, 44 insertions(+)

diff --git a/package/ngrep/0006-Include-err.h-and-tcpkill.h-to-avoid-implicit-functi.patch b/package/ngrep/0006-Include-err.h-and-tcpkill.h-to-avoid-implicit-functi.patch
new file mode 100644
index 0000000000000000000000000000000000000000..6d596bfe3791a33994179494e8c08ec7a9439975
--- /dev/null
+++ b/package/ngrep/0006-Include-err.h-and-tcpkill.h-to-avoid-implicit-functi.patch
@@ -0,0 +1,44 @@
+From 52515bae377f221b5473d9040f5f43ab1c672672 Mon Sep 17 00:00:00 2001
+From: Florian Weimer <fweimer@redhat.com>
+Date: Mon, 19 Dec 2022 11:49:06 +0100
+Subject: [PATCH] Include <err.h> and "tcpkill.h" to avoid implicit function
+ declarations
+
+Implicit function declarations are a historic language feature that
+were removed from C in 1999.
+
+Upstream: https://github.com/jpr5/ngrep/pull/28
+
+Signed-off-by: Thomas Bonnefille <thomas.bonnefille@bootlin.com>
+---
+ ngrep.c   | 1 +
+ tcpkill.c | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/ngrep.c b/ngrep.c
+index 3df9389..b2fcceb 100644
+--- a/ngrep.c
++++ b/ngrep.c
+@@ -98,6 +98,7 @@
+ #endif
+ 
+ #include "ngrep.h"
++#include "tcpkill.h"
+ 
+ 
+ /*
+diff --git a/tcpkill.c b/tcpkill.c
+index 5388ec5..ac8fd2e 100644
+--- a/tcpkill.c
++++ b/tcpkill.c
+@@ -14,6 +14,7 @@
+ #include <stdlib.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <err.h>
+ #include <libnet.h>
+ #include <pcap.h>
+ 
+-- 
+2.50.1
+

---
base-commit: f5101638b9f917dc4c569828ff3fee0c486ba8f8
change-id: 20250802-fix_ngrep-59ab75bf5919

Best regards,
-- 
Thomas Bonnefille <thomas.bonnefille@bootlin.com>

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

* Re: [Buildroot] [PATCH] package/ngrep: fix implicit function declaration
  2025-08-02 11:37 [Buildroot] [PATCH] package/ngrep: fix implicit function declaration Thomas Bonnefille via buildroot
@ 2025-08-02 20:03 ` Thomas Perale via buildroot
  2025-08-09 21:52 ` Romain Naour via buildroot
  2025-08-14 20:31 ` Thomas Perale via buildroot
  2 siblings, 0 replies; 6+ messages in thread
From: Thomas Perale via buildroot @ 2025-08-02 20:03 UTC (permalink / raw)
  To: Thomas Bonnefille
  Cc: Thomas Perale, buildroot, Thomas Petazzoni, Miquèl Raynal,
	Wade Berrier, Florian Weimer

> This patch can be backported to 2025.02.x as this issue is reproducible
> on the current version of the LTS.

Hi,

Thanks for including this note Thomas, appreciate it.

Regards,
Thomas Perale
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

* Re: [Buildroot] [PATCH] package/ngrep: fix implicit function declaration
  2025-08-02 11:37 [Buildroot] [PATCH] package/ngrep: fix implicit function declaration Thomas Bonnefille via buildroot
  2025-08-02 20:03 ` Thomas Perale via buildroot
@ 2025-08-09 21:52 ` Romain Naour via buildroot
  2025-08-10 10:49   ` Thomas Petazzoni via buildroot
  2025-08-14 20:31 ` Thomas Perale via buildroot
  2 siblings, 1 reply; 6+ messages in thread
From: Romain Naour via buildroot @ 2025-08-09 21:52 UTC (permalink / raw)
  To: Thomas Bonnefille, buildroot
  Cc: Thomas Petazzoni, Miquèl Raynal, Wade Berrier,
	Florian Weimer

Hello Thomas, All,

Le 02/08/2025 à 13:37, Thomas Bonnefille via buildroot a écrit :
> Fixes: https://autobuild.buildroot.org/results/20b/20b924c5c96b3f43e381d87e59fb160ba8d3dcd0//

Please, can you provide your analysis on this issue?

From the patch, I understand that it's an error generated by gcc-14 (an newer).
But ngrep package fail to build only when BR2_PACKAGE_LIBNET is selected.

I updated the commit log with a defconfig and the minimal gcc version to
reproduce the issue.

Best regards,
Romain


> 
> Signed-off-by: Thomas Bonnefille <thomas.bonnefille@bootlin.com>
> ---
> This patch can be backported to 2025.02.x as this issue is reproducible
> on the current version of the LTS.
> ---
>  ....h-and-tcpkill.h-to-avoid-implicit-functi.patch | 44 ++++++++++++++++++++++
>  1 file changed, 44 insertions(+)
> 
> diff --git a/package/ngrep/0006-Include-err.h-and-tcpkill.h-to-avoid-implicit-functi.patch b/package/ngrep/0006-Include-err.h-and-tcpkill.h-to-avoid-implicit-functi.patch
> new file mode 100644
> index 0000000000000000000000000000000000000000..6d596bfe3791a33994179494e8c08ec7a9439975
> --- /dev/null
> +++ b/package/ngrep/0006-Include-err.h-and-tcpkill.h-to-avoid-implicit-functi.patch
> @@ -0,0 +1,44 @@
> +From 52515bae377f221b5473d9040f5f43ab1c672672 Mon Sep 17 00:00:00 2001
> +From: Florian Weimer <fweimer@redhat.com>
> +Date: Mon, 19 Dec 2022 11:49:06 +0100
> +Subject: [PATCH] Include <err.h> and "tcpkill.h" to avoid implicit function
> + declarations
> +
> +Implicit function declarations are a historic language feature that
> +were removed from C in 1999.
> +
> +Upstream: https://github.com/jpr5/ngrep/pull/28
> +
> +Signed-off-by: Thomas Bonnefille <thomas.bonnefille@bootlin.com>
> +---
> + ngrep.c   | 1 +
> + tcpkill.c | 1 +
> + 2 files changed, 2 insertions(+)
> +
> +diff --git a/ngrep.c b/ngrep.c
> +index 3df9389..b2fcceb 100644
> +--- a/ngrep.c
> ++++ b/ngrep.c
> +@@ -98,6 +98,7 @@
> + #endif
> + 
> + #include "ngrep.h"
> ++#include "tcpkill.h"
> + 
> + 
> + /*
> +diff --git a/tcpkill.c b/tcpkill.c
> +index 5388ec5..ac8fd2e 100644
> +--- a/tcpkill.c
> ++++ b/tcpkill.c
> +@@ -14,6 +14,7 @@
> + #include <stdlib.h>
> + #include <unistd.h>
> + #include <string.h>
> ++#include <err.h>
> + #include <libnet.h>
> + #include <pcap.h>
> + 
> +-- 
> +2.50.1
> +
> 
> ---
> base-commit: f5101638b9f917dc4c569828ff3fee0c486ba8f8
> change-id: 20250802-fix_ngrep-59ab75bf5919
> 
> Best regards,

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

* Re: [Buildroot] [PATCH] package/ngrep: fix implicit function declaration
  2025-08-09 21:52 ` Romain Naour via buildroot
@ 2025-08-10 10:49   ` Thomas Petazzoni via buildroot
  2025-08-10 13:27     ` Romain Naour via buildroot
  0 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni via buildroot @ 2025-08-10 10:49 UTC (permalink / raw)
  To: Romain Naour
  Cc: Thomas Bonnefille, buildroot, Miquèl Raynal, Wade Berrier,
	Florian Weimer

Hello Romain,

Thanks for the review, but something is not clear. See below.

On Sat, 9 Aug 2025 23:52:55 +0200
Romain Naour <romain.naour@smile.fr> wrote:

> Hello Thomas, All,
> 
> Le 02/08/2025 à 13:37, Thomas Bonnefille via buildroot a écrit :
> > Fixes: https://autobuild.buildroot.org/results/20b/20b924c5c96b3f43e381d87e59fb160ba8d3dcd0//  
> 
> Please, can you provide your analysis on this issue?
> 
> From the patch, I understand that it's an error generated by gcc-14 (an newer).
> But ngrep package fail to build only when BR2_PACKAGE_LIBNET is selected.

So you ask for more details (which would encourage the submitter to
send a new version of the patch)...

> I updated the commit log with a defconfig and the minimal gcc version to
> reproduce the issue.

... but you say you have already updated the commit log with more
details. So? Did you already apply the patch and sending a new
iteration is not needed, or?

Thanks!

Thomas
-- 
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

* Re: [Buildroot] [PATCH] package/ngrep: fix implicit function declaration
  2025-08-10 10:49   ` Thomas Petazzoni via buildroot
@ 2025-08-10 13:27     ` Romain Naour via buildroot
  0 siblings, 0 replies; 6+ messages in thread
From: Romain Naour via buildroot @ 2025-08-10 13:27 UTC (permalink / raw)
  To: Thomas Petazzoni
  Cc: Thomas Bonnefille, buildroot, Miquèl Raynal, Wade Berrier,
	Florian Weimer

Hello Thomas,

Le 10/08/2025 à 12:49, Thomas Petazzoni a écrit :
> Hello Romain,
> 
> Thanks for the review, but something is not clear. See below.
> 
> On Sat, 9 Aug 2025 23:52:55 +0200
> Romain Naour <romain.naour@smile.fr> wrote:
> 
>> Hello Thomas, All,
>>
>> Le 02/08/2025 à 13:37, Thomas Bonnefille via buildroot a écrit :
>>> Fixes: https://autobuild.buildroot.org/results/20b/20b924c5c96b3f43e381d87e59fb160ba8d3dcd0//  
>>
>> Please, can you provide your analysis on this issue?
>>
>> From the patch, I understand that it's an error generated by gcc-14 (an newer).
>> But ngrep package fail to build only when BR2_PACKAGE_LIBNET is selected.
> 
> So you ask for more details (which would encourage the submitter to
> send a new version of the patch)...
> 
>> I updated the commit log with a defconfig and the minimal gcc version to
>> reproduce the issue.
> 
> ... but you say you have already updated the commit log with more
> details. So? Did you already apply the patch and sending a new
> iteration is not needed, or?

Yes, I merged the patch with additional information in the commit log:

https://gitlab.com/buildroot.org/buildroot/-/commit/53d2ef7ec6fc406a23a5c5a13a4a3aefc8de3563

My initial intend was indeed to ask for more details but finally figured out
what was the issue. I should have updated my email before sending it.

Best regards,
Romain


> 
> Thanks!
> 
> Thomas

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

* Re: [Buildroot] [PATCH] package/ngrep: fix implicit function declaration
  2025-08-02 11:37 [Buildroot] [PATCH] package/ngrep: fix implicit function declaration Thomas Bonnefille via buildroot
  2025-08-02 20:03 ` Thomas Perale via buildroot
  2025-08-09 21:52 ` Romain Naour via buildroot
@ 2025-08-14 20:31 ` Thomas Perale via buildroot
  2 siblings, 0 replies; 6+ messages in thread
From: Thomas Perale via buildroot @ 2025-08-14 20:31 UTC (permalink / raw)
  To: Thomas Bonnefille; +Cc: Thomas Perale, buildroot

In reply of:
> Fixes: https://autobuild.buildroot.org/results/20b/20b924c5c96b3f43e381d87e59fb160ba8d3dcd0//
> 
> Signed-off-by: Thomas Bonnefille <thomas.bonnefille@bootlin.com>

Applied to 2025.02.x & 2025.05.x. Thanks

> ---
> This patch can be backported to 2025.02.x as this issue is reproducible
> on the current version of the LTS.
> ---
>  ....h-and-tcpkill.h-to-avoid-implicit-functi.patch | 44 ++++++++++++++++++++++
>  1 file changed, 44 insertions(+)
> 
> diff --git a/package/ngrep/0006-Include-err.h-and-tcpkill.h-to-avoid-implicit-functi.patch b/package/ngrep/0006-Include-err.h-and-tcpkill.h-to-avoid-implicit-functi.patch
> new file mode 100644
> index 0000000000000000000000000000000000000000..6d596bfe3791a33994179494e8c08ec7a9439975
> --- /dev/null
> +++ b/package/ngrep/0006-Include-err.h-and-tcpkill.h-to-avoid-implicit-functi.patch
> @@ -0,0 +1,44 @@
> +From 52515bae377f221b5473d9040f5f43ab1c672672 Mon Sep 17 00:00:00 2001
> +From: Florian Weimer <fweimer@redhat.com>
> +Date: Mon, 19 Dec 2022 11:49:06 +0100
> +Subject: [PATCH] Include <err.h> and "tcpkill.h" to avoid implicit function
> + declarations
> +
> +Implicit function declarations are a historic language feature that
> +were removed from C in 1999.
> +
> +Upstream: https://github.com/jpr5/ngrep/pull/28
> +
> +Signed-off-by: Thomas Bonnefille <thomas.bonnefille@bootlin.com>
> +---
> + ngrep.c   | 1 +
> + tcpkill.c | 1 +
> + 2 files changed, 2 insertions(+)
> +
> +diff --git a/ngrep.c b/ngrep.c
> +index 3df9389..b2fcceb 100644
> +--- a/ngrep.c
> ++++ b/ngrep.c
> +@@ -98,6 +98,7 @@
> + #endif
> + 
> + #include "ngrep.h"
> ++#include "tcpkill.h"
> + 
> + 
> + /*
> +diff --git a/tcpkill.c b/tcpkill.c
> +index 5388ec5..ac8fd2e 100644
> +--- a/tcpkill.c
> ++++ b/tcpkill.c
> +@@ -14,6 +14,7 @@
> + #include <stdlib.h>
> + #include <unistd.h>
> + #include <string.h>
> ++#include <err.h>
> + #include <libnet.h>
> + #include <pcap.h>
> + 
> +-- 
> +2.50.1
> +
> 
> ---
> base-commit: f5101638b9f917dc4c569828ff3fee0c486ba8f8
> change-id: 20250802-fix_ngrep-59ab75bf5919
> 
> Best regards,
> -- 
> Thomas Bonnefille <thomas.bonnefille@bootlin.com>
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

end of thread, other threads:[~2025-08-14 20:32 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-02 11:37 [Buildroot] [PATCH] package/ngrep: fix implicit function declaration Thomas Bonnefille via buildroot
2025-08-02 20:03 ` Thomas Perale via buildroot
2025-08-09 21:52 ` Romain Naour via buildroot
2025-08-10 10:49   ` Thomas Petazzoni via buildroot
2025-08-10 13:27     ` Romain Naour via buildroot
2025-08-14 20:31 ` Thomas Perale via buildroot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox