From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id BD3B2C43334 for ; Tue, 21 Jun 2022 00:10:10 +0000 (UTC) Received: from mail-qk1-f170.google.com (mail-qk1-f170.google.com [209.85.222.170]) by mx.groups.io with SMTP id smtpd.web08.37781.1655770209619666380 for ; Mon, 20 Jun 2022 17:10:09 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20210112 header.b=nbaTnLQz; spf=pass (domain: gmail.com, ip: 209.85.222.170, mailfrom: raj.khem@gmail.com) Received: by mail-qk1-f170.google.com with SMTP id d128so8950045qkg.8 for ; Mon, 20 Jun 2022 17:10:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=vET4iK3CpEELmrEx70D0zKPsxIp71sGX6OEI59IxI3E=; b=nbaTnLQzrBc9TZYZRjLZn2JoO3Xe794vkXB/r0+n+e5IjbpfPytUoNh1GsbWEfu99Q 1ocNVvWAfbSbd+dLY8NZrGKHoabRtr7PfA4qkg0R+RJAlddXBmWMwlFSCv5t8hC1g9nN w4wUnJtLKPqfIBp8UvhxnvXYdULIgoFf68f0+5BlPj3pmypKy6yHluUo86Upzc3pvuUj 8rOqzK4Op3B3suREn8KnxOho6NLtIDKaXWBmbwhIm/QvHHEHAEjSEY1h3DCuFjz8O3FJ fbFtnYmydxXC+8ApV7Qf/Ih+F1DOLApU6pVL9g8uEca36Y37rph5fVvszRz2Y8eYnkWf eG3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=vET4iK3CpEELmrEx70D0zKPsxIp71sGX6OEI59IxI3E=; b=TWrCpzCVhwC4//+eYd1KjlbiyeAxjCc+1ahWwisaMCi6wd0eH/dtFOhvs8a8aV9XSB 8K58LhQl6oTRjgLvqfgM7EMWCLCm50piKbYk/u0Cq+Mk43vGVsnwPTlkbHyBO2wR1IQ2 mFTLtWFkrxSsNdZMR8Rokp/8ud4zSetXndUtOGHskks8qvUOC7/GtPYc4YqYnyCRm6HF xFOOvuHhz7rQI5CS0YjceEg9YftkBdUlAofOoJjO8waxf6EN1rqMd/mZM+pO9hKG5OwG vS2xQI2wGlZs6zS3les9TuSx7ZsQ+ei69oPLYv3nGITE5P0DZMR8LvP9VBIkxdQ7LNeW dUBQ== X-Gm-Message-State: AJIora/UUAIwS75M8Mpnzi9ZR6VQihYjd1wlLVu6nCVWcAOSXgcfLvkG q+bzIdfOJ9x/23DRbFkhNJ8pq+4QryA1B9dtkPg= X-Google-Smtp-Source: AGRyM1ufvVuWam28VPltYRvRsxuoJH3FduPTW4iwl3zWAGrJ17mZKJUZ7N5hL4BQrS8E8lz5H5ECwUAppS+KjuTR6UM= X-Received: by 2002:ae9:d60b:0:b0:6a6:ab28:3c05 with SMTP id r11-20020ae9d60b000000b006a6ab283c05mr18051282qkk.180.1655770208596; Mon, 20 Jun 2022 17:10:08 -0700 (PDT) MIME-Version: 1.0 References: <20220620161228.5267-1-pavel@zhukoff.net> In-Reply-To: <20220620161228.5267-1-pavel@zhukoff.net> From: Khem Raj Date: Tue, 21 Jun 2022 05:39:57 +0530 Message-ID: Subject: Re: [OE-core] [PATCH 1/2] systemd: Add missed sys/file.h includes for musl To: Pavel Zhukov Cc: Pavel Zhukov , openembedded-core@lists.openembedded.org Content-Type: multipart/alternative; boundary="0000000000001cf88205e1ea0b1d" List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 21 Jun 2022 00:10:10 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/167127 --0000000000001cf88205e1ea0b1d Content-Type: text/plain; charset="UTF-8" This could be a generic patch and also submit it upstream On Mon, Jun 20, 2022 at 9:43 PM Pavel Zhukov wrote: > Signed-off-by: Pavel Zhukov > --- > .../0001-Add-sys-file.h-for-LOCK_.patch | 80 +++++++++++++++++++ > meta/recipes-core/systemd/systemd_251.2.bb | 2 +- > 2 files changed, 81 insertions(+), 1 deletion(-) > create mode 100644 > meta/recipes-core/systemd/systemd/0001-Add-sys-file.h-for-LOCK_.patch > > diff --git > a/meta/recipes-core/systemd/systemd/0001-Add-sys-file.h-for-LOCK_.patch > b/meta/recipes-core/systemd/systemd/0001-Add-sys-file.h-for-LOCK_.patch > new file mode 100644 > index 0000000000..25a1042a9d > --- /dev/null > +++ b/meta/recipes-core/systemd/systemd/0001-Add-sys-file.h-for-LOCK_.patch > @@ -0,0 +1,80 @@ > +From 7ae39374fda539aa613caeeee09be8d050a9bb79 Mon Sep 17 00:00:00 2001 > +From: Pavel Zhukov > +Date: Mon, 20 Jun 2022 11:24:52 +0200 > +Subject: [PATCH] Add sys/file.h for LOCK_ > +Cc: pavel@zhukoff.net > + > +Upstream-Status: Inappropriate [musl specific] > + > +Signed-off-by: Pavel Zhukov > +--- > + src/core/namespace.c | 1 + > + src/dissect/dissect.c | 1 + > + src/shared/dissect-image.c | 2 ++ > + src/sysext/sysext.c | 1 + > + src/test/test-loop-block.c | 1 + > + 5 files changed, 6 insertions(+) > + > +diff --git a/src/core/namespace.c b/src/core/namespace.c > +index 926aa96174..39f9e21c93 100644 > +--- a/src/core/namespace.c > ++++ b/src/core/namespace.c > +@@ -7,6 +7,7 @@ > + #include > + #include > + #include > ++#include // For LOCK_ musl-specific > + > + #include "alloc-util.h" > + #include "base-filesystem.h" > +diff --git a/src/dissect/dissect.c b/src/dissect/dissect.c > +index bd94a755db..a0d2a6f287 100644 > +--- a/src/dissect/dissect.c > ++++ b/src/dissect/dissect.c > +@@ -6,6 +6,7 @@ > + #include > + #include > + #include > ++#include // musl specific for LOCK_ > + > + #include "architecture.h" > + #include "chase-symlinks.h" > +diff --git a/src/shared/dissect-image.c b/src/shared/dissect-image.c > +index 1ab88839aa..a9e3fe4b44 100644 > +--- a/src/shared/dissect-image.c > ++++ b/src/shared/dissect-image.c > +@@ -4,6 +4,8 @@ > + #include > + #endif > + > ++#include // For LOCK (musl specific) > ++ > + #include > + #include > + #include > +diff --git a/src/sysext/sysext.c b/src/sysext/sysext.c > +index 364af195e0..85686c0fab 100644 > +--- a/src/sysext/sysext.c > ++++ b/src/sysext/sysext.c > +@@ -5,6 +5,7 @@ > + #include > + #include > + #include > ++#include // LOCK_ (musl-specific) > + > + #include "capability-util.h" > + #include "chase-symlinks.h" > +diff --git a/src/test/test-loop-block.c b/src/test/test-loop-block.c > +index d1793222f0..6886c4cd31 100644 > +--- a/src/test/test-loop-block.c > ++++ b/src/test/test-loop-block.c > +@@ -3,6 +3,7 @@ > + #include > + #include > + #include > ++#include // LOCK_ (Musl specific) > + > + #include "alloc-util.h" > + #include "dissect-image.h" > +-- > +2.35.1 > diff --git a/meta/recipes-core/systemd/systemd_251.2.bb > b/meta/recipes-core/systemd/systemd_251.2.bb > index 8370bec0ca..88216ccf6e 100644 > --- a/meta/recipes-core/systemd/systemd_251.2.bb > +++ b/meta/recipes-core/systemd/systemd_251.2.bb > @@ -35,7 +35,6 @@ SRC_URI_MUSL = "\ > > file://0005-src-basic-missing.h-check-for-missing-strndupa.patch \ > > file://0007-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch \ > file://0008-add-missing-FTW_-macros-for-musl.patch \ > - > file://0009-fix-missing-of-__register_atfork-for-non-glibc-build.patch \ > file://0010-Use-uintmax_t-for-handling-rlim_t.patch \ > > file://0011-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch \ > > file://0012-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch \ > @@ -51,6 +50,7 @@ SRC_URI_MUSL = "\ > file://0001-pass-correct-parameters-to-getdents64.patch \ > file://0002-Add-sys-stat.h-for-S_IFDIR.patch \ > file://0001-Adjust-for-musl-headers.patch \ > + file://0001-Add-sys-file.h-for-LOCK_.patch \ > " > > PAM_PLUGINS = " \ > -- > 2.35.1 > > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#167121): > https://lists.openembedded.org/g/openembedded-core/message/167121 > Mute This Topic: https://lists.openembedded.org/mt/91880524/1997914 > Group Owner: openembedded-core+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [ > raj.khem@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- > > --0000000000001cf88205e1ea0b1d Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
This could be a generic patch and also submit it upstream= =C2=A0

