* [Buildroot] [PATCH] package/util-linux: fix build for riscv64 and powerpc64le
@ 2020-03-12 11:47 unixmania at gmail.com
2020-03-12 13:50 ` Thomas Petazzoni
0 siblings, 1 reply; 6+ messages in thread
From: unixmania at gmail.com @ 2020-03-12 11:47 UTC (permalink / raw)
To: buildroot
From: Carlos Santos <unixmania@gmail.com>
Pull two upstream patches that fix the declaration of pidfd_open and
pidfd_send_signal.
Fixes:
http://autobuild.buildroot.net/results/2396b04478f9d358b94f2e2e05540625ddc9f205/
http://autobuild.buildroot.net/results/ed4b5ec61bd33d3ccf0ebb16000af46d0499366d/
Signed-off-by: Carlos Santos <unixmania@gmail.com>
---
...-types.h-before-checking-SYS_pidfd_s.patch | 61 +++++++++++++++++++
.../0007-include-cleanup-pidfd-inckudes.patch | 39 ++++++++++++
2 files changed, 100 insertions(+)
create mode 100644 package/util-linux/0006-kill-include-sys-types.h-before-checking-SYS_pidfd_s.patch
create mode 100644 package/util-linux/0007-include-cleanup-pidfd-inckudes.patch
diff --git a/package/util-linux/0006-kill-include-sys-types.h-before-checking-SYS_pidfd_s.patch b/package/util-linux/0006-kill-include-sys-types.h-before-checking-SYS_pidfd_s.patch
new file mode 100644
index 0000000000..a892298faf
--- /dev/null
+++ b/package/util-linux/0006-kill-include-sys-types.h-before-checking-SYS_pidfd_s.patch
@@ -0,0 +1,61 @@
+From 3cfde0370d3a8949df0c5bcf447cec6692910ed2 Mon Sep 17 00:00:00 2001
+From: Sami Kerola <kerolasa@iki.fi>
+Date: Sat, 15 Feb 2020 21:12:50 +0000
+Subject: [PATCH] kill: include sys/types.h before checking
+ SYS_pidfd_send_signal
+
+Including sys/types.h must happen before SYS_pidfd_send_signal is checked,
+because that header defines variable in normal conditions. When sys/types.h
+does not have SYS_pidfd_send_signal then fallback is defined in config.h
+that is included by default, and has therefore worked fine before and after
+this change.
+
+Signed-off-by: Sami Kerola <kerolasa@iki.fi>
+---
+ include/pidfd-utils.h | 18 ++++++++++--------
+ 1 file changed, 10 insertions(+), 8 deletions(-)
+
+diff --git a/include/pidfd-utils.h b/include/pidfd-utils.h
+index 593346576..0baedd2c9 100644
+--- a/include/pidfd-utils.h
++++ b/include/pidfd-utils.h
+@@ -1,26 +1,28 @@
+ #ifndef UTIL_LINUX_PIDFD_UTILS
+ #define UTIL_LINUX_PIDFD_UTILS
+
+-#if defined(__linux__) && defined(SYS_pidfd_send_signal)
+-# include <sys/types.h>
++#if defined(__linux__)
+ # include <sys/syscall.h>
++# if defined(SYS_pidfd_send_signal)
++# include <sys/types.h>
+
+-# ifndef HAVE_PIDFD_OPEN
++# ifndef HAVE_PIDFD_OPEN
+ static inline int pidfd_send_signal(int pidfd, int sig, siginfo_t *info,
+ unsigned int flags)
+ {
+ return syscall(SYS_pidfd_send_signal, pidfd, sig, info, flags);
+ }
+-# endif
++# endif
+
+-# ifndef HAVE_PIDFD_SEND_SIGNAL
++# ifndef HAVE_PIDFD_SEND_SIGNAL
+ static inline int pidfd_open(pid_t pid, unsigned int flags)
+ {
+ return syscall(SYS_pidfd_open, pid, flags);
+ }
+-# endif
++# endif
+
+-# define UL_HAVE_PIDFD 1
++# define UL_HAVE_PIDFD 1
+
+-#endif /* __linux__ && SYS_pidfd_send_signal */
++# endif /* SYS_pidfd_send_signal */
++#endif /* __linux__ */
+ #endif /* UTIL_LINUX_PIDFD_UTILS */
+--
+2.18.2
+
diff --git a/package/util-linux/0007-include-cleanup-pidfd-inckudes.patch b/package/util-linux/0007-include-cleanup-pidfd-inckudes.patch
new file mode 100644
index 0000000000..4d4cc1f20d
--- /dev/null
+++ b/package/util-linux/0007-include-cleanup-pidfd-inckudes.patch
@@ -0,0 +1,39 @@
+From 0a4035ff2e4fd5b5ae0cf8f8665696c2aff53b75 Mon Sep 17 00:00:00 2001
+From: Karel Zak <kzak@redhat.com>
+Date: Tue, 10 Mar 2020 11:43:16 +0100
+Subject: [PATCH] include: cleanup pidfd inckudes
+
+Signed-off-by: Karel Zak <kzak@redhat.com>
+---
+ include/pidfd-utils.h | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/include/pidfd-utils.h b/include/pidfd-utils.h
+index 0baedd2c9..4a6c3a604 100644
+--- a/include/pidfd-utils.h
++++ b/include/pidfd-utils.h
+@@ -3,10 +3,10 @@
+
+ #if defined(__linux__)
+ # include <sys/syscall.h>
+-# if defined(SYS_pidfd_send_signal)
++# if defined(SYS_pidfd_send_signal) && defined(SYS_pidfd_open)
+ # include <sys/types.h>
+
+-# ifndef HAVE_PIDFD_OPEN
++# ifndef HAVE_PIDFD_SEND_SIGNAL
+ static inline int pidfd_send_signal(int pidfd, int sig, siginfo_t *info,
+ unsigned int flags)
+ {
+@@ -14,7 +14,7 @@ static inline int pidfd_send_signal(int pidfd, int sig, siginfo_t *info,
+ }
+ # endif
+
+-# ifndef HAVE_PIDFD_SEND_SIGNAL
++# ifndef HAVE_PIDFD_OPEN
+ static inline int pidfd_open(pid_t pid, unsigned int flags)
+ {
+ return syscall(SYS_pidfd_open, pid, flags);
+--
+2.18.2
+
--
2.18.2
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [Buildroot] [PATCH] package/util-linux: fix build for riscv64 and powerpc64le
2020-03-12 11:47 [Buildroot] [PATCH] package/util-linux: fix build for riscv64 and powerpc64le unixmania at gmail.com
@ 2020-03-12 13:50 ` Thomas Petazzoni
2020-03-12 13:54 ` Carlos Santos
0 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni @ 2020-03-12 13:50 UTC (permalink / raw)
To: buildroot
Hello Carlos,
On Thu, 12 Mar 2020 08:47:59 -0300
unixmania at gmail.com wrote:
> From: Carlos Santos <unixmania@gmail.com>
>
> Pull two upstream patches that fix the declaration of pidfd_open and
> pidfd_send_signal.
>
> Fixes:
> http://autobuild.buildroot.net/results/2396b04478f9d358b94f2e2e05540625ddc9f205/
> http://autobuild.buildroot.net/results/ed4b5ec61bd33d3ccf0ebb16000af46d0499366d/
>
> Signed-off-by: Carlos Santos <unixmania@gmail.com>
We normally require to sign-off on the patches themselves, when they
are added to Buildroot packages.
Thanks!
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Buildroot] [PATCH] package/util-linux: fix build for riscv64 and powerpc64le
2020-03-12 13:50 ` Thomas Petazzoni
@ 2020-03-12 13:54 ` Carlos Santos
2020-03-12 15:11 ` Thomas Petazzoni
0 siblings, 1 reply; 6+ messages in thread
From: Carlos Santos @ 2020-03-12 13:54 UTC (permalink / raw)
To: buildroot
On Thu, Mar 12, 2020 at 10:50 AM Thomas Petazzoni
<thomas.petazzoni@bootlin.com> wrote:
>
> Hello Carlos,
>
> On Thu, 12 Mar 2020 08:47:59 -0300
> unixmania at gmail.com wrote:
>
> > From: Carlos Santos <unixmania@gmail.com>
> >
> > Pull two upstream patches that fix the declaration of pidfd_open and
> > pidfd_send_signal.
> >
> > Fixes:
> > http://autobuild.buildroot.net/results/2396b04478f9d358b94f2e2e05540625ddc9f205/
> > http://autobuild.buildroot.net/results/ed4b5ec61bd33d3ccf0ebb16000af46d0499366d/
> >
> > Signed-off-by: Carlos Santos <unixmania@gmail.com>
>
> We normally require to sign-off on the patches themselves, when they
> are added to Buildroot packages.
The patches are not mine and are already properly signed:
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
--
Carlos Santos <unixmania@gmail.com>
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Buildroot] [PATCH] package/util-linux: fix build for riscv64 and powerpc64le
2020-03-12 13:54 ` Carlos Santos
@ 2020-03-12 15:11 ` Thomas Petazzoni
2020-03-12 16:10 ` Carlos Santos
0 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni @ 2020-03-12 15:11 UTC (permalink / raw)
To: buildroot
On Thu, 12 Mar 2020 10:54:52 -0300
Carlos Santos <unixmania@gmail.com> wrote:
> The patches are not mine and are already properly signed:
>
> Signed-off-by: Sami Kerola <kerolasa@iki.fi>
> Signed-off-by: Karel Zak <kzak@redhat.com>
We require contributors to on top of that add their own Signed-off-by.
It's been like this for several years in the Buildroot project. Have a
look, all patches in packages do have the original authors
Signed-off-by, plus the Signed-off-by of the Buildroot contributor who
brought the change into Buildroot.
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Buildroot] [PATCH] package/util-linux: fix build for riscv64 and powerpc64le
2020-03-12 15:11 ` Thomas Petazzoni
@ 2020-03-12 16:10 ` Carlos Santos
2020-03-13 8:04 ` Thomas Petazzoni
0 siblings, 1 reply; 6+ messages in thread
From: Carlos Santos @ 2020-03-12 16:10 UTC (permalink / raw)
To: buildroot
On Thu, Mar 12, 2020 at 12:11 PM Thomas Petazzoni
<thomas.petazzoni@bootlin.com> wrote:
>
> On Thu, 12 Mar 2020 10:54:52 -0300
> Carlos Santos <unixmania@gmail.com> wrote:
>
> > The patches are not mine and are already properly signed:
> >
> > Signed-off-by: Sami Kerola <kerolasa@iki.fi>
> > Signed-off-by: Karel Zak <kzak@redhat.com>
>
> We require contributors to on top of that add their own Signed-off-by.
> It's been like this for several years in the Buildroot project. Have a
> look, all patches in packages do have the original authors
> Signed-off-by, plus the Signed-off-by of the Buildroot contributor who
> brought the change into Buildroot.
So all the current util-linux patches are wrong too. :-(
--
Carlos Santos <unixmania@gmail.com>
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Buildroot] [PATCH] package/util-linux: fix build for riscv64 and powerpc64le
2020-03-12 16:10 ` Carlos Santos
@ 2020-03-13 8:04 ` Thomas Petazzoni
0 siblings, 0 replies; 6+ messages in thread
From: Thomas Petazzoni @ 2020-03-13 8:04 UTC (permalink / raw)
To: buildroot
On Thu, 12 Mar 2020 13:10:12 -0300
Carlos Santos <unixmania@gmail.com> wrote:
> > We require contributors to on top of that add their own Signed-off-by.
> > It's been like this for several years in the Buildroot project. Have a
> > look, all patches in packages do have the original authors
> > Signed-off-by, plus the Signed-off-by of the Buildroot contributor who
> > brought the change into Buildroot.
>
> So all the current util-linux patches are wrong too. :-(
Possibly yes, but our global policy is that all patches should have
Signed-off-by from the person who added the patch to Buildroot. There
may have been occasions where this was over-looked, but this is
nonetheless our rule.
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2020-03-13 8:04 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-12 11:47 [Buildroot] [PATCH] package/util-linux: fix build for riscv64 and powerpc64le unixmania at gmail.com
2020-03-12 13:50 ` Thomas Petazzoni
2020-03-12 13:54 ` Carlos Santos
2020-03-12 15:11 ` Thomas Petazzoni
2020-03-12 16:10 ` Carlos Santos
2020-03-13 8:04 ` Thomas Petazzoni
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.