From: "Stephan Hartmann" <sultan@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-cluster/ploop/files/, sys-cluster/ploop/
Date: Sun, 19 Jun 2022 17:45:29 +0000 (UTC) [thread overview]
Message-ID: <1655660723.d2c74fe1c6bd290617186d2cd4992f005a288ca2.sultan@gentoo> (raw)
commit: d2c74fe1c6bd290617186d2cd4992f005a288ca2
Author: Stephan Hartmann <sultan <AT> gentoo <DOT> org>
AuthorDate: Sun Jun 19 17:45:12 2022 +0000
Commit: Stephan Hartmann <sultan <AT> gentoo <DOT> org>
CommitDate: Sun Jun 19 17:45:23 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d2c74fe1
sys-cluster/ploop: fix building on musl
Closes: https://bugs.gentoo.org/832965
Signed-off-by: Stephan Hartmann <sultan <AT> gentoo.org>
sys-cluster/ploop/files/ploop-1.14-musl.patch | 78 +++++++++++++++++++++++++++
sys-cluster/ploop/ploop-1.14.1-r1.ebuild | 1 +
2 files changed, 79 insertions(+)
diff --git a/sys-cluster/ploop/files/ploop-1.14-musl.patch b/sys-cluster/ploop/files/ploop-1.14-musl.patch
new file mode 100644
index 000000000000..693135123c55
--- /dev/null
+++ b/sys-cluster/ploop/files/ploop-1.14-musl.patch
@@ -0,0 +1,78 @@
+--- a/lib/balloon_util.c
++++ b/lib/balloon_util.c
+@@ -30,6 +30,7 @@
+ #include <string.h>
+ #include <linux/fs.h>
+ #include <linux/fiemap.h>
++#include <stddef.h>
+
+ #include "ploop.h"
+
+--- a/lib/delta_read.c
++++ b/lib/delta_read.c
+@@ -24,6 +24,7 @@
+ #include <malloc.h>
+ #include <string.h>
+ #include <sys/stat.h>
++#include <stddef.h>
+
+ #include "ploop.h"
+
+--- a/lib/delta_sysfs.c
++++ b/lib/delta_sysfs.c
+@@ -29,6 +29,7 @@
+ #include <linux/fs.h>
+ #include <sys/ioctl.h>
+ #include <sys/utsname.h>
++#include <sys/sysmacros.h>
+
+ #include "ploop.h"
+
+@@ -238,7 +239,7 @@ static int get_dev_num(const char *path, dev_t *dev_num)
+ ploop_err(0, "Unexpected format of %s: %s", path, nbuf);
+ return -1;
+ }
+- *dev_num = gnu_dev_makedev(maj, min);
++ *dev_num = makedev(maj, min);
+ return 0;
+ }
+
+--- a/lib/merge.c
++++ b/lib/merge.c
+@@ -29,6 +29,7 @@
+ #include <linux/types.h>
+ #include <string.h>
+ #include <assert.h>
++#include <stddef.h>
+
+ #include "ploop.h"
+
+--- a/lib/ploop.c
++++ b/lib/ploop.c
+@@ -1087,7 +1087,7 @@ static int get_mount_dir(const char *device, char *out, int size)
+
+ if (get_dev_by_name(device, &dev))
+ return -1;
+- minor = gnu_dev_minor(dev);
++ minor = minor(dev);
+
+ fp = fopen("/proc/self/mountinfo", "r");
+ if (fp == NULL) {
+@@ -1719,7 +1719,7 @@ static int create_ploop_dev(int minor)
+ make_sysfs_dev_name(minor, device + 5, sizeof(device) - 5);
+ /* Create pair /dev/ploopN & /dev/ploopNp1 */
+ if (access(device, F_OK)) {
+- if (mknod(device, S_IFBLK, gnu_dev_makedev(PLOOP_DEV_MAJOR, minor))) {
++ if (mknod(device, S_IFBLK, makedev(PLOOP_DEV_MAJOR, minor))) {
+ ploop_err(errno, "mknod %s", device);
+ return SYSEXIT_MKNOD;
+ }
+@@ -1730,7 +1730,7 @@ static int create_ploop_dev(int minor)
+ }
+ snprintf(devicep1, sizeof(devicep1), "%sp1", device);
+ if (access(devicep1, F_OK)) {
+- if (mknod(devicep1, S_IFBLK, gnu_dev_makedev(PLOOP_DEV_MAJOR, minor+1))) {
++ if (mknod(devicep1, S_IFBLK, makedev(PLOOP_DEV_MAJOR, minor+1))) {
+ ploop_err(errno, "mknod %s", devicep1);
+ return SYSEXIT_MKNOD;
+ }
diff --git a/sys-cluster/ploop/ploop-1.14.1-r1.ebuild b/sys-cluster/ploop/ploop-1.14.1-r1.ebuild
index b8086d22b8d8..1dfbcff162dc 100644
--- a/sys-cluster/ploop/ploop-1.14.1-r1.ebuild
+++ b/sys-cluster/ploop/ploop-1.14.1-r1.ebuild
@@ -24,6 +24,7 @@ RDEPEND="${DEPEND}
PATCHES=(
"${FILESDIR}"/disable_create_run_dir.patch
+ "${FILESDIR}"/${PN}-1.14-musl.patch
)
DOCS=( tools/README )
next reply other threads:[~2022-06-19 17:45 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-19 17:45 Stephan Hartmann [this message]
-- strict thread matches above, loose matches on Subject: below --
2015-10-10 14:33 [gentoo-commits] repo/gentoo:master commit in: sys-cluster/ploop/files/, sys-cluster/ploop/ Maxim Koltsov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1655660723.d2c74fe1c6bd290617186d2cd4992f005a288ca2.sultan@gentoo \
--to=sultan@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox