summaryrefslogtreecommitdiffstats
path: root/package/systemd/systemd-fix-page-size.patch
diff options
context:
space:
mode:
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>2014-02-12 23:13:00 +0100
committerPeter Korsgaard <peter@korsgaard.com>2014-02-13 21:51:08 +0100
commit55ad3cfd3f9809f4a1f0210fe7c7110d147c54f6 (patch)
tree7ef032528fbed74bbdf918d32ba8c920f56cea53 /package/systemd/systemd-fix-page-size.patch
parent2f78767bb84a5c536a7fc3129b9460acada7426e (diff)
downloadbuildroot-55ad3cfd3f9809f4a1f0210fe7c7110d147c54f6.tar.gz
buildroot-55ad3cfd3f9809f4a1f0210fe7c7110d147c54f6.zip
systemd: fix build with uClibc toolchains
Currently, the build of systemd is broken with the internal toolchain backend, because we have uClibc patches that add support for execvpe(), but we also have a patch for systemd that adds execvpe(), which was added when the internal uClibc didn't support execvpe(). However, simply dropping the patch is not a solution, as it would break the build of systemd with any other uClibc than the ones built with Buildroot. For example, a Crosstool-NG uClibc toolchain would fail. Beyond this execvpe() problem, there are also other problems that prevented systemd from being built with unpatched uClibc. This patch does the following: * Add sequence numbers of systemd patches. * Regenerate them to avoid fuzz. * Improve the uClibc compatibility patch so that it: - Detects whether execvpe() is available or not, and if not available provide an implementation. - Detects if dup3() is available or not, and if not available provide an implementation. - Detects if MSG_CMSG_CLOEXEC is defined or not, and if not, define it to the appropriate value. This has been tested with uClibc internal toolchain, uClibc external toolchain built with Buildroot, uClibc external toolchain built with Crosstool-NG, and glibc external toolchain. Fixes bug #6776. Fixes: http://autobuild.buildroot.org/results/591/591c6055430da334bd1e46e7d01497add45da837/build-end.log http://autobuild.buildroot.org/results/e58/e5851939d2837d4e35a4c1d9ca6df3c93ed5a34b/build-end.log http://autobuild.buildroot.org/results/92e/92e4c40c69a3feb4046b2fe5a0d8c69d5a44a157/build-end.log Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Diffstat (limited to 'package/systemd/systemd-fix-page-size.patch')
-rw-r--r--package/systemd/systemd-fix-page-size.patch43
1 files changed, 0 insertions, 43 deletions
diff --git a/package/systemd/systemd-fix-page-size.patch b/package/systemd/systemd-fix-page-size.patch
deleted file mode 100644
index 241ceb8c0b..0000000000
--- a/package/systemd/systemd-fix-page-size.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-commit 7264278fbbdc1dc6c30fedc902d1337594aa6ff6
-Author: Lennart Poettering <lennart@poettering.net>
-Date: Wed Mar 21 23:47:44 2012 +0100
-
- journal: PAGE_SIZE is not known on ppc and other archs
-
- Let's use NAME_MAX, as suggested by Dan Walsh
-
-diff --git a/src/journal/journald.c b/src/journal/journald.c
-index d27cb60..87390bd 100644
---- a/src/journal/journald.c
-+++ b/src/journal/journald.c
-@@ -29,7 +29,6 @@
- #include <sys/ioctl.h>
- #include <linux/sockios.h>
- #include <sys/statvfs.h>
--#include <sys/user.h>
-
- #include <systemd/sd-journal.h>
- #include <systemd/sd-login.h>
-@@ -2149,10 +2148,20 @@ static int process_event(Server *s, struct epoll_event *ev) {
- size_t label_len = 0;
- union {
- struct cmsghdr cmsghdr;
-+
-+ /* We use NAME_MAX space for the
-+ * SELinux label here. The kernel
-+ * currently enforces no limit, but
-+ * according to suggestions from the
-+ * SELinux people this will change and
-+ * it will probably be identical to
-+ * NAME_MAX. For now we use that, but
-+ * this should be updated one day when
-+ * the final limit is known.*/
- uint8_t buf[CMSG_SPACE(sizeof(struct ucred)) +
- CMSG_SPACE(sizeof(struct timeval)) +
-- CMSG_SPACE(sizeof(int)) +
-- CMSG_SPACE(PAGE_SIZE)]; /* selinux label */
-+ CMSG_SPACE(sizeof(int)) + /* fd */
-+ CMSG_SPACE(NAME_MAX)]; /* selinux label */
- } control;
- ssize_t n;
- int v;
OpenPOWER on IntegriCloud