From 623ee73d661e5ed8475cb264511f683407d87365 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sun, 12 Apr 2020 03:41:30 +0100 Subject: gentoo Easter resync : 12.04.2020 --- sys-apps/systemd/Manifest | 17 +- sys-apps/systemd/files/245-clang-gnu11.patch | 60 +++ sys-apps/systemd/files/245-rc1-network-debug.patch | 45 -- .../systemd/files/245-rc1-sysctl-segfault.patch | 23 - sys-apps/systemd/metadata.xml | 2 + sys-apps/systemd/systemd-243-r2.ebuild | 3 +- sys-apps/systemd/systemd-244.3.ebuild | 3 +- sys-apps/systemd/systemd-244.ebuild | 3 +- sys-apps/systemd/systemd-245-r2.ebuild | 520 +++++++++++++++++++++ sys-apps/systemd/systemd-245_rc1-r2.ebuild | 512 -------------------- sys-apps/systemd/systemd-9999.ebuild | 15 +- 11 files changed, 608 insertions(+), 595 deletions(-) create mode 100644 sys-apps/systemd/files/245-clang-gnu11.patch delete mode 100644 sys-apps/systemd/files/245-rc1-network-debug.patch delete mode 100644 sys-apps/systemd/files/245-rc1-sysctl-segfault.patch create mode 100644 sys-apps/systemd/systemd-245-r2.ebuild delete mode 100644 sys-apps/systemd/systemd-245_rc1-r2.ebuild (limited to 'sys-apps/systemd') diff --git a/sys-apps/systemd/Manifest b/sys-apps/systemd/Manifest index 85f3d29829a3..c8f5fc4d207d 100644 --- a/sys-apps/systemd/Manifest +++ b/sys-apps/systemd/Manifest @@ -1,18 +1,17 @@ AUX 243-seccomp.patch 6293 BLAKE2B be1a78783e34d6cf8ba33f6ae6fb0e8747d414de692cf28bd9cce01ca47baf188b078171dd66c236ecf2a4a821f1dec0b7021e1298a29a3b21aacf3a9d667189 SHA512 da2cd2e11a06e0520af0ad3c6debe54c5ab046f7ee35a922c99a32924464a6b760b4620d8e511064f84d8adbf5e65db473877476a1cc36941a0420491b89cb25 AUX 244-efi-gcc-10.patch 3032 BLAKE2B f9fd018c567384171b154809bb95b35c18fc9c3ad7d5c114f5854bb90db2bdafca9d96c3437a9d20a7ea875a3e5646750f29294025fcb657a40dcd7d4ed95282 SHA512 f9bbc9c3be417ff14775de06d3c4088913eff4c6f62e58278420345cbc7b115b706c169faaae9dc17448f895d9cf9b417ee8c04398ec4c206df89f5f3bcfb4a1 -AUX 245-rc1-network-debug.patch 1915 BLAKE2B b4e2fc470e584520c0423b06d00e663fb82e364594626e89632e9db4dd503b55c419f844c5063ca7f8641919ff47d3057f6962e269686829041ea262e75504ae SHA512 d55dac6e5b11d066eff46b0387b64d1cf59b9c4134171b17933447064f0ea0ca774681134be20e0af40f3de03f971778cf358d38bca78107e7129d3d86e7065e -AUX 245-rc1-sysctl-segfault.patch 942 BLAKE2B 00fc826da41bfe0bb42e86bb839dc441d0762993ddabc227097865061a706a0598e1bd1ef4451b8ba11f702ba66ab1b9281e2141fcffed054c787206bb78966a SHA512 d92f4ac03d1ddb84a9ff2bb90efc92a7d0394165fa0dd7d3fa0739e1480b847e11ec522a3d6dc907998455df19c1b300c046a404f7c4226e77aa10f51fff37a5 +AUX 245-clang-gnu11.patch 3167 BLAKE2B 4d254ae7ffc906d282580805a041ac2c11552ff6e7569cc06709faf6fe0894d9c9856ba54783e141341c512a401428390f7233050921e5e045b867f7e517f298 SHA512 6261c71cb4afbbbe5189f7ac01bf7cc50139edca4175f6f821941e012f5f4335835eef518e187996612e174159947a4fc2fec70fdbb16c8cdfa82369c7f4c814 AUX gentoo-Dont-enable-audit-by-default.patch 1027 BLAKE2B 9193a409db4e5c1dec6f6b66ee6e0a4cc1ada49d41ab758c788cf12534fffb67bd7370b8558a6af56572d7f2b73cf47db255fef105e56362c15f0a426f80b256 SHA512 44e512d8bbadbc5714192896a3ba262e460af034846e4e9b9832b4143fff772e2734e655316fd88d1ef386509bd234c195dce2087348f220836b3bf4f26790e0 AUX gentoo-generator-path-r1.patch 1037 BLAKE2B 5eb80521a6726c9b4693f9b0f56d3e68fca1a49f5f5eb5a1576329d30c93d2fe7c121920099d74962eacf7ed1d3747250f103a57e4be246320a99871521a3b6a SHA512 1b0d1c2f96cb4aa95adfa5940efaeb2bd940110720399358317906d21d08b0caf625474980e101bba001afd626f8ad64367b09b40bec0b2d46b977021c4adfc5 AUX gentoo-systemd-user-pam.patch 443 BLAKE2B fad5c24f35666313efbf1e33640320058022fe17acff869a80104ed87ce0ad7ebaa1498915f8e933985e9c2d66d77172eb21ab480fc4fa857e0e5b985735831a SHA512 0a47368b1b38995a4193492e3add5c716c063366a9bc53dec03b7cb59b524da644033e095344da6e15e01dc84d8f5b335e7510442eeaba26e06918403fed0e5c AUX nsswitch.conf 734 BLAKE2B 5f5a7821a84f6c8aa31fe9a68c29a1a0f24be578d427a623f14a9ef795e7da481f226efe5511d92932b5edf5638fa719808a0c3a0b8fd340799dd6bcb703a0a1 SHA512 dcbd51dacaaebdff32edb3840cc7b9b47b6521009b8786690e3673a2e78bc60bfd8e591b1048c5d452117c6659b9917ae2864462f5057cc39b704b0130522e60 DIST systemd-243.tar.gz 8242522 BLAKE2B 89e3ebbea5a99061329f7c78220a66c1e075d5ba90dfdf5ee8d0d9b762ef4600dc82d8ca2054632e5e343b6272cd8046c92f7f99dcfa8287c5ef2b42fb96d4cb SHA512 56b52a297aa5ac04d9667eb3afb1598725b197de73ff72baa1aabbc2844e36fba7b7fccdf6d214ae8b5b926616b2b7e15772763aaa80ec938d74333ff9c8673e DIST systemd-244.tar.gz 8445963 BLAKE2B 19751fb9c058a079694ee1b991259fd3f1fa30ae98ca38bbe8caadfc5628db7848c7f742a1b11781fbd67f911adda917d7a4da1dddb63064907f86f47e5a3256 SHA512 08f260fb15b5eb273faafda826dd9154e9a02841b4c5911cc1c7e1445072ad51389f8cced7b9acf112737c20fd56b2fbf48b3f914733c934c774d38a23b616fb -DIST systemd-245-rc1.tar.gz 8961356 BLAKE2B ed04166ead57c2f1cc1a1ca2f0041cae134b503d3448ea9fdd799e12d81f45721ee304d4aabd96d3eab8ea1321b283820e8d2a850b41733e40f07fd419f67b95 SHA512 2ef9a295f3897c6642a2fac2e3c73467ece9bc6fc196cc4f3707b9c23af2581eb9f74def78909d57513b67604bf1cf6dc5dbb31c6d435f7997677d09a73d006b +DIST systemd-245.tar.gz 8993479 BLAKE2B be0b1fca5ba8585978f570868bc9135c1fee78ea64dcdf8b1a3419e856a83da90104ed2f86e5f3e5b0b6f29d4b34f603bfe1e4cbc61ccf71bedce547db62ff35 SHA512 1b80d0e02472dfc4197f11dab4f56cf90e8a6e105ce19f837cb11335b6d8577ed49031dad94cdb41aa9bdc06ec8eec62c8e9246272b83935e7bb9dcd3cd8c012 DIST systemd-stable-244.3.tar.gz 8484735 BLAKE2B 25125ecdae59c852e8ceb45b7ed0b76631b301ab4026c4e389c4bc12090fe41f5918411a75bd20f38b6b3993445df93c850ba98f8d9b30fd24fc4e25f8355a3d SHA512 f8e83fa3e57ac8fdbed61b66bb45fd0eafa6fb36eda26f10690d93f34b03daab6ce4e7eff45b79dcaf59f11f41c1b022d1d9314f576c50ad28f6bb5901f1b18d -EBUILD systemd-243-r2.ebuild 14551 BLAKE2B 7cc961a76f605d29fac9f931de5cd940d86bf8d113b5f9411f3da43a39632967e08c7065b26b8de55352f3ef9922a366b4756ad84e45544b75b08e51e882c602 SHA512 0d30a2ff1c48fa61ea34b6d9b2da84bb776f332c327c172cfbd68e1adf7a21488b28619f080190a84c81e62a7215f5f0bcabe5f8ed653afae5ebdd4a4448d40b -EBUILD systemd-244.3.ebuild 14547 BLAKE2B 5b747e450e2cc3408082ef17704dfab6564bcdadee7f3b9339fb379d47146a1ffa30d4844d5e8d63b669cdcb58bfc75537ffeb058e7d018c4152636d8ff047a9 SHA512 060abc374a7f35347109109907075a302b6481012c1a8cafc40634986ff214177106ac03b8fca7c29de23b5576800032c19b911b929786bb3564309a8c19381b -EBUILD systemd-244.ebuild 14531 BLAKE2B 97622ec92021c12016bb8f1e2181eef6573af83e4e71bc5bca31c05fbf3eea2ba674f77b69e152aa49bf4dae0068483df244c5ba29efc58fd2b995062286fa48 SHA512 871185ea400df7ca5bc90467a37b62380da20d8149f7d8f47f629e95a37da209c4754c397fefc6d11be58aee6a878534c2ea66ec479a2b63bfbebd1348dcbc67 -EBUILD systemd-245_rc1-r2.ebuild 14832 BLAKE2B 844021148e36863564bfd260f277919998f9c6ebb792796fb1ae9e9a46c72c8c04b2505b851da0c6c89ac1e6e9cca9ed1edfc99aaaf452272f52aff2a5d0e98b SHA512 85df145d991791c8330ac8dd5b7c6dd08d5cf62d1bf11998672016582452fedd5d25a2e5fbddab012034a55f06298b06614091849939497ff77aefc00f220e50 -EBUILD systemd-9999.ebuild 14742 BLAKE2B f19eab68908becf058b7e6e706204425951c392c010c9259ff7703771c899e046287fee721cd65f8b06f2cd1de5b509799c7ffebd16cff502d150b7e7645d509 SHA512 d757c4e343f546371dd409193b8eff4cb10a864b1cc2722434ca0278211e2efc399070654a4635cc76718e6620e0e6b5dd0c565a32b2f4912f941da08b14c7ea -MISC metadata.xml 2170 BLAKE2B 40691c4b4248e8296325a2cd167f1485c28f50a2814320e151c03ac7293023b5720f8200ea6a314f853ac330994de2b8b79d50a4ee8412454be95c22c9580176 SHA512 77351af149533d7c8a8a0cb0308cae1fae1f45eaa533a52209fb63c9cb3aa54b0782796fccd480ab2c41c5ba7e2eda8e195f4b68a1a2487a9dfd0b22ea874c1f +EBUILD systemd-243-r2.ebuild 14590 BLAKE2B 536b1996e88366d7aa24a474305f05ca2cd6d5e4f026c1fd8392679fd21bf1bba28ca8bf39121427faa1fd412fa3950d45e863e75a9cf2e4f16b3c499da68555 SHA512 49b6883b2a72a986a32bf084fb962698399449859b3dba42db6a08090a018a7598f4af0eb05dd86615005e72e3b4a72d0c4da7891407b1e0537cf7953c5510ab +EBUILD systemd-244.3.ebuild 14582 BLAKE2B 47660116f69e9b59f0fc125d206f41cb7a94b0d70245c6ce92de957ab294fe6e969797ff05d16dec46fe6430173dae0a29ec68fe99ea960e18d731e231a5f038 SHA512 00034a5c3ee577d1719756aab0721c23ee1b944896d875fc1fb81c41481aa1683b6d155ed42ba3ba2979b2a2b44c2231dc531f888b8fe4b9fcaf80260a712c06 +EBUILD systemd-244.ebuild 14570 BLAKE2B 918be50336353a5d5512653c61ed6c1e1cbb4f8e49ec7fd8b1eeb5436951ad82b3d7aa7fa0e313681a952dcbd64c7fd899bb5ac3a7a319a4508d099a358a8ab6 SHA512 1b9d610e10c5c1a21d80395a3a68f82f4201f6b1c23d7e57f98e09cb509a133e60484c5e72ae0c78819a189b930b2f77cca84e869af9f03fbc5a3a4ac9448ab2 +EBUILD systemd-245-r2.ebuild 15009 BLAKE2B 945f285053fa32d29c0c19032e1acbf4af2a0ca7641a5cd9b7b4de944d5309d8eb5ed3c6bbdbd60be494caea1677b730a3ecb4d6cbd2d5fdddce4b1d15d6f444 SHA512 bd9dd09b7d2a8f072235aaa3045d842c96fc93c4c14c8a8d97c2ad3f3c34ed0ac5ac59c164d796503bbf5c07c42762631ded479cd2c50aa30b7222993cf57bad +EBUILD systemd-9999.ebuild 14971 BLAKE2B b5d61f8f72003b93d42e0710fb9e73ac29a0033a96d0586b165264e6d59ce0361c39d4f56fdfa17d792cc53a608f93ee18b5e0431a6deb4275ea9c3140ae6431 SHA512 6bba52ec5ea5781b8538c60d947a2beb3a676461406103780d5b59b4f7dad6872c739c4a462e5d302d74c4fad0a6f6a2b35dc3a9ac112b96c8b2768520cf70ce +MISC metadata.xml 2305 BLAKE2B ae8b39dbfa828f47622fb234a6f76255ed3357d370408686ceac8141a4068cf49954ebf203c9e1d31dcb7d70552f7768ef9f4308169e1c96685b375287dc113d SHA512 bc6a8c7317e3b39b5dd0268d89bfa99592f18ecb18e32b1e2a93659748547909c66e423ca30a79d5044bee31af2fd7a3ff386ddcbf6a456898471db4387cf909 diff --git a/sys-apps/systemd/files/245-clang-gnu11.patch b/sys-apps/systemd/files/245-clang-gnu11.patch new file mode 100644 index 000000000000..9056b56d48ee --- /dev/null +++ b/sys-apps/systemd/files/245-clang-gnu11.patch @@ -0,0 +1,60 @@ +From 36e0d89a88c51ba879a2d7e2f90ea9b38333e2c0 Mon Sep 17 00:00:00 2001 +From: Denis Pronin +Date: Sun, 8 Mar 2020 23:57:07 +0300 +Subject: [PATCH] Support compiling with clang and gnu11 standard + +Signed-off-by: Denis Pronin +--- + src/shared/json-internal.h | 35 ++++++++++++++++++++++++----------- + 1 file changed, 24 insertions(+), 11 deletions(-) + +diff --git a/src/shared/json-internal.h b/src/shared/json-internal.h +index bf158bff0d4..fabff0c860e 100644 +--- a/src/shared/json-internal.h ++++ b/src/shared/json-internal.h +@@ -26,21 +26,34 @@ assert_cc(sizeof(JsonValue) == 16U); + /* We use fake JsonVariant objects for some special values, in order to avoid memory allocations for them. Note that + * effectively this means that there are multiple ways to encode the same objects: via these magic values or as + * properly allocated JsonVariant. We convert between both on-the-fly as necessary. */ +-#define JSON_VARIANT_MAGIC_TRUE ((JsonVariant*) 1) +-#define JSON_VARIANT_MAGIC_FALSE ((JsonVariant*) 2) +-#define JSON_VARIANT_MAGIC_NULL ((JsonVariant*) 3) +-#define JSON_VARIANT_MAGIC_ZERO_INTEGER ((JsonVariant*) 4) +-#define JSON_VARIANT_MAGIC_ZERO_UNSIGNED ((JsonVariant*) 5) +-#define JSON_VARIANT_MAGIC_ZERO_REAL ((JsonVariant*) 6) +-#define JSON_VARIANT_MAGIC_EMPTY_STRING ((JsonVariant*) 7) +-#define JSON_VARIANT_MAGIC_EMPTY_ARRAY ((JsonVariant*) 8) +-#define JSON_VARIANT_MAGIC_EMPTY_OBJECT ((JsonVariant*) 9) +-#define _JSON_VARIANT_MAGIC_MAX ((JsonVariant*) 10) ++enum ++{ ++ _JSON_VARIANT_MAGIC_TRUE = 1, ++#define JSON_VARIANT_MAGIC_TRUE ((JsonVariant*) _JSON_VARIANT_MAGIC_TRUE) ++ _JSON_VARIANT_MAGIC_FALSE, ++#define JSON_VARIANT_MAGIC_FALSE ((JsonVariant*) _JSON_VARIANT_MAGIC_FALSE) ++ _JSON_VARIANT_MAGIC_NULL, ++#define JSON_VARIANT_MAGIC_NULL ((JsonVariant*) _JSON_VARIANT_MAGIC_NULL) ++ _JSON_VARIANT_MAGIC_ZERO_INTEGER, ++#define JSON_VARIANT_MAGIC_ZERO_INTEGER ((JsonVariant*) _JSON_VARIANT_MAGIC_ZERO_INTEGER) ++ _JSON_VARIANT_MAGIC_ZERO_UNSIGNED, ++#define JSON_VARIANT_MAGIC_ZERO_UNSIGNED ((JsonVariant*) _JSON_VARIANT_MAGIC_ZERO_UNSIGNED) ++ _JSON_VARIANT_MAGIC_ZERO_REAL, ++#define JSON_VARIANT_MAGIC_ZERO_REAL ((JsonVariant*) _JSON_VARIANT_MAGIC_ZERO_REAL) ++ _JSON_VARIANT_MAGIC_EMPTY_STRING, ++#define JSON_VARIANT_MAGIC_EMPTY_STRING ((JsonVariant*) _JSON_VARIANT_MAGIC_EMPTY_STRING) ++ _JSON_VARIANT_MAGIC_EMPTY_ARRAY, ++#define JSON_VARIANT_MAGIC_EMPTY_ARRAY ((JsonVariant*) _JSON_VARIANT_MAGIC_EMPTY_ARRAY) ++ _JSON_VARIANT_MAGIC_EMPTY_OBJECT, ++#define JSON_VARIANT_MAGIC_EMPTY_OBJECT ((JsonVariant*) _JSON_VARIANT_MAGIC_EMPTY_OBJECT) ++ __JSON_VARIANT_MAGIC_MAX ++#define _JSON_VARIANT_MAGIC_MAX ((JsonVariant*) __JSON_VARIANT_MAGIC_MAX) ++}; + + /* This is only safe as long as we don't define more than 4K magic pointers, i.e. the page size of the simplest + * architectures we support. That's because we rely on the fact that malloc() will never allocate from the first memory + * page, as it is a faulting page for catching NULL pointer dereferences. */ +-assert_cc((uintptr_t) _JSON_VARIANT_MAGIC_MAX < 4096U); ++assert_cc((unsigned) __JSON_VARIANT_MAGIC_MAX < 4096U); + + enum { /* JSON tokens */ + JSON_TOKEN_END, diff --git a/sys-apps/systemd/files/245-rc1-network-debug.patch b/sys-apps/systemd/files/245-rc1-network-debug.patch deleted file mode 100644 index e65035f21857..000000000000 --- a/sys-apps/systemd/files/245-rc1-network-debug.patch +++ /dev/null @@ -1,45 +0,0 @@ -From 01ec0028d97fa97d2e433659e24a1517b0e2382e Mon Sep 17 00:00:00 2001 -From: Mike Gilbert -Date: Wed, 5 Feb 2020 11:04:50 -0500 -Subject: [PATCH] network: remove unnecessary link->ifname from debug log - statements - -Since 98b0299479a68ffd414888368907fc776a46b82a, we log the interface -name automatically via log_link_debug(). - -Fixes: https://github.com/systemd/systemd/issues/14782 ---- - src/network/networkd-dhcp-server.c | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/src/network/networkd-dhcp-server.c b/src/network/networkd-dhcp-server.c -index a6dbe2e596c..bee75a6930e 100644 ---- a/src/network/networkd-dhcp-server.c -+++ b/src/network/networkd-dhcp-server.c -@@ -45,7 +45,7 @@ static int link_push_uplink_dns_to_dhcp_server(Link *link, sd_dhcp_server *s) { - size_t n_addresses = 0, n_allocated = 0; - unsigned i; - -- log_link_debug(link, "Copying DNS server information from %s", link->ifname); -+ log_link_debug(link, "Copying DNS server information from link"); - - if (!link->network) - return 0; -@@ -99,7 +99,7 @@ static int link_push_uplink_ntp_to_dhcp_server(Link *link, sd_dhcp_server *s) { - if (!link->network) - return 0; - -- log_link_debug(link, "Copying NTP server information from %s", link->ifname); -+ log_link_debug(link, "Copying NTP server information from link"); - - STRV_FOREACH(a, link->network->ntp) { - union in_addr_union ia; -@@ -148,7 +148,7 @@ static int link_push_uplink_sip_to_dhcp_server(Link *link, sd_dhcp_server *s) { - if (!link->network) - return 0; - -- log_link_debug(link, "Copying SIP server information from %s", link->ifname); -+ log_link_debug(link, "Copying SIP server information from link"); - - STRV_FOREACH(a, link->network->sip) { - union in_addr_union ia; diff --git a/sys-apps/systemd/files/245-rc1-sysctl-segfault.patch b/sys-apps/systemd/files/245-rc1-sysctl-segfault.patch deleted file mode 100644 index 7618b2deba5e..000000000000 --- a/sys-apps/systemd/files/245-rc1-sysctl-segfault.patch +++ /dev/null @@ -1,23 +0,0 @@ -From db99904bc8482efe556bb010a8b203a3e60ee37f Mon Sep 17 00:00:00 2001 -From: Yu Watanabe -Date: Thu, 6 Feb 2020 19:13:11 +0900 -Subject: [PATCH] sysctl: fix segfault - -Fixes #14801. ---- - src/sysctl/sysctl.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/sysctl/sysctl.c b/src/sysctl/sysctl.c -index bbcf0c43235..0cdb740d218 100644 ---- a/src/sysctl/sysctl.c -+++ b/src/sysctl/sysctl.c -@@ -257,7 +257,7 @@ static int parse_file(OrderedHashmap **sysctl_options, const char *path, bool ig - - existing = ordered_hashmap_get(*sysctl_options, p); - if (existing) { -- if (streq(value, existing->value)) { -+ if (streq_ptr(value, existing->value)) { - existing->ignore_failure = existing->ignore_failure || ignore_failure; - continue; - } diff --git a/sys-apps/systemd/metadata.xml b/sys-apps/systemd/metadata.xml index fdbbc809fd18..336245a670ab 100644 --- a/sys-apps/systemd/metadata.xml +++ b/sys-apps/systemd/metadata.xml @@ -18,6 +18,7 @@ Enable EFI boot manager and stub loader (built using sys-boot/gnu-efi) Enable coredump stacktraces in the journal Enable sealing of journal files using gcrypt + Enable portable home directories Enable embedded HTTP server in journald Enable import daemon Enable kernel module loading via sys-apps/kmod @@ -25,6 +26,7 @@ Enable support for network address translation in networkd Enable PKCS#11 support for cryptsetup and homed Enable password quality checking in homed + Enable support for growing/adding partitions Enable qrcode output support in journal Install resolvconf symlink for systemd-resolve Install sysvinit compatibility symlinks and manpages for init, telinit, halt, poweroff, reboot, runlevel, and shutdown diff --git a/sys-apps/systemd/systemd-243-r2.ebuild b/sys-apps/systemd/systemd-243-r2.ebuild index 5c4c417bc344..62ea76aad71d 100644 --- a/sys-apps/systemd/systemd-243-r2.ebuild +++ b/sys-apps/systemd/systemd-243-r2.ebuild @@ -11,7 +11,7 @@ else MY_P=${PN}-${MY_PV} S=${WORKDIR}/${MY_P} SRC_URI="https://github.com/systemd/systemd/archive/v${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="~alpha amd64 arm arm64 ~hppa ia64 ~mips ppc ppc64 sparc x86" + KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 sparc x86" fi PYTHON_COMPAT=( python{3_6,3_7} ) @@ -188,6 +188,7 @@ src_prepare() { # Add local patches here PATCHES+=( "${FILESDIR}/243-seccomp.patch" + "${FILESDIR}/245-clang-gnu11.patch" ) if ! use vanilla; then diff --git a/sys-apps/systemd/systemd-244.3.ebuild b/sys-apps/systemd/systemd-244.3.ebuild index 1acea5bfd495..2c8406ec99c6 100644 --- a/sys-apps/systemd/systemd-244.3.ebuild +++ b/sys-apps/systemd/systemd-244.3.ebuild @@ -16,7 +16,7 @@ else MY_P=${MY_PN}-${MY_PV} S=${WORKDIR}/${MY_P} SRC_URI="https://github.com/systemd/${MY_PN}/archive/v${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="~alpha amd64 ~arm ~arm64 ~hppa ia64 ~mips ~ppc ~ppc64 ~sparc x86" + KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ~ppc ppc64 sparc x86" fi PYTHON_COMPAT=( python3_{6,7,8} ) @@ -192,6 +192,7 @@ src_prepare() { # Add local patches here PATCHES+=( + "${FILESDIR}/245-clang-gnu11.patch" ) if ! use vanilla; then diff --git a/sys-apps/systemd/systemd-244.ebuild b/sys-apps/systemd/systemd-244.ebuild index 49383fe9a6f3..04b0c3c377d5 100644 --- a/sys-apps/systemd/systemd-244.ebuild +++ b/sys-apps/systemd/systemd-244.ebuild @@ -11,7 +11,7 @@ else MY_P=${PN}-${MY_PV} S=${WORKDIR}/${MY_P} SRC_URI="https://github.com/systemd/systemd/archive/v${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ia64 ~mips ppc ppc64 sparc x86" + KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ~mips ppc ppc64 sparc x86" fi PYTHON_COMPAT=( python{3_6,3_7} ) @@ -188,6 +188,7 @@ src_prepare() { # Add local patches here PATCHES+=( "${FILESDIR}"/244-efi-gcc-10.patch + "${FILESDIR}/245-clang-gnu11.patch" ) if ! use vanilla; then diff --git a/sys-apps/systemd/systemd-245-r2.ebuild b/sys-apps/systemd/systemd-245-r2.ebuild new file mode 100644 index 000000000000..6b80478fa7e0 --- /dev/null +++ b/sys-apps/systemd/systemd-245-r2.ebuild @@ -0,0 +1,520 @@ +# Copyright 2011-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +if [[ ${PV} == 9999 ]]; then + EGIT_REPO_URI="https://github.com/systemd/systemd.git" + inherit git-r3 +else + if [[ ${PV} == *.* ]]; then + MY_PN=systemd-stable + else + MY_PN=systemd + fi + MY_PV=${PV/_/-} + MY_P=${MY_PN}-${MY_PV} + S=${WORKDIR}/${MY_P} + SRC_URI="https://github.com/systemd/${MY_PN}/archive/v${MY_PV}/${MY_P}.tar.gz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86" +fi + +PYTHON_COMPAT=( python3_{6,7,8} ) + +inherit bash-completion-r1 linux-info meson multilib-minimal ninja-utils pam python-any-r1 systemd toolchain-funcs udev usr-ldscript + +DESCRIPTION="System and service manager for Linux" +HOMEPAGE="https://www.freedesktop.org/wiki/Software/systemd" + +LICENSE="GPL-2 LGPL-2.1 MIT public-domain" +SLOT="0/2" +IUSE="acl apparmor audit build cgroup-hybrid cryptsetup curl dns-over-tls elfutils +gcrypt gnuefi homed http idn importd +kmod +lz4 lzma nat pam pcre pkcs11 policykit pwquality qrcode repart +resolvconf +seccomp selinux split-usr static-libs +sysv-utils test vanilla xkb" + +REQUIRED_USE=" + homed? ( cryptsetup ) + importd? ( curl gcrypt lzma ) +" +RESTRICT="!test? ( test )" + +MINKV="3.11" + +OPENSSL_DEP=">=dev-libs/openssl-1.1.0:0=" + +COMMON_DEPEND=">=sys-apps/util-linux-2.30:0=[${MULTILIB_USEDEP}] + sys-libs/libcap:0=[${MULTILIB_USEDEP}] + acl? ( sys-apps/acl:0= ) + apparmor? ( sys-libs/libapparmor:0= ) + audit? ( >=sys-process/audit-2:0= ) + cryptsetup? ( >=sys-fs/cryptsetup-2.0.1:0= ) + curl? ( net-misc/curl:0= ) + dns-over-tls? ( >=net-libs/gnutls-3.6.0:0= ) + elfutils? ( >=dev-libs/elfutils-0.158:0= ) + gcrypt? ( >=dev-libs/libgcrypt-1.4.5:0=[${MULTILIB_USEDEP}] ) + homed? ( ${OPENSSL_DEP} ) + http? ( + >=net-libs/libmicrohttpd-0.9.33:0=[epoll(+)] + >=net-libs/gnutls-3.1.4:0= + ) + idn? ( net-dns/libidn2:= ) + importd? ( + app-arch/bzip2:0= + sys-libs/zlib:0= + ) + kmod? ( >=sys-apps/kmod-15:0= ) + lz4? ( >=app-arch/lz4-0_p131:0=[${MULTILIB_USEDEP}] ) + lzma? ( >=app-arch/xz-utils-5.0.5-r1:0=[${MULTILIB_USEDEP}] ) + nat? ( net-firewall/iptables:0= ) + pam? ( sys-libs/pam:=[${MULTILIB_USEDEP}] ) + pkcs11? ( app-crypt/p11-kit:0= ) + pcre? ( dev-libs/libpcre2 ) + pwquality? ( dev-libs/libpwquality:0= ) + qrcode? ( media-gfx/qrencode:0= ) + repart? ( ${OPENSSL_DEP} ) + seccomp? ( >=sys-libs/libseccomp-2.3.3:0= ) + selinux? ( sys-libs/libselinux:0= ) + xkb? ( >=x11-libs/libxkbcommon-0.4.1:0= )" + +# Newer linux-headers needed by ia64, bug #480218 +DEPEND="${COMMON_DEPEND} + >=sys-kernel/linux-headers-${MINKV} + gnuefi? ( >=sys-boot/gnu-efi-3.0.2 ) +" + +# baselayout-2.2 has /run +RDEPEND="${COMMON_DEPEND} + acct-group/adm + acct-group/wheel + acct-group/kmem + acct-group/tty + acct-group/utmp + acct-group/audio + acct-group/cdrom + acct-group/dialout + acct-group/disk + acct-group/input + acct-group/kvm + acct-group/render + acct-group/tape + acct-group/video + acct-group/systemd-journal + acct-user/systemd-journal-remote + acct-user/systemd-coredump + acct-user/systemd-network + acct-user/systemd-resolve + acct-user/systemd-timesync + >=sys-apps/baselayout-2.2 + selinux? ( sec-policy/selinux-base-policy[systemd] ) + sysv-utils? ( !sys-apps/sysvinit ) + !sysv-utils? ( sys-apps/sysvinit ) + resolvconf? ( !net-dns/openresolv ) + !build? ( || ( + sys-apps/util-linux[kill(-)] + sys-process/procps[kill(+)] + sys-apps/coreutils[kill(-)] + ) ) + !sys-auth/nss-myhostname + !sys-fs/eudev + !sys-fs/udev +" + +# sys-apps/dbus: the daemon only (+ build-time lib dep for tests) +PDEPEND=">=sys-apps/dbus-1.9.8[systemd] + >=sys-apps/hwids-20150417[udev] + >=sys-fs/udev-init-scripts-25 + policykit? ( sys-auth/polkit ) + !vanilla? ( sys-apps/gentoo-systemd-integration )" + +BDEPEND=" + app-arch/xz-utils:0 + dev-util/gperf + >=dev-util/meson-0.46 + >=dev-util/intltool-0.50 + >=sys-apps/coreutils-8.16 + sys-devel/m4 + virtual/pkgconfig[${MULTILIB_USEDEP}] + test? ( sys-apps/dbus ) + app-text/docbook-xml-dtd:4.2 + app-text/docbook-xml-dtd:4.5 + app-text/docbook-xsl-stylesheets + dev-libs/libxslt:0 + $(python_gen_any_dep 'dev-python/lxml[${PYTHON_USEDEP}]') +" + +python_check_deps() { + has_version -b "dev-python/lxml[${PYTHON_USEDEP}]" +} + +pkg_pretend() { + if [[ ${MERGE_TYPE} != buildonly ]]; then + if use test && has pid-sandbox ${FEATURES}; then + ewarn "Tests are known to fail with PID sandboxing enabled." + ewarn "See https://bugs.gentoo.org/674458." + fi + + local CONFIG_CHECK="~AUTOFS4_FS ~BLK_DEV_BSG ~CGROUPS + ~CHECKPOINT_RESTORE ~DEVTMPFS ~EPOLL ~FANOTIFY ~FHANDLE + ~INOTIFY_USER ~IPV6 ~NET ~NET_NS ~PROC_FS ~SIGNALFD ~SYSFS + ~TIMERFD ~TMPFS_XATTR ~UNIX + ~CRYPTO_HMAC ~CRYPTO_SHA256 ~CRYPTO_USER_API_HASH + ~!GRKERNSEC_PROC ~!IDE ~!SYSFS_DEPRECATED + ~!SYSFS_DEPRECATED_V2" + + use acl && CONFIG_CHECK+=" ~TMPFS_POSIX_ACL" + use seccomp && CONFIG_CHECK+=" ~SECCOMP ~SECCOMP_FILTER" + kernel_is -lt 3 7 && CONFIG_CHECK+=" ~HOTPLUG" + kernel_is -lt 4 7 && CONFIG_CHECK+=" ~DEVPTS_MULTIPLE_INSTANCES" + kernel_is -ge 4 10 && CONFIG_CHECK+=" ~CGROUP_BPF" + + if linux_config_exists; then + local uevent_helper_path=$(linux_chkconfig_string UEVENT_HELPER_PATH) + if [[ -n ${uevent_helper_path} ]] && [[ ${uevent_helper_path} != '""' ]]; then + ewarn "It's recommended to set an empty value to the following kernel config option:" + ewarn "CONFIG_UEVENT_HELPER_PATH=${uevent_helper_path}" + fi + if linux_chkconfig_present X86; then + CONFIG_CHECK+=" ~DMIID" + fi + fi + + if kernel_is -lt ${MINKV//./ }; then + ewarn "Kernel version at least ${MINKV} required" + fi + + check_extra_config + fi +} + +pkg_setup() { + : +} + +src_unpack() { + default + [[ ${PV} != 9999 ]] || git-r3_src_unpack +} + +src_prepare() { + # Do NOT add patches here + local PATCHES=() + + [[ -d "${WORKDIR}"/patches ]] && PATCHES+=( "${WORKDIR}"/patches ) + + # Add local patches here + PATCHES+=( + "${FILESDIR}/245-clang-gnu11.patch" + ) + + if ! use vanilla; then + PATCHES+=( + "${FILESDIR}/gentoo-Dont-enable-audit-by-default.patch" + "${FILESDIR}/gentoo-systemd-user-pam.patch" + "${FILESDIR}/gentoo-generator-path-r1.patch" + ) + fi + + default +} + +src_configure() { + # Prevent conflicts with i686 cross toolchain, bug 559726 + tc-export AR CC NM OBJCOPY RANLIB + + python_setup + + multilib-minimal_src_configure +} + +meson_use() { + usex "$1" true false +} + +meson_multilib() { + if multilib_is_native_abi; then + echo true + else + echo false + fi +} + +meson_multilib_native_use() { + if multilib_is_native_abi && use "$1"; then + echo true + else + echo false + fi +} + +multilib_src_configure() { + local myconf=( + --localstatedir="${EPREFIX}/var" + -Dsupport-url="https://gentoo.org/support/" + -Dpamlibdir="$(getpam_mod_dir)" + # avoid bash-completion dep + -Dbashcompletiondir="$(get_bashcompdir)" + # make sure we get /bin:/sbin in PATH + -Dsplit-usr=$(usex split-usr true false) + -Dsplit-bin=true + -Drootprefix="$(usex split-usr "${EPREFIX:-/}" "${EPREFIX}/usr")" + -Drootlibdir="${EPREFIX}/usr/$(get_libdir)" + -Dsysvinit-path= + -Dsysvrcnd-path= + # Avoid infinite exec recursion, bug 642724 + -Dtelinit-path="${EPREFIX}/lib/sysvinit/telinit" + # no deps + -Dima=true + -Ddefault-hierarchy=$(usex cgroup-hybrid hybrid unified) + # Optional components/dependencies + -Dacl=$(meson_multilib_native_use acl) + -Dapparmor=$(meson_multilib_native_use apparmor) + -Daudit=$(meson_multilib_native_use audit) + -Dlibcryptsetup=$(meson_multilib_native_use cryptsetup) + -Dlibcurl=$(meson_multilib_native_use curl) + -Ddns-over-tls=$(meson_multilib_native_use dns-over-tls) + -Delfutils=$(meson_multilib_native_use elfutils) + -Dgcrypt=$(meson_use gcrypt) + -Dgnu-efi=$(meson_multilib_native_use gnuefi) + -Defi-libdir="${ESYSROOT}/usr/$(get_libdir)" + -Dhomed=$(meson_multilib_native_use homed) + -Dmicrohttpd=$(meson_multilib_native_use http) + -Didn=$(meson_multilib_native_use idn) + -Dimportd=$(meson_multilib_native_use importd) + -Dbzip2=$(meson_multilib_native_use importd) + -Dzlib=$(meson_multilib_native_use importd) + -Dkmod=$(meson_multilib_native_use kmod) + -Dlz4=$(meson_use lz4) + -Dxz=$(meson_use lzma) + -Dlibiptc=$(meson_multilib_native_use nat) + -Dpam=$(meson_use pam) + -Dp11kit=$(meson_multilib_native_use pkcs11) + -Dpcre2=$(meson_multilib_native_use pcre) + -Dpolkit=$(meson_multilib_native_use policykit) + -Dpwquality=$(meson_multilib_native_use pwquality) + -Dqrencode=$(meson_multilib_native_use qrcode) + -Drepart=$(meson_multilib_native_use repart) + -Dseccomp=$(meson_multilib_native_use seccomp) + -Dselinux=$(meson_multilib_native_use selinux) + -Ddbus=$(meson_multilib_native_use test) + -Dxkbcommon=$(meson_multilib_native_use xkb) + -Dntp-servers="0.gentoo.pool.ntp.org 1.gentoo.pool.ntp.org 2.gentoo.pool.ntp.org 3.gentoo.pool.ntp.org" + # Breaks screen, tmux, etc. + -Ddefault-kill-user-processes=false + -Dcreate-log-dirs=false + + # multilib options + -Dbacklight=$(meson_multilib) + -Dbinfmt=$(meson_multilib) + -Dcoredump=$(meson_multilib) + -Denvironment-d=$(meson_multilib) + -Dfirstboot=$(meson_multilib) + -Dhibernate=$(meson_multilib) + -Dhostnamed=$(meson_multilib) + -Dhwdb=$(meson_multilib) + -Dldconfig=$(meson_multilib) + -Dlocaled=$(meson_multilib) + -Dman=$(meson_multilib) + -Dnetworkd=$(meson_multilib) + -Dquotacheck=$(meson_multilib) + -Drandomseed=$(meson_multilib) + -Drfkill=$(meson_multilib) + -Dsysusers=$(meson_multilib) + -Dtimedated=$(meson_multilib) + -Dtimesyncd=$(meson_multilib) + -Dtmpfiles=$(meson_multilib) + -Dvconsole=$(meson_multilib) + + # static-libs + -Dstatic-libsystemd=$(usex static-libs true false) + -Dstatic-libudev=$(usex static-libs true false) + ) + + meson_src_configure "${myconf[@]}" +} + +multilib_src_compile() { + eninja +} + +multilib_src_test() { + unset DBUS_SESSION_BUS_ADDRESS XDG_RUNTIME_DIR + meson_src_test +} + +multilib_src_install() { + DESTDIR="${D}" eninja install +} + +multilib_src_install_all() { + local rootprefix=$(usex split-usr '' /usr) + + # meson doesn't know about docdir + mv "${ED}"/usr/share/doc/{systemd,${PF}} || die + + einstalldocs + dodoc "${FILESDIR}"/nsswitch.conf + + if ! use resolvconf; then + rm -f "${ED}${rootprefix}"/sbin/resolvconf || die + fi + + if ! use sysv-utils; then + rm "${ED}${rootprefix}"/sbin/{halt,init,poweroff,reboot,runlevel,shutdown,telinit} || die + rm "${ED}"/usr/share/man/man1/init.1 || die + rm "${ED}"/usr/share/man/man8/{halt,poweroff,reboot,runlevel,shutdown,telinit}.8 || die + fi + + if ! use resolvconf && ! use sysv-utils; then + rmdir "${ED}${rootprefix}"/sbin || die + fi + + # Preserve empty dirs in /etc & /var, bug #437008 + keepdir /etc/{binfmt.d,modules-load.d,tmpfiles.d} + keepdir /etc/kernel/install.d + keepdir /etc/systemd/{network,system,user} + keepdir /etc/udev/{hwdb.d,rules.d} + keepdir "${rootprefix}"/lib/systemd/{system-sleep,system-shutdown} + keepdir /usr/lib/{binfmt.d,modules-load.d} + keepdir /usr/lib/systemd/user-generators + keepdir /var/lib/systemd + keepdir /var/log/journal + + # Symlink /etc/sysctl.conf for easy migration. + dosym ../sysctl.conf /etc/sysctl.d/99-sysctl.conf + + rm -r "${ED}${rootprefix}"/lib/udev/hwdb.d || die + + if use split-usr; then + # Avoid breaking boot/reboot + dosym ../../../lib/systemd/systemd /usr/lib/systemd/systemd + dosym ../../../lib/systemd/systemd-shutdown /usr/lib/systemd/systemd-shutdown + fi + + gen_usr_ldscript -a systemd udev +} + +migrate_locale() { + local envd_locale_def="${EROOT}/etc/env.d/02locale" + local envd_locale=( "${EROOT}"/etc/env.d/??locale ) + local locale_conf="${EROOT}/etc/locale.conf" + + if [[ ! -L ${locale_conf} && ! -e ${locale_conf} ]]; then + # If locale.conf does not exist... + if [[ -e ${envd_locale} ]]; then + # ...either copy env.d/??locale if there's one + ebegin "Moving ${envd_locale} to ${locale_conf}" + mv "${envd_locale}" "${locale_conf}" + eend ${?} || FAIL=1 + else + # ...or create a dummy default + ebegin "Creating ${locale_conf}" + cat > "${locale_conf}" <<-EOF + # This file has been created by the sys-apps/systemd ebuild. + # See locale.conf(5) and localectl(1). + + # LANG=${LANG} + EOF + eend ${?} || FAIL=1 + fi + fi + + if [[ ! -L ${envd_locale} ]]; then + # now, if env.d/??locale is not a symlink (to locale.conf)... + if [[ -e ${envd_locale} ]]; then + # ...warn the user that he has duplicate locale settings + ewarn + ewarn "To ensure consistent behavior, you should replace ${envd_locale}" + ewarn "with a symlink to ${locale_conf}. Please migrate your settings" + ewarn "and create the symlink with the following command:" + ewarn "ln -s -n -f ../locale.conf ${envd_locale}" + ewarn + else + # ...or just create the symlink if there's nothing here + ebegin "Creating ${envd_locale_def} -> ../locale.conf symlink" + ln -n -s ../locale.conf "${envd_locale_def}" + eend ${?} || FAIL=1 + fi + fi +} + +save_enabled_units() { + ENABLED_UNITS=() + type systemctl &>/dev/null || return + for x; do + if systemctl --quiet --root="${ROOT:-/}" is-enabled "${x}"; then + ENABLED_UNITS+=( "${x}" ) + fi + done +} + +pkg_preinst() { + save_enabled_units {machines,remote-{cryptsetup,fs}}.target getty@tty1.service + + if ! use split-usr; then + local dir + for dir in bin sbin lib; do + if [[ ! ${EROOT}/${dir} -ef ${EROOT}/usr/${dir} ]]; then + eerror "\"${EROOT}/${dir}\" and \"${EROOT}/usr/${dir}\" are not merged." + eerror "One of them should be a symbolic link to the other one." + FAIL=1 + fi + done + if [[ ${FAIL} ]]; then + eerror "Migration to system layout with merged directories must be performed before" + eerror "rebuilding ${CATEGORY}/${PN} with USE=\"-split-usr\" to avoid run-time breakage." + die "System layout with split directories still used" + fi + fi +} + +pkg_postinst() { + systemd_update_catalog + + # Keep this here in case the database format changes so it gets updated + # when required. Despite that this file is owned by sys-apps/hwids. + if has_version "sys-apps/hwids[udev]"; then + udevadm hwdb --update --root="${EROOT}" + fi + + udev_reload || FAIL=1 + + # Bug 465468, make sure locales are respect, and ensure consistency + # between OpenRC & systemd + migrate_locale + + systemd_reenable systemd-networkd.service systemd-resolved.service + + if [[ ${ENABLED_UNITS[@]} ]]; then + systemctl --root="${ROOT:-/}" enable "${ENABLED_UNITS[@]}" + fi + + if [[ -z ${REPLACING_VERSIONS} ]]; then + if type systemctl &>/dev/null; then + systemctl --root="${ROOT:-/}" enable getty@.service remote-fs.target || FAIL=1 + fi + elog "To enable a useful set of services, run the following:" + elog " systemctl preset-all --preset-mode=enable-only" + fi + + if [[ -L ${EROOT}/var/lib/systemd/timesync ]]; then + rm "${EROOT}/var/lib/systemd/timesync" + fi + + if [[ -z ${ROOT} && -d /run/systemd/system ]]; then + ebegin "Reexecuting system manager" + systemctl daemon-reexec + eend $? + fi + + if [[ ${FAIL} ]]; then + eerror "One of the postinst commands failed. Please check the postinst output" + eerror "for errors. You may need to clean up your system and/or try installing" + eerror "systemd again." + eerror + fi +} + +pkg_prerm() { + # If removing systemd completely, remove the catalog database. + if [[ ! ${REPLACED_BY_VERSION} ]]; then + rm -f -v "${EROOT}"/var/lib/systemd/catalog/database + fi +} diff --git a/sys-apps/systemd/systemd-245_rc1-r2.ebuild b/sys-apps/systemd/systemd-245_rc1-r2.ebuild deleted file mode 100644 index 3ab16fd6edd8..000000000000 --- a/sys-apps/systemd/systemd-245_rc1-r2.ebuild +++ /dev/null @@ -1,512 +0,0 @@ -# Copyright 2011-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -if [[ ${PV} == 9999 ]]; then - EGIT_REPO_URI="https://github.com/systemd/systemd.git" - inherit git-r3 -else - if [[ ${PV} == *.* ]]; then - MY_PN=systemd-stable - else - MY_PN=systemd - fi - MY_PV=${PV/_/-} - MY_P=${MY_PN}-${MY_PV} - S=${WORKDIR}/${MY_P} - SRC_URI="https://github.com/systemd/${MY_PN}/archive/v${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86" -fi - -PYTHON_COMPAT=( python3_{6,7,8} ) - -inherit bash-completion-r1 linux-info meson multilib-minimal ninja-utils pam python-any-r1 systemd toolchain-funcs udev usr-ldscript - -DESCRIPTION="System and service manager for Linux" -HOMEPAGE="https://www.freedesktop.org/wiki/Software/systemd" - -LICENSE="GPL-2 LGPL-2.1 MIT public-domain" -SLOT="0/2" -IUSE="acl apparmor audit build cgroup-hybrid cryptsetup curl dns-over-tls elfutils +gcrypt gnuefi http idn importd +kmod +lz4 lzma nat pam pcre pkcs11 policykit pwquality qrcode +resolvconf +seccomp selinux split-usr static-libs +sysv-utils test vanilla xkb" - -REQUIRED_USE="importd? ( curl gcrypt lzma )" -RESTRICT="!test? ( test )" - -MINKV="3.11" - -COMMON_DEPEND=">=sys-apps/util-linux-2.30:0=[${MULTILIB_USEDEP}] - sys-libs/libcap:0=[${MULTILIB_USEDEP}] - acl? ( sys-apps/acl:0= ) - apparmor? ( sys-libs/libapparmor:0= ) - audit? ( >=sys-process/audit-2:0= ) - cryptsetup? ( >=sys-fs/cryptsetup-2.0.1:0= ) - curl? ( net-misc/curl:0= ) - dns-over-tls? ( >=net-libs/gnutls-3.5.3:0= ) - elfutils? ( >=dev-libs/elfutils-0.158:0= ) - gcrypt? ( >=dev-libs/libgcrypt-1.4.5:0=[${MULTILIB_USEDEP}] ) - http? ( - >=net-libs/libmicrohttpd-0.9.33:0=[epoll(+)] - >=net-libs/gnutls-3.1.4:0= - ) - idn? ( net-dns/libidn2:= ) - importd? ( - app-arch/bzip2:0= - sys-libs/zlib:0= - ) - kmod? ( >=sys-apps/kmod-15:0= ) - lz4? ( >=app-arch/lz4-0_p131:0=[${MULTILIB_USEDEP}] ) - lzma? ( >=app-arch/xz-utils-5.0.5-r1:0=[${MULTILIB_USEDEP}] ) - nat? ( net-firewall/iptables:0= ) - pam? ( sys-libs/pam:=[${MULTILIB_USEDEP}] ) - pkcs11? ( app-crypt/p11-kit:0= ) - pcre? ( dev-libs/libpcre2 ) - pwquality? ( dev-libs/libpwquality:0= ) - qrcode? ( media-gfx/qrencode:0= ) - seccomp? ( >=sys-libs/libseccomp-2.3.3:0= ) - selinux? ( sys-libs/libselinux:0= ) - xkb? ( >=x11-libs/libxkbcommon-0.4.1:0= )" - -# Newer linux-headers needed by ia64, bug #480218 -DEPEND="${COMMON_DEPEND} - >=sys-kernel/linux-headers-${MINKV} - gnuefi? ( >=sys-boot/gnu-efi-3.0.2 ) -" - -# baselayout-2.2 has /run -RDEPEND="${COMMON_DEPEND} - acct-group/adm - acct-group/wheel - acct-group/kmem - acct-group/tty - acct-group/utmp - acct-group/audio - acct-group/cdrom - acct-group/dialout - acct-group/disk - acct-group/input - acct-group/kvm - acct-group/render - acct-group/tape - acct-group/video - acct-group/systemd-journal - acct-user/systemd-journal-remote - acct-user/systemd-coredump - acct-user/systemd-network - acct-user/systemd-resolve - acct-user/systemd-timesync - >=sys-apps/baselayout-2.2 - selinux? ( sec-policy/selinux-base-policy[systemd] ) - sysv-utils? ( !sys-apps/sysvinit ) - !sysv-utils? ( sys-apps/sysvinit ) - resolvconf? ( !net-dns/openresolv ) - !build? ( || ( - sys-apps/util-linux[kill(-)] - sys-process/procps[kill(+)] - sys-apps/coreutils[kill(-)] - ) ) - !sys-auth/nss-myhostname - !sys-fs/eudev - !sys-fs/udev -" - -# sys-apps/dbus: the daemon only (+ build-time lib dep for tests) -PDEPEND=">=sys-apps/dbus-1.9.8[systemd] - >=sys-apps/hwids-20150417[udev] - >=sys-fs/udev-init-scripts-25 - policykit? ( sys-auth/polkit ) - !vanilla? ( sys-apps/gentoo-systemd-integration )" - -BDEPEND=" - app-arch/xz-utils:0 - dev-util/gperf - >=dev-util/meson-0.46 - >=dev-util/intltool-0.50 - >=sys-apps/coreutils-8.16 - sys-devel/m4 - virtual/pkgconfig[${MULTILIB_USEDEP}] - test? ( sys-apps/dbus ) - app-text/docbook-xml-dtd:4.2 - app-text/docbook-xml-dtd:4.5 - app-text/docbook-xsl-stylesheets - dev-libs/libxslt:0 - $(python_gen_any_dep 'dev-python/lxml[${PYTHON_USEDEP}]') -" - -python_check_deps() { - has_version -b "dev-python/lxml[${PYTHON_USEDEP}]" -} - -pkg_pretend() { - if [[ ${MERGE_TYPE} != buildonly ]]; then - if use test && has pid-sandbox ${FEATURES}; then - ewarn "Tests are known to fail with PID sandboxing enabled." - ewarn "See https://bugs.gentoo.org/674458." - fi - - local CONFIG_CHECK="~AUTOFS4_FS ~BLK_DEV_BSG ~CGROUPS - ~CHECKPOINT_RESTORE ~DEVTMPFS ~EPOLL ~FANOTIFY ~FHANDLE - ~INOTIFY_USER ~IPV6 ~NET ~NET_NS ~PROC_FS ~SIGNALFD ~SYSFS - ~TIMERFD ~TMPFS_XATTR ~UNIX - ~CRYPTO_HMAC ~CRYPTO_SHA256 ~CRYPTO_USER_API_HASH - ~!GRKERNSEC_PROC ~!IDE ~!SYSFS_DEPRECATED - ~!SYSFS_DEPRECATED_V2" - - use acl && CONFIG_CHECK+=" ~TMPFS_POSIX_ACL" - use seccomp && CONFIG_CHECK+=" ~SECCOMP ~SECCOMP_FILTER" - kernel_is -lt 3 7 && CONFIG_CHECK+=" ~HOTPLUG" - kernel_is -lt 4 7 && CONFIG_CHECK+=" ~DEVPTS_MULTIPLE_INSTANCES" - kernel_is -ge 4 10 && CONFIG_CHECK+=" ~CGROUP_BPF" - - if linux_config_exists; then - local uevent_helper_path=$(linux_chkconfig_string UEVENT_HELPER_PATH) - if [[ -n ${uevent_helper_path} ]] && [[ ${uevent_helper_path} != '""' ]]; then - ewarn "It's recommended to set an empty value to the following kernel config option:" - ewarn "CONFIG_UEVENT_HELPER_PATH=${uevent_helper_path}" - fi - if linux_chkconfig_present X86; then - CONFIG_CHECK+=" ~DMIID" - fi - fi - - if kernel_is -lt ${MINKV//./ }; then - ewarn "Kernel version at least ${MINKV} required" - fi - - check_extra_config - fi -} - -pkg_setup() { - : -} - -src_unpack() { - default - [[ ${PV} != 9999 ]] || git-r3_src_unpack -} - -src_prepare() { - # Do NOT add patches here - local PATCHES=() - - [[ -d "${WORKDIR}"/patches ]] && PATCHES+=( "${WORKDIR}"/patches ) - - # Add local patches here - PATCHES+=( - "${FILESDIR}"/245-rc1-network-debug.patch - "${FILESDIR}"/245-rc1-sysctl-segfault.patch - ) - - if ! use vanilla; then - PATCHES+=( - "${FILESDIR}/gentoo-Dont-enable-audit-by-default.patch" - "${FILESDIR}/gentoo-systemd-user-pam.patch" - "${FILESDIR}/gentoo-generator-path-r1.patch" - ) - fi - - default -} - -src_configure() { - # Prevent conflicts with i686 cross toolchain, bug 559726 - tc-export AR CC NM OBJCOPY RANLIB - - python_setup - - multilib-minimal_src_configure -} - -meson_use() { - usex "$1" true false -} - -meson_multilib() { - if multilib_is_native_abi; then - echo true - else - echo false - fi -} - -meson_multilib_native_use() { - if multilib_is_native_abi && use "$1"; then - echo true - else - echo false - fi -} - -multilib_src_configure() { - local myconf=( - --localstatedir="${EPREFIX}/var" - -Dsupport-url="https://gentoo.org/support/" - -Dpamlibdir="$(getpam_mod_dir)" - # avoid bash-completion dep - -Dbashcompletiondir="$(get_bashcompdir)" - # make sure we get /bin:/sbin in PATH - -Dsplit-usr=$(usex split-usr true false) - -Dsplit-bin=true - -Drootprefix="$(usex split-usr "${EPREFIX:-/}" "${EPREFIX}/usr")" - -Drootlibdir="${EPREFIX}/usr/$(get_libdir)" - -Dsysvinit-path= - -Dsysvrcnd-path= - # Avoid infinite exec recursion, bug 642724 - -Dtelinit-path="${EPREFIX}/lib/sysvinit/telinit" - # no deps - -Dima=true - -Ddefault-hierarchy=$(usex cgroup-hybrid hybrid unified) - # Optional components/dependencies - -Dacl=$(meson_multilib_native_use acl) - -Dapparmor=$(meson_multilib_native_use apparmor) - -Daudit=$(meson_multilib_native_use audit) - -Dlibcryptsetup=$(meson_multilib_native_use cryptsetup) - -Dlibcurl=$(meson_multilib_native_use curl) - -Ddns-over-tls=$(meson_multilib_native_use dns-over-tls) - -Delfutils=$(meson_multilib_native_use elfutils) - -Dgcrypt=$(meson_use gcrypt) - -Dgnu-efi=$(meson_multilib_native_use gnuefi) - -Defi-libdir="${ESYSROOT}/usr/$(get_libdir)" - -Dmicrohttpd=$(meson_multilib_native_use http) - -Didn=$(meson_multilib_native_use idn) - -Dimportd=$(meson_multilib_native_use importd) - -Dbzip2=$(meson_multilib_native_use importd) - -Dzlib=$(meson_multilib_native_use importd) - -Dkmod=$(meson_multilib_native_use kmod) - -Dlz4=$(meson_use lz4) - -Dxz=$(meson_use lzma) - -Dlibiptc=$(meson_multilib_native_use nat) - -Dpam=$(meson_use pam) - -Dp11kit=$(meson_multilib_native_use pkcs11) - -Dpcre2=$(meson_multilib_native_use pcre) - -Dpolkit=$(meson_multilib_native_use policykit) - -Dpwquality=$(meson_multilib_native_use pwquality) - -Dqrencode=$(meson_multilib_native_use qrcode) - -Dseccomp=$(meson_multilib_native_use seccomp) - -Dselinux=$(meson_multilib_native_use selinux) - -Ddbus=$(meson_multilib_native_use test) - -Dxkbcommon=$(meson_multilib_native_use xkb) - -Dntp-servers="0.gentoo.pool.ntp.org 1.gentoo.pool.ntp.org 2.gentoo.pool.ntp.org 3.gentoo.pool.ntp.org" - # Breaks screen, tmux, etc. - -Ddefault-kill-user-processes=false - -Dcreate-log-dirs=false - - # multilib options - -Dbacklight=$(meson_multilib) - -Dbinfmt=$(meson_multilib) - -Dcoredump=$(meson_multilib) - -Denvironment-d=$(meson_multilib) - -Dfirstboot=$(meson_multilib) - -Dhibernate=$(meson_multilib) - -Dhostnamed=$(meson_multilib) - -Dhwdb=$(meson_multilib) - -Dldconfig=$(meson_multilib) - -Dlocaled=$(meson_multilib) - -Dman=$(meson_multilib) - -Dnetworkd=$(meson_multilib) - -Dquotacheck=$(meson_multilib) - -Drandomseed=$(meson_multilib) - -Drfkill=$(meson_multilib) - -Dsysusers=$(meson_multilib) - -Dtimedated=$(meson_multilib) - -Dtimesyncd=$(meson_multilib) - -Dtmpfiles=$(meson_multilib) - -Dvconsole=$(meson_multilib) - - # static-libs - -Dstatic-libsystemd=$(usex static-libs true false) - -Dstatic-libudev=$(usex static-libs true false) - ) - - meson_src_configure "${myconf[@]}" -} - -multilib_src_compile() { - eninja -} - -multilib_src_test() { - unset DBUS_SESSION_BUS_ADDRESS XDG_RUNTIME_DIR - meson_src_test -} - -multilib_src_install() { - DESTDIR="${D}" eninja install -} - -multilib_src_install_all() { - local rootprefix=$(usex split-usr '' /usr) - - # meson doesn't know about docdir - mv "${ED}"/usr/share/doc/{systemd,${PF}} || die - - einstalldocs - dodoc "${FILESDIR}"/nsswitch.conf - - if ! use resolvconf; then - rm -f "${ED}${rootprefix}"/sbin/resolvconf || die - fi - - if ! use sysv-utils; then - rm "${ED}${rootprefix}"/sbin/{halt,init,poweroff,reboot,runlevel,shutdown,telinit} || die - rm "${ED}"/usr/share/man/man1/init.1 || die - rm "${ED}"/usr/share/man/man8/{halt,poweroff,reboot,runlevel,shutdown,telinit}.8 || die - fi - - if ! use resolvconf && ! use sysv-utils; then - rmdir "${ED}${rootprefix}"/sbin || die - fi - - # Preserve empty dirs in /etc & /var, bug #437008 - keepdir /etc/{binfmt.d,modules-load.d,tmpfiles.d} - keepdir /etc/kernel/install.d - keepdir /etc/systemd/{network,system,user} - keepdir /etc/udev/{hwdb.d,rules.d} - keepdir "${rootprefix}"/lib/systemd/{system-sleep,system-shutdown} - keepdir /usr/lib/{binfmt.d,modules-load.d} - keepdir /usr/lib/systemd/user-generators - keepdir /var/lib/systemd - keepdir /var/log/journal - - # Symlink /etc/sysctl.conf for easy migration. - dosym ../sysctl.conf /etc/sysctl.d/99-sysctl.conf - - rm -r "${ED}${rootprefix}"/lib/udev/hwdb.d || die - - if use split-usr; then - # Avoid breaking boot/reboot - dosym ../../../lib/systemd/systemd /usr/lib/systemd/systemd - dosym ../../../lib/systemd/systemd-shutdown /usr/lib/systemd/systemd-shutdown - fi - - gen_usr_ldscript -a systemd udev -} - -migrate_locale() { - local envd_locale_def="${EROOT}/etc/env.d/02locale" - local envd_locale=( "${EROOT}"/etc/env.d/??locale ) - local locale_conf="${EROOT}/etc/locale.conf" - - if [[ ! -L ${locale_conf} && ! -e ${locale_conf} ]]; then - # If locale.conf does not exist... - if [[ -e ${envd_locale} ]]; then - # ...either copy env.d/??locale if there's one - ebegin "Moving ${envd_locale} to ${locale_conf}" - mv "${envd_locale}" "${locale_conf}" - eend ${?} || FAIL=1 - else - # ...or create a dummy default - ebegin "Creating ${locale_conf}" - cat > "${locale_conf}" <<-EOF - # This file has been created by the sys-apps/systemd ebuild. - # See locale.conf(5) and localectl(1). - - # LANG=${LANG} - EOF - eend ${?} || FAIL=1 - fi - fi - - if [[ ! -L ${envd_locale} ]]; then - # now, if env.d/??locale is not a symlink (to locale.conf)... - if [[ -e ${envd_locale} ]]; then - # ...warn the user that he has duplicate locale settings - ewarn - ewarn "To ensure consistent behavior, you should replace ${envd_locale}" - ewarn "with a symlink to ${locale_conf}. Please migrate your settings" - ewarn "and create the symlink with the following command:" - ewarn "ln -s -n -f ../locale.conf ${envd_locale}" - ewarn - else - # ...or just create the symlink if there's nothing here - ebegin "Creating ${envd_locale_def} -> ../locale.conf symlink" - ln -n -s ../locale.conf "${envd_locale_def}" - eend ${?} || FAIL=1 - fi - fi -} - -save_enabled_units() { - ENABLED_UNITS=() - type systemctl &>/dev/null || return - for x; do - if systemctl --quiet --root="${ROOT:-/}" is-enabled "${x}"; then - ENABLED_UNITS+=( "${x}" ) - fi - done -} - -pkg_preinst() { - save_enabled_units {machines,remote-{cryptsetup,fs}}.target getty@tty1.service - - if ! use split-usr; then - local dir - for dir in bin sbin lib; do - if [[ ! ${EROOT}/${dir} -ef ${EROOT}/usr/${dir} ]]; then - eerror "\"${EROOT}/${dir}\" and \"${EROOT}/usr/${dir}\" are not merged." - eerror "One of them should be a symbolic link to the other one." - FAIL=1 - fi - done - if [[ ${FAIL} ]]; then - eerror "Migration to system layout with merged directories must be performed before" - eerror "rebuilding ${CATEGORY}/${PN} with USE=\"-split-usr\" to avoid run-time breakage." - die "System layout with split directories still used" - fi - fi -} - -pkg_postinst() { - systemd_update_catalog - - # Keep this here in case the database format changes so it gets updated - # when required. Despite that this file is owned by sys-apps/hwids. - if has_version "sys-apps/hwids[udev]"; then - udevadm hwdb --update --root="${EROOT}" - fi - - udev_reload || FAIL=1 - - # Bug 465468, make sure locales are respect, and ensure consistency - # between OpenRC & systemd - migrate_locale - - systemd_reenable systemd-networkd.service systemd-resolved.service - - if [[ ${ENABLED_UNITS[@]} ]]; then - systemctl --root="${ROOT:-/}" enable "${ENABLED_UNITS[@]}" - fi - - if [[ -z ${REPLACING_VERSIONS} ]]; then - if type systemctl &>/dev/null; then - systemctl --root="${ROOT:-/}" enable getty@.service remote-fs.target || FAIL=1 - fi - elog "To enable a useful set of services, run the following:" - elog " systemctl preset-all --preset-mode=enable-only" - fi - - if [[ -L ${EROOT}/var/lib/systemd/timesync ]]; then - rm "${EROOT}/var/lib/systemd/timesync" - fi - - if [[ -z ${ROOT} && -d /run/systemd/system ]]; then - ebegin "Reexecuting system manager" - systemctl daemon-reexec - eend $? - fi - - if [[ ${FAIL} ]]; then - eerror "One of the postinst commands failed. Please check the postinst output" - eerror "for errors. You may need to clean up your system and/or try installing" - eerror "systemd again." - eerror - fi -} - -pkg_prerm() { - # If removing systemd completely, remove the catalog database. - if [[ ! ${REPLACED_BY_VERSION} ]]; then - rm -f -v "${EROOT}"/var/lib/systemd/catalog/database - fi -} diff --git a/sys-apps/systemd/systemd-9999.ebuild b/sys-apps/systemd/systemd-9999.ebuild index 6454de6e1695..c35e623d94d7 100644 --- a/sys-apps/systemd/systemd-9999.ebuild +++ b/sys-apps/systemd/systemd-9999.ebuild @@ -28,13 +28,18 @@ HOMEPAGE="https://www.freedesktop.org/wiki/Software/systemd" LICENSE="GPL-2 LGPL-2.1 MIT public-domain" SLOT="0/2" -IUSE="acl apparmor audit build cgroup-hybrid cryptsetup curl dns-over-tls elfutils +gcrypt gnuefi http idn importd +kmod +lz4 lzma nat pam pcre pkcs11 policykit pwquality qrcode +resolvconf +seccomp selinux split-usr static-libs +sysv-utils test vanilla xkb" +IUSE="acl apparmor audit build cgroup-hybrid cryptsetup curl dns-over-tls elfutils +gcrypt gnuefi homed http idn importd +kmod +lz4 lzma nat pam pcre pkcs11 policykit pwquality qrcode repart +resolvconf +seccomp selinux split-usr static-libs +sysv-utils test vanilla xkb" -REQUIRED_USE="importd? ( curl gcrypt lzma )" +REQUIRED_USE=" + homed? ( cryptsetup ) + importd? ( curl gcrypt lzma ) +" RESTRICT="!test? ( test )" MINKV="3.11" +OPENSSL_DEP=">=dev-libs/openssl-1.1.0:0=" + COMMON_DEPEND=">=sys-apps/util-linux-2.30:0=[${MULTILIB_USEDEP}] sys-libs/libcap:0=[${MULTILIB_USEDEP}] acl? ( sys-apps/acl:0= ) @@ -42,9 +47,10 @@ COMMON_DEPEND=">=sys-apps/util-linux-2.30:0=[${MULTILIB_USEDEP}] audit? ( >=sys-process/audit-2:0= ) cryptsetup? ( >=sys-fs/cryptsetup-2.0.1:0= ) curl? ( net-misc/curl:0= ) - dns-over-tls? ( >=net-libs/gnutls-3.5.3:0= ) + dns-over-tls? ( >=net-libs/gnutls-3.6.0:0= ) elfutils? ( >=dev-libs/elfutils-0.158:0= ) gcrypt? ( >=dev-libs/libgcrypt-1.4.5:0=[${MULTILIB_USEDEP}] ) + homed? ( ${OPENSSL_DEP} ) http? ( >=net-libs/libmicrohttpd-0.9.33:0=[epoll(+)] >=net-libs/gnutls-3.1.4:0= @@ -63,6 +69,7 @@ COMMON_DEPEND=">=sys-apps/util-linux-2.30:0=[${MULTILIB_USEDEP}] pcre? ( dev-libs/libpcre2 ) pwquality? ( dev-libs/libpwquality:0= ) qrcode? ( media-gfx/qrencode:0= ) + repart? ( ${OPENSSL_DEP} ) seccomp? ( >=sys-libs/libseccomp-2.3.3:0= ) selinux? ( sys-libs/libselinux:0= ) xkb? ( >=x11-libs/libxkbcommon-0.4.1:0= )" @@ -266,6 +273,7 @@ multilib_src_configure() { -Dgcrypt=$(meson_use gcrypt) -Dgnu-efi=$(meson_multilib_native_use gnuefi) -Defi-libdir="${ESYSROOT}/usr/$(get_libdir)" + -Dhomed=$(meson_multilib_native_use homed) -Dmicrohttpd=$(meson_multilib_native_use http) -Didn=$(meson_multilib_native_use idn) -Dimportd=$(meson_multilib_native_use importd) @@ -281,6 +289,7 @@ multilib_src_configure() { -Dpolkit=$(meson_multilib_native_use policykit) -Dpwquality=$(meson_multilib_native_use pwquality) -Dqrencode=$(meson_multilib_native_use qrcode) + -Drepart=$(meson_multilib_native_use repart) -Dseccomp=$(meson_multilib_native_use seccomp) -Dselinux=$(meson_multilib_native_use selinux) -Ddbus=$(meson_multilib_native_use test) -- cgit v1.2.3