On Mon, Jun 20, 2022 at 9:43 PM Pavel Zhukov <pavel@zhukoff.net> wrote:
Signed-off-by: Pavel Zhukov <pavel.zhukov@huawei.com>
---
=C2=A0.../0001-Add-sys-file.h-for-LOCK_.patch=C2=A0 =C2=A0 =C2=A0 =C2=A0| 8= 0 +++++++++++++++++++
=C2=A0meta/recipes-core/systemd/systemd_251.2.bb=C2=A0 =C2=A0 |=C2=A0 2 += -
=C2=A02 files changed, 81 insertions(+), 1 deletion(-)
=C2=A0create mode 100644 meta/recipes-core/systemd/systemd/0001-Add-sys-fil= e.h-for-LOCK_.patch

diff --git a/meta/recipes-core/systemd/systemd/0001-Add-sys-file.h-for-LOCK= _.patch b/meta/recipes-core/systemd/systemd/0001-Add-sys-file.h-for-LOCK_.p= atch
new file mode 100644
index 0000000000..25a1042a9d
--- /dev/null
+++ b/meta/recipes-core/systemd/systemd/0001-Add-sys-file.h-for-LOCK_.patch=
@@ -0,0 +1,80 @@
+From 7ae39374fda539aa613caeeee09be8d050a9bb79 Mon Sep 17 00:00:00 2001
+From: Pavel Zhukov <pavel.zhukov@huawei.com>
+Date: Mon, 20 Jun 2022 11:24:52 +0200
+Subject: [PATCH] Add sys/file.h for LOCK_
+Cc: pavel@zhukoff.n= et
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Pavel Zhukov <pavel.zhukov@huawei.com>
+---
+ src/core/namespace.c=C2=A0 =C2=A0 =C2=A0 =C2=A0| 1 +
+ src/dissect/dissect.c=C2=A0 =C2=A0 =C2=A0 | 1 +
+ src/shared/dissect-image.c | 2 ++
+ src/sysext/sysext.c=C2=A0 =C2=A0 =C2=A0 =C2=A0 | 1 +
+ src/test/test-loop-block.c | 1 +
+ 5 files changed, 6 insertions(+)
+
+diff --git a/src/core/namespace.c b/src/core/namespace.c
+index 926aa96174..39f9e21c93 100644
+--- a/src/core/namespace.c
++++ b/src/core/namespace.c
+@@ -7,6 +7,7 @@
+ #include <sys/mount.h>
+ #include <unistd.h>
+ #include <linux/fs.h>
++#include <sys/file.h> // For LOCK_ musl-specific
+
+ #include "alloc-util.h"
+ #include "base-filesystem.h"
+diff --git a/src/dissect/dissect.c b/src/dissect/dissect.c
+index bd94a755db..a0d2a6f287 100644
+--- a/src/dissect/dissect.c
++++ b/src/dissect/dissect.c
+@@ -6,6 +6,7 @@
+ #include <stdio.h>
+ #include <sys/ioctl.h>
+ #include <sys/mount.h>
++#include <sys/file.h> // musl specific for LOCK_
+
+ #include "architecture.h"
+ #include "chase-symlinks.h"
+diff --git a/src/shared/dissect-image.c b/src/shared/dissect-image.c
+index 1ab88839aa..a9e3fe4b44 100644
+--- a/src/shared/dissect-image.c
++++ b/src/shared/dissect-image.c
+@@ -4,6 +4,8 @@
+ #include <valgrind/memcheck.h>
+ #endif
+
++#include <sys/file.h> // For LOCK (musl specific)
++
+ #include <linux/blkpg.h>
+ #include <linux/dm-ioctl.h>
+ #include <linux/loop.h>
+diff --git a/src/sysext/sysext.c b/src/sysext/sysext.c
+index 364af195e0..85686c0fab 100644
+--- a/src/sysext/sysext.c
++++ b/src/sysext/sysext.c
+@@ -5,6 +5,7 @@
+ #include <linux/loop.h>
+ #include <sys/mount.h>
+ #include <unistd.h>
++#include <sys/file.h> // LOCK_ (musl-specific)
+
+ #include "capability-util.h"
+ #include "chase-symlinks.h"
+diff --git a/src/test/test-loop-block.c b/src/test/test-loop-block.c
+index d1793222f0..6886c4cd31 100644
+--- a/src/test/test-loop-block.c
++++ b/src/test/test-loop-block.c
+@@ -3,6 +3,7 @@
+ #include <fcntl.h>
+ #include <linux/loop.h>
+ #include <pthread.h>
++#include <sys/file.h> // LOCK_ (Musl specific)
+
+ #include "alloc-util.h"
+ #include "dissect-image.h"
+--
+2.35.1
diff --git a/meta/recipes-core/systemd/systemd_251.2.bb b/meta/recipes-co= re/systemd/systemd_251.2.bb
index 8370bec0ca..88216ccf6e 100644
--- a/meta/recipes-core/systemd/systemd_251.2.bb
+++ b/meta/recipes-core/systemd/systemd_251.2.bb
@@ -35,7 +35,6 @@ SRC_URI_MUSL =3D "\
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 file://0005-src-bas= ic-missing.h-check-for-missing-strndupa.patch \
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 file://0007-don-t-f= ail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch \
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 file://0008-add-mis= sing-FTW_-macros-for-musl.patch \
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0file://0009-fix-mis= sing-of-__register_atfork-for-non-glibc-build.patch \
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 file://0010-Use-uin= tmax_t-for-handling-rlim_t.patch \
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 file://0011-test-si= zeof.c-Disable-tests-for-missing-typedefs-in-.patch \
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 file://0012-don-t-p= ass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch \
@@ -51,6 +50,7 @@ SRC_URI_MUSL =3D "\
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 file://0001-pass-co= rrect-parameters-to-getdents64.patch \
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 file://0002-Add-sys= -stat.h-for-S_IFDIR.patch \
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 file://0001-Adjust-= for-musl-headers.patch \
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0file://0001-Add-sys= -file.h-for-LOCK_.patch \
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 "

=C2=A0PAM_PLUGINS =3D " \
--
2.35.1


-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-
Links: You receive all messages sent to this group.
View/Reply Online (#167121): https:= //lists.openembedded.org/g/openembedded-core/message/167121
Mute This Topic: https://lists.openembedded.org/mt= /91880524/1997914
Group Owner: openembedded-core+owner@lists.openembedded.org<= br> Unsubscribe: https://lists.openembedded.org/= g/openembedded-core/unsub [raj.khem@gmail.com]
-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-

--0000000000001cf88205e1ea0b1d--