* [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers
@ 2019-02-24 20:49 Artem Panfilov
2019-02-25 5:58 ` Baruch Siach
2019-05-26 22:05 ` Arnout Vandecappelle
0 siblings, 2 replies; 8+ messages in thread
From: Artem Panfilov @ 2019-02-24 20:49 UTC (permalink / raw)
To: buildroot
net_tstamp.h in recent kernel versions requires time.h for clockid_t.
Fixes:
http://autobuild.buildroot.net/results/93903e8abfeaa7df0b6525033fa63e29f2c9e7ae
Signed-off-by: Artem Panfilov <panfilov.artyom@gmail.com>
---
| 55 +++++++++++++++++++
1 file changed, 55 insertions(+)
create mode 100644 package/linuxptp/0002-fix-building-with-new-kernel-headers.patch
--git a/package/linuxptp/0002-fix-building-with-new-kernel-headers.patch b/package/linuxptp/0002-fix-building-with-new-kernel-headers.patch
new file mode 100644
index 0000000000..332e5491ff
--- /dev/null
+++ b/package/linuxptp/0002-fix-building-with-new-kernel-headers.patch
@@ -0,0 +1,55 @@
+From d663a483c40939bad58301c256d86da1f3da6cc0 Mon Sep 17 00:00:00 2001
+From: Miroslav Lichvar <mlichvar@redhat.com>
+Date: Tue, 13 Nov 2018 13:16:08 +0100
+Subject: [PATCH] Fix building with new kernel headers.
+
+net_tstamp.h in recent kernel versions requires time.h for clockid_t.
+
+Signed-off-by: Miroslav Lichvar <mlichvar@redhat.com>
+---
+ clock.c | 2 +-
+ sk.c | 1 +
+ timemaster.c | 1 +
+ 3 files changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/clock.c b/clock.c
+index 9c493c3..8533b39 100644
+--- a/clock.c
++++ b/clock.c
+@@ -17,11 +17,11 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+ #include <errno.h>
++#include <time.h>
+ #include <linux/net_tstamp.h>
+ #include <poll.h>
+ #include <stdlib.h>
+ #include <string.h>
+-#include <time.h>
+ #include <sys/queue.h>
+
+ #include "address.h"
+diff --git a/sk.c b/sk.c
+index e2b1f28..30162eb 100644
+--- a/sk.c
++++ b/sk.c
+@@ -18,6 +18,7 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+ #include <errno.h>
++#include <time.h>
+ #include <linux/net_tstamp.h>
+ #include <linux/sockios.h>
+ #include <linux/ethtool.h>
+diff --git a/timemaster.c b/timemaster.c
+index 058678f..00db59f 100644
+--- a/timemaster.c
++++ b/timemaster.c
+@@ -22,6 +22,7 @@
+ #include <errno.h>
+ #include <libgen.h>
+ #include <limits.h>
++#include <time.h>
+ #include <linux/net_tstamp.h>
+ #include <net/if.h>
+ #include <signal.h>
--
2.19.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers
2019-02-24 20:49 [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers Artem Panfilov
@ 2019-02-25 5:58 ` Baruch Siach
2019-02-25 6:24 ` Artem Panfilov
2019-02-25 22:40 ` Romain Naour
2019-05-26 22:05 ` Arnout Vandecappelle
1 sibling, 2 replies; 8+ messages in thread
From: Baruch Siach @ 2019-02-25 5:58 UTC (permalink / raw)
To: buildroot
Hi Artem,
On Sun, Feb 24, 2019 at 11:49:31PM +0300, Artem Panfilov wrote:
> net_tstamp.h in recent kernel versions requires time.h for clockid_t.
This is a kernel bug. Kernel UAPI headers must not use the userspace clockid_t
type. This bug has been fixed in kernel commit e2c4cf7f98a5 ("net: Use
__kernel_clockid_t in uapi net_stamp.h") just before the v4.20 release. It
looks like this Linaro toolchain took the headers of a kernel -rc release.
Maybe update the Linaro toolchain to 2019.02 in master?
Romain?
baruch
> Fixes:
> http://autobuild.buildroot.net/results/93903e8abfeaa7df0b6525033fa63e29f2c9e7ae
> Signed-off-by: Artem Panfilov <panfilov.artyom@gmail.com>
> ---
> ...fix-building-with-new-kernel-headers.patch | 55 +++++++++++++++++++
> 1 file changed, 55 insertions(+)
> create mode 100644 package/linuxptp/0002-fix-building-with-new-kernel-headers.patch
>
> diff --git a/package/linuxptp/0002-fix-building-with-new-kernel-headers.patch b/package/linuxptp/0002-fix-building-with-new-kernel-headers.patch
> new file mode 100644
> index 0000000000..332e5491ff
> --- /dev/null
> +++ b/package/linuxptp/0002-fix-building-with-new-kernel-headers.patch
> @@ -0,0 +1,55 @@
> +From d663a483c40939bad58301c256d86da1f3da6cc0 Mon Sep 17 00:00:00 2001
> +From: Miroslav Lichvar <mlichvar@redhat.com>
> +Date: Tue, 13 Nov 2018 13:16:08 +0100
> +Subject: [PATCH] Fix building with new kernel headers.
> +
> +net_tstamp.h in recent kernel versions requires time.h for clockid_t.
> +
> +Signed-off-by: Miroslav Lichvar <mlichvar@redhat.com>
> +---
> + clock.c | 2 +-
> + sk.c | 1 +
> + timemaster.c | 1 +
> + 3 files changed, 3 insertions(+), 1 deletion(-)
> +
> +diff --git a/clock.c b/clock.c
> +index 9c493c3..8533b39 100644
> +--- a/clock.c
> ++++ b/clock.c
> +@@ -17,11 +17,11 @@
> + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
> + */
> + #include <errno.h>
> ++#include <time.h>
> + #include <linux/net_tstamp.h>
> + #include <poll.h>
> + #include <stdlib.h>
> + #include <string.h>
> +-#include <time.h>
> + #include <sys/queue.h>
> +
> + #include "address.h"
> +diff --git a/sk.c b/sk.c
> +index e2b1f28..30162eb 100644
> +--- a/sk.c
> ++++ b/sk.c
> +@@ -18,6 +18,7 @@
> + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
> + */
> + #include <errno.h>
> ++#include <time.h>
> + #include <linux/net_tstamp.h>
> + #include <linux/sockios.h>
> + #include <linux/ethtool.h>
> +diff --git a/timemaster.c b/timemaster.c
> +index 058678f..00db59f 100644
> +--- a/timemaster.c
> ++++ b/timemaster.c
> +@@ -22,6 +22,7 @@
> + #include <errno.h>
> + #include <libgen.h>
> + #include <limits.h>
> ++#include <time.h>
> + #include <linux/net_tstamp.h>
> + #include <net/if.h>
> + #include <signal.h>
> --
> 2.19.1
>
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
--
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers
2019-02-25 5:58 ` Baruch Siach
@ 2019-02-25 6:24 ` Artem Panfilov
2019-02-25 22:40 ` Romain Naour
1 sibling, 0 replies; 8+ messages in thread
From: Artem Panfilov @ 2019-02-25 6:24 UTC (permalink / raw)
To: buildroot
Hi Baruch,
On 25.02.2019 8:58, Baruch Siach wrote:> Maybe update the Linaro toolchain to 2019.02 in master?
> This is a kernel bug. Kernel UAPI headers must not use the userspace clockid_t
> type. This bug has been fixed in kernel commit e2c4cf7f98a5 ("net: Use
> __kernel_clockid_t in uapi net_stamp.h") just before the v4.20 release. It
> looks like this Linaro toolchain took the headers of a kernel -rc release.
This patch is already in the master branch of linuxptp.
It depends when buildroot 2019.02 will be released.
Upgrading toolchain seems a cleaner solution for me.
Artem
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers
2019-02-25 5:58 ` Baruch Siach
2019-02-25 6:24 ` Artem Panfilov
@ 2019-02-25 22:40 ` Romain Naour
2019-02-26 12:12 ` Peter Korsgaard
1 sibling, 1 reply; 8+ messages in thread
From: Romain Naour @ 2019-02-25 22:40 UTC (permalink / raw)
To: buildroot
Hi Baruch, Artem, All,
Le 25/02/2019 ? 06:58, Baruch Siach a ?crit?:
> Hi Artem,
>
> On Sun, Feb 24, 2019 at 11:49:31PM +0300, Artem Panfilov wrote:
>> net_tstamp.h in recent kernel versions requires time.h for clockid_t.
>
> This is a kernel bug. Kernel UAPI headers must not use the userspace clockid_t
> type. This bug has been fixed in kernel commit e2c4cf7f98a5 ("net: Use
> __kernel_clockid_t in uapi net_stamp.h") just before the v4.20 release. It
> looks like this Linaro toolchain took the headers of a kernel -rc release.
>
> Maybe update the Linaro toolchain to 2019.02 in master?
> Romain?
Actually it's not a Linaro toolchain anymore, it's an ARM toolchain.
Indeed, these toolchains use a 4.20 -rc kernel release.
I noticed it while updating to the 2018.11 release that was released one month
before the official kernel 4.20 release (respectively 23 Nov 2018 and 23 Dec
2018). I had to wait for BR2_TOOLCHAIN_HEADERS_AT_LEAST_4_20 symbol in Buildroot.
The latest ARM toolchain 2019.01 release use 5.0-rc1 kernel release.
We can't include this version into Buildroot since the kernel 5.0 is not
released yet.
Maybe we should report this issue to https://bugs.linaro.org ?
Best regards,
Romain
>
> baruch
>
>> Fixes:
>> http://autobuild.buildroot.net/results/93903e8abfeaa7df0b6525033fa63e29f2c9e7ae
>> Signed-off-by: Artem Panfilov <panfilov.artyom@gmail.com>
>> ---
>> ...fix-building-with-new-kernel-headers.patch | 55 +++++++++++++++++++
>> 1 file changed, 55 insertions(+)
>> create mode 100644 package/linuxptp/0002-fix-building-with-new-kernel-headers.patch
>>
>> diff --git a/package/linuxptp/0002-fix-building-with-new-kernel-headers.patch b/package/linuxptp/0002-fix-building-with-new-kernel-headers.patch
>> new file mode 100644
>> index 0000000000..332e5491ff
>> --- /dev/null
>> +++ b/package/linuxptp/0002-fix-building-with-new-kernel-headers.patch
>> @@ -0,0 +1,55 @@
>> +From d663a483c40939bad58301c256d86da1f3da6cc0 Mon Sep 17 00:00:00 2001
>> +From: Miroslav Lichvar <mlichvar@redhat.com>
>> +Date: Tue, 13 Nov 2018 13:16:08 +0100
>> +Subject: [PATCH] Fix building with new kernel headers.
>> +
>> +net_tstamp.h in recent kernel versions requires time.h for clockid_t.
>> +
>> +Signed-off-by: Miroslav Lichvar <mlichvar@redhat.com>
>> +---
>> + clock.c | 2 +-
>> + sk.c | 1 +
>> + timemaster.c | 1 +
>> + 3 files changed, 3 insertions(+), 1 deletion(-)
>> +
>> +diff --git a/clock.c b/clock.c
>> +index 9c493c3..8533b39 100644
>> +--- a/clock.c
>> ++++ b/clock.c
>> +@@ -17,11 +17,11 @@
>> + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
>> + */
>> + #include <errno.h>
>> ++#include <time.h>
>> + #include <linux/net_tstamp.h>
>> + #include <poll.h>
>> + #include <stdlib.h>
>> + #include <string.h>
>> +-#include <time.h>
>> + #include <sys/queue.h>
>> +
>> + #include "address.h"
>> +diff --git a/sk.c b/sk.c
>> +index e2b1f28..30162eb 100644
>> +--- a/sk.c
>> ++++ b/sk.c
>> +@@ -18,6 +18,7 @@
>> + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
>> + */
>> + #include <errno.h>
>> ++#include <time.h>
>> + #include <linux/net_tstamp.h>
>> + #include <linux/sockios.h>
>> + #include <linux/ethtool.h>
>> +diff --git a/timemaster.c b/timemaster.c
>> +index 058678f..00db59f 100644
>> +--- a/timemaster.c
>> ++++ b/timemaster.c
>> +@@ -22,6 +22,7 @@
>> + #include <errno.h>
>> + #include <libgen.h>
>> + #include <limits.h>
>> ++#include <time.h>
>> + #include <linux/net_tstamp.h>
>> + #include <net/if.h>
>> + #include <signal.h>
>> --
>> 2.19.1
>>
>> _______________________________________________
>> buildroot mailing list
>> buildroot at busybox.net
>> http://lists.busybox.net/mailman/listinfo/buildroot
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers
2019-02-25 22:40 ` Romain Naour
@ 2019-02-26 12:12 ` Peter Korsgaard
2019-02-26 22:39 ` Romain Naour
0 siblings, 1 reply; 8+ messages in thread
From: Peter Korsgaard @ 2019-02-26 12:12 UTC (permalink / raw)
To: buildroot
>>>>> "Romain" == Romain Naour <romain.naour@gmail.com> writes:
> Hi Baruch, Artem, All,
> Le 25/02/2019 ? 06:58, Baruch Siach a ?crit?:
>> Hi Artem,
>>
>> On Sun, Feb 24, 2019 at 11:49:31PM +0300, Artem Panfilov wrote:
>>> net_tstamp.h in recent kernel versions requires time.h for clockid_t.
>>
>> This is a kernel bug. Kernel UAPI headers must not use the userspace clockid_t
>> type. This bug has been fixed in kernel commit e2c4cf7f98a5 ("net: Use
>> __kernel_clockid_t in uapi net_stamp.h") just before the v4.20 release. It
>> looks like this Linaro toolchain took the headers of a kernel -rc release.
>>
>> Maybe update the Linaro toolchain to 2019.02 in master?
>> Romain?
> Actually it's not a Linaro toolchain anymore, it's an ARM toolchain.
> Indeed, these toolchains use a 4.20 -rc kernel release.
> I noticed it while updating to the 2018.11 release that was released one month
> before the official kernel 4.20 release (respectively 23 Nov 2018 and 23 Dec
> 2018). I had to wait for BR2_TOOLCHAIN_HEADERS_AT_LEAST_4_20 symbol in Buildroot.
> The latest ARM toolchain 2019.01 release use 5.0-rc1 kernel release.
> We can't include this version into Buildroot since the kernel 5.0 is not
> released yet.
> Maybe we should report this issue to https://bugs.linaro.org ?
Yes, it would be nice if they could use released kernels for the
headers.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers
2019-02-26 12:12 ` Peter Korsgaard
@ 2019-02-26 22:39 ` Romain Naour
2019-02-27 8:53 ` Peter Korsgaard
0 siblings, 1 reply; 8+ messages in thread
From: Romain Naour @ 2019-02-26 22:39 UTC (permalink / raw)
To: buildroot
Hello Peter,
Le 26/02/2019 ? 13:12, Peter Korsgaard a ?crit?:
>>>>>> "Romain" == Romain Naour <romain.naour@gmail.com> writes:
>
> > Hi Baruch, Artem, All,
> > Le 25/02/2019 ? 06:58, Baruch Siach a ?crit?:
> >> Hi Artem,
> >>
> >> On Sun, Feb 24, 2019 at 11:49:31PM +0300, Artem Panfilov wrote:
> >>> net_tstamp.h in recent kernel versions requires time.h for clockid_t.
> >>
> >> This is a kernel bug. Kernel UAPI headers must not use the userspace clockid_t
> >> type. This bug has been fixed in kernel commit e2c4cf7f98a5 ("net: Use
> >> __kernel_clockid_t in uapi net_stamp.h") just before the v4.20 release. It
> >> looks like this Linaro toolchain took the headers of a kernel -rc release.
> >>
> >> Maybe update the Linaro toolchain to 2019.02 in master?
> >> Romain?
>
> > Actually it's not a Linaro toolchain anymore, it's an ARM toolchain.
>
> > Indeed, these toolchains use a 4.20 -rc kernel release.
> > I noticed it while updating to the 2018.11 release that was released one month
> > before the official kernel 4.20 release (respectively 23 Nov 2018 and 23 Dec
> > 2018). I had to wait for BR2_TOOLCHAIN_HEADERS_AT_LEAST_4_20 symbol in Buildroot.
>
> > The latest ARM toolchain 2019.01 release use 5.0-rc1 kernel release.
> > We can't include this version into Buildroot since the kernel 5.0 is not
> > released yet.
>
> > Maybe we should report this issue to https://bugs.linaro.org ?
>
> Yes, it would be nice if they could use released kernels for the
> headers.
>
Done:
https://bugs.linaro.org/show_bug.cgi?id=4297
Best regards,
Romain
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers
2019-02-26 22:39 ` Romain Naour
@ 2019-02-27 8:53 ` Peter Korsgaard
0 siblings, 0 replies; 8+ messages in thread
From: Peter Korsgaard @ 2019-02-27 8:53 UTC (permalink / raw)
To: buildroot
>>>>> "Romain" == Romain Naour <romain.naour@gmail.com> writes:
Hi,
>> > Maybe we should report this issue to https://bugs.linaro.org ?
>>
>> Yes, it would be nice if they could use released kernels for the
>> headers.
> Done:
> https://bugs.linaro.org/show_bug.cgi?id=4297
Great, thanks!
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers
2019-02-24 20:49 [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers Artem Panfilov
2019-02-25 5:58 ` Baruch Siach
@ 2019-05-26 22:05 ` Arnout Vandecappelle
1 sibling, 0 replies; 8+ messages in thread
From: Arnout Vandecappelle @ 2019-05-26 22:05 UTC (permalink / raw)
To: buildroot
On 24/02/2019 21:49, Artem Panfilov wrote:
> net_tstamp.h in recent kernel versions requires time.h for clockid_t.
>
> Fixes:
> http://autobuild.buildroot.net/results/93903e8abfeaa7df0b6525033fa63e29f2c9e7ae
> Signed-off-by: Artem Panfilov <panfilov.artyom@gmail.com>
There should be an empty line above your Sob. I fixed that up and applied to
master, thanks.
There was some discussion if this was the proper approach, but the patch comes
from upstream, and it's still failing in the autobuilders.
Regards,
Arnout
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2019-05-26 22:05 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-24 20:49 [Buildroot] [PATCH 1/1] package/linuxptp: fix build with new headers Artem Panfilov
2019-02-25 5:58 ` Baruch Siach
2019-02-25 6:24 ` Artem Panfilov
2019-02-25 22:40 ` Romain Naour
2019-02-26 12:12 ` Peter Korsgaard
2019-02-26 22:39 ` Romain Naour
2019-02-27 8:53 ` Peter Korsgaard
2019-05-26 22:05 ` Arnout Vandecappelle
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.