summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2017-06-15 23:15:00 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-06-22 09:16:00 +0100
commit4c2d0b1205be2c0e42cafea1de18e46edf4a374b (patch)
tree929918f4745764c3b5618f1489e540cf0645eeb4 /meta/recipes-core
parent39df3561d8cb0d6d86d492bb462640cf2f0a760a (diff)
downloadpoky-4c2d0b1205be2c0e42cafea1de18e46edf4a374b.tar.gz
meta: Remove further uclibc remnants (inc. patches and site files)
Some of these are clearly dead, e.g. one binutils patch reverts the effects of the earlier one. This also removes the uclibc site files. We now have mechanisms to allow these to be extended from another layer should someone ever wish to do that. (From OE-Core rev: e01e7c543a559c8926d72159b5cd55db0c661434) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core')
-rw-r--r--meta/recipes-core/systemd/systemd/0006-configure-Check-for-additional-features-that-uclibc-.patch48
-rw-r--r--meta/recipes-core/systemd/systemd/0007-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch25
-rw-r--r--meta/recipes-core/systemd/systemd/0008-nspawn-Use-execvpe-only-when-libc-supports-it.patch41
-rw-r--r--meta/recipes-core/systemd/systemd/0009-util-bypass-unimplemented-_SC_PHYS_PAGES-system-conf.patch49
-rw-r--r--meta/recipes-core/systemd/systemd_232.bb3
5 files changed, 11 insertions, 155 deletions
diff --git a/meta/recipes-core/systemd/systemd/0006-configure-Check-for-additional-features-that-uclibc-.patch b/meta/recipes-core/systemd/systemd/0006-configure-Check-for-additional-features-that-uclibc-.patch
deleted file mode 100644
index 43a0d3f616..0000000000
--- a/meta/recipes-core/systemd/systemd/0006-configure-Check-for-additional-features-that-uclibc-.patch
+++ /dev/null
@@ -1,48 +0,0 @@
1From 82d837b76618a773485b96e38b7b91083a7437e8 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Fri, 20 Feb 2015 05:05:45 +0000
4Subject: [PATCH 06/19] configure: Check for additional features that uclibc
5 doesnt support
6
7This helps in supporting uclibc which does not have all features that
8glibc might have
9
10Upstream-Status: Denied [no desire for uclibc support]
11
12Signed-off-by: Khem Raj <raj.khem@gmail.com>
13---
14 configure.ac | 18 ++++++++++++++++++
15 1 file changed, 18 insertions(+)
16
17diff --git a/configure.ac b/configure.ac
18index 7f6b3b9..7c4b5a2 100644
19--- a/configure.ac
20+++ b/configure.ac
21@@ -110,6 +110,24 @@ AC_PATH_PROG([UMOUNT_PATH], [umount], [/usr/bin/umount], [$PATH:/usr/sbin:/sbin]
22
23 AS_IF([! ln --relative --help > /dev/null 2>&1], [AC_MSG_ERROR([*** ln doesn't support --relative ***])])
24
25+# check for few functions not implemented in uClibc
26+
27+AC_CHECK_FUNCS_ONCE(mkostemp execvpe posix_fallocate)
28+
29+# check for %ms format support - assume always no if cross compiling
30+
31+AC_MSG_CHECKING([whether %ms format is supported by *scanf])
32+
33+AC_LINK_IFELSE(
34+ [AC_LANG_PROGRAM([
35+ #include <stdio.h>
36+ ],[
37+ char *buf1, *buf2, *buf3, str="1 2.3 abcde" ;
38+ int rc = sscanf(str, "%ms %ms %ms", &buf1, &buf2, &buf3) ;
39+ return (rc==3)?0:1;])],
40+ [AC_DEFINE([HAVE_MSFORMAT], [1], [Define if %ms format is supported by *scanf.])],
41+ [AC_MSG_RESULT([no])])
42+
43 M4_DEFINES=
44
45 AC_CHECK_TOOL(OBJCOPY, objcopy)
46--
472.10.2
48
diff --git a/meta/recipes-core/systemd/systemd/0007-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch b/meta/recipes-core/systemd/systemd/0007-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch
index fad69a51af..bc92db7468 100644
--- a/meta/recipes-core/systemd/systemd/0007-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch
+++ b/meta/recipes-core/systemd/systemd/0007-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch
@@ -12,10 +12,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
12 configure.ac | 2 -- 12 configure.ac | 2 --
13 2 files changed, 1 insertion(+), 3 deletions(-) 13 2 files changed, 1 insertion(+), 3 deletions(-)
14 14
15diff --git a/Makefile.am b/Makefile.am 15Index: git/Makefile.am
16index 29ed1dd..02f4017 100644 16===================================================================
17--- a/Makefile.am 17--- git.orig/Makefile.am
18+++ b/Makefile.am 18+++ git/Makefile.am
19@@ -320,7 +320,7 @@ define install-relative-aliases 19@@ -320,7 +320,7 @@ define install-relative-aliases
20 while [ -n "$$1" ]; do \ 20 while [ -n "$$1" ]; do \
21 $(MKDIR_P) `dirname $(DESTDIR)$$dir/$$2` && \ 21 $(MKDIR_P) `dirname $(DESTDIR)$$dir/$$2` && \
@@ -25,19 +25,16 @@ index 29ed1dd..02f4017 100644
25 shift 2 || exit $$?; \ 25 shift 2 || exit $$?; \
26 done 26 done
27 endef 27 endef
28diff --git a/configure.ac b/configure.ac 28Index: git/configure.ac
29index 7c4b5a2..b10c952 100644 29===================================================================
30--- a/configure.ac 30--- git.orig/configure.ac
31+++ b/configure.ac 31+++ git/configure.ac
32@@ -108,8 +108,6 @@ AC_PATH_PROG([SULOGIN], [sulogin], [/usr/sbin/sulogin], [$PATH:/usr/sbin:/sbin]) 32@@ -110,8 +110,6 @@ AC_PATH_PROG([SULOGIN], [sulogin], [/usr
33 AC_PATH_PROG([MOUNT_PATH], [mount], [/usr/bin/mount], [$PATH:/usr/sbin:/sbin]) 33 AC_PATH_PROG([MOUNT_PATH], [mount], [/usr/bin/mount], [$PATH:/usr/sbin:/sbin])
34 AC_PATH_PROG([UMOUNT_PATH], [umount], [/usr/bin/umount], [$PATH:/usr/sbin:/sbin]) 34 AC_PATH_PROG([UMOUNT_PATH], [umount], [/usr/bin/umount], [$PATH:/usr/sbin:/sbin])
35 35
36-AS_IF([! ln --relative --help > /dev/null 2>&1], [AC_MSG_ERROR([*** ln doesn't support --relative ***])]) 36-AS_IF([! ln --relative --help > /dev/null 2>&1], [AC_MSG_ERROR([*** ln doesn't support --relative ***])])
37- 37-
38 # check for few functions not implemented in uClibc 38 M4_DEFINES=
39 39
40 AC_CHECK_FUNCS_ONCE(mkostemp execvpe posix_fallocate) 40 AC_CHECK_TOOL(OBJCOPY, objcopy)
41--
422.10.2
43
diff --git a/meta/recipes-core/systemd/systemd/0008-nspawn-Use-execvpe-only-when-libc-supports-it.patch b/meta/recipes-core/systemd/systemd/0008-nspawn-Use-execvpe-only-when-libc-supports-it.patch
deleted file mode 100644
index 586b5aab7d..0000000000
--- a/meta/recipes-core/systemd/systemd/0008-nspawn-Use-execvpe-only-when-libc-supports-it.patch
+++ /dev/null
@@ -1,41 +0,0 @@
1From 96026a3763264eb41a2c3e374f232f6e543284a8 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Wed, 9 Nov 2016 19:33:49 -0800
4Subject: [PATCH 08/19] nspawn: Use execvpe only when libc supports it
5
6Upstream-Status: Denied [no desire for uclibc support]
7
8Signed-off-by: Khem Raj <raj.khem@gmail.com>
9---
10 src/nspawn/nspawn.c | 7 +++++++
11 1 file changed, 7 insertions(+)
12
13diff --git a/src/nspawn/nspawn.c b/src/nspawn/nspawn.c
14index 9b9ae90..19b47cd 100644
15--- a/src/nspawn/nspawn.c
16+++ b/src/nspawn/nspawn.c
17@@ -123,6 +123,8 @@ typedef enum LinkJournal {
18 LINK_GUEST
19 } LinkJournal;
20
21+#include "config.h"
22+
23 static char *arg_directory = NULL;
24 static char *arg_template = NULL;
25 static char *arg_chdir = NULL;
26@@ -2871,7 +2873,12 @@ static int inner_child(
27 a[0] = (char*) "/sbin/init";
28 execve(a[0], a, env_use);
29 } else if (!strv_isempty(arg_parameters))
30+#ifdef HAVE_EXECVPE
31 execvpe(arg_parameters[0], arg_parameters, env_use);
32+#else
33+ environ = env_use;
34+ execvp(arg_parameters[0], arg_parameters);
35+#endif /* HAVE_EXECVPE */
36 else {
37 if (!arg_chdir)
38 /* If we cannot change the directory, we'll end up in /, that is expected. */
39--
402.10.2
41
diff --git a/meta/recipes-core/systemd/systemd/0009-util-bypass-unimplemented-_SC_PHYS_PAGES-system-conf.patch b/meta/recipes-core/systemd/systemd/0009-util-bypass-unimplemented-_SC_PHYS_PAGES-system-conf.patch
deleted file mode 100644
index f150bb087a..0000000000
--- a/meta/recipes-core/systemd/systemd/0009-util-bypass-unimplemented-_SC_PHYS_PAGES-system-conf.patch
+++ /dev/null
@@ -1,49 +0,0 @@
1From 085c8b6f253726ad547e7be84ff3f2b99701488b Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Wed, 9 Nov 2016 19:38:07 -0800
4Subject: [PATCH 09/19] util: bypass unimplemented _SC_PHYS_PAGES system
5 configuration API on uclibc
6
7Upstream-Status: Inappropriate [uclibc-specific]
8
9Signed-off-by: Khem Raj <raj.khem@gmail.com>
10---
11 src/basic/util.c | 15 +++++++++++++++
12 1 file changed, 15 insertions(+)
13
14diff --git a/src/basic/util.c b/src/basic/util.c
15index c1b5ca1..4c62d43 100644
16--- a/src/basic/util.c
17+++ b/src/basic/util.c
18@@ -742,6 +742,20 @@ uint64_t physical_memory(void) {
19 * In order to support containers nicely that have a configured memory limit we'll take the minimum of the
20 * physically reported amount of memory and the limit configured for the root cgroup, if there is any. */
21
22+#ifdef __UCLIBC__
23+ char line[128];
24+ FILE *f = fopen("/proc/meminfo", "r");
25+ if (f == NULL)
26+ return 0;
27+ while (!feof(f) && fgets(line, sizeof(line)-1, f)) {
28+ if (sscanf(line, "MemTotal: %li kB", &mem) == 1) {
29+ mem *= 1024;
30+ break;
31+ }
32+ }
33+ fclose(f);
34+ return (uint64_t) mem;
35+#else
36 sc = sysconf(_SC_PHYS_PAGES);
37 assert(sc > 0);
38
39@@ -762,6 +776,7 @@ uint64_t physical_memory(void) {
40 lim *= ps;
41
42 return MIN(mem, lim);
43+#endif
44 }
45
46 uint64_t physical_memory_scale(uint64_t v, uint64_t max) {
47--
482.10.2
49
diff --git a/meta/recipes-core/systemd/systemd_232.bb b/meta/recipes-core/systemd/systemd_232.bb
index a6e6401da7..d54e92707f 100644
--- a/meta/recipes-core/systemd/systemd_232.bb
+++ b/meta/recipes-core/systemd/systemd_232.bb
@@ -18,10 +18,7 @@ SRC_URI += " \
18 file://0003-define-exp10-if-missing.patch \ 18 file://0003-define-exp10-if-missing.patch \
19 file://0004-Use-getenv-when-secure-versions-are-not-available.patch \ 19 file://0004-Use-getenv-when-secure-versions-are-not-available.patch \
20 file://0005-binfmt-Don-t-install-dependency-links-at-install-tim.patch \ 20 file://0005-binfmt-Don-t-install-dependency-links-at-install-tim.patch \
21 file://0006-configure-Check-for-additional-features-that-uclibc-.patch \
22 file://0007-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch \ 21 file://0007-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch \
23 file://0008-nspawn-Use-execvpe-only-when-libc-supports-it.patch \
24 file://0009-util-bypass-unimplemented-_SC_PHYS_PAGES-system-conf.patch \
25 file://0010-implment-systemd-sysv-install-for-OE.patch \ 22 file://0010-implment-systemd-sysv-install-for-OE.patch \
26 file://0011-nss-mymachines-Build-conditionally-when-HAVE_MYHOSTN.patch \ 23 file://0011-nss-mymachines-Build-conditionally-when-HAVE_MYHOSTN.patch \
27 file://0012-rules-whitelist-hd-devices.patch \ 24 file://0012-rules-whitelist-hd-devices.patch \