diff options
Diffstat (limited to 'sys-cluster/ploop/files/ploop-1.14-musl.patch')
-rw-r--r-- | sys-cluster/ploop/files/ploop-1.14-musl.patch | 78 |
1 files changed, 78 insertions, 0 deletions
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; + } |