summaryrefslogtreecommitdiff
path: root/sys-apps/util-linux
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-04-28 20:21:43 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-04-28 20:21:43 +0100
commit40aaaa64e86ba6710bbeb31c4615a6ce80e75e11 (patch)
tree758c221bad35c9288d0bd6df9c7dfc226728e52c /sys-apps/util-linux
parent8d5dbd847cbc704a6a06405856e94b461011afe3 (diff)
gentoo resync : 28.04.2021
Diffstat (limited to 'sys-apps/util-linux')
-rw-r--r--sys-apps/util-linux/Manifest18
-rw-r--r--sys-apps/util-linux/files/util-linux-2.33.1-fix-struct_termios-check.patch30
-rw-r--r--sys-apps/util-linux/files/util-linux-2.36.1-libmount_dont_use_symfollow.patch40
-rw-r--r--sys-apps/util-linux/files/util-linux-2.36.1-riscv32.patch29
-rw-r--r--sys-apps/util-linux/util-linux-2.33.2.ebuild290
-rw-r--r--sys-apps/util-linux/util-linux-2.34-r3.ebuild301
-rw-r--r--sys-apps/util-linux/util-linux-2.35.2.ebuild12
-rw-r--r--sys-apps/util-linux/util-linux-2.36.2.ebuild10
-rw-r--r--sys-apps/util-linux/util-linux-2.37_rc1.ebuild (renamed from sys-apps/util-linux/util-linux-2.36.1-r1.ebuild)84
-rw-r--r--sys-apps/util-linux/util-linux-9999.ebuild81
10 files changed, 145 insertions, 750 deletions
diff --git a/sys-apps/util-linux/Manifest b/sys-apps/util-linux/Manifest
index a0b7ab3db6b3..884b62da4f2d 100644
--- a/sys-apps/util-linux/Manifest
+++ b/sys-apps/util-linux/Manifest
@@ -1,18 +1,12 @@
AUX runuser-l.pamd 188 BLAKE2B 4fbd934c05386732b32281fdfac19153f01e0610868f3168026fbc4eb828ed1fe177677939958322fb074a95c8f64bdbaea42a4e9c039ac86dee0154ac96242e SHA512 86538adbd3d01c4b9e46fee00c38d298d2857fb1224461206425532404c212f03331308b74347c9af2e00583a3b50802085bdc6cb2bd393cf5e9d032e7290301
AUX runuser.pamd 278 BLAKE2B 61afa98e02a4ee030176dad97b7aa7d7075b07584c0e9f2c254f90bf22f6bad7ad8d87cb6d7c95efb789dcbec01e266c3192e135a3a36d817ab47c6bc05e7a01 SHA512 a4c4d41078acdc7c7f1d1f1894d20d052d3d5a3c66d5680d7f76665e251c614fd76ca9678a27ea376147f49250c716a1b3b0c0afa9595bd74d26d2190d1680fd
-AUX util-linux-2.33.1-fix-struct_termios-check.patch 1128 BLAKE2B 93d3722c44889d61596f125045a633865d088b8b9f2c1bfc828b90d1700dd2095e7c0a3220e40e6bef3db5f87fd828a018f9db9b774202f23722f460dce3a45a SHA512 eefdce290ec4a025e259d71a42fedb949e725ade512417800f043203418ccb9404673758a406a9ce5a144a5db8ee953122a4d0893f6d511e4f30a94482a20a6a
AUX util-linux-2.35.1-cleanup-pidfd-include.patch 1117 BLAKE2B a207824f36b2167f721b4420b5de47462cdc3f12187316ee0ba37bebd1561aee0c591a522cb9cf7f24986322e1954f1fab1e6fe1751dfebc116aec12f70cc81e SHA512 315b5aabad68d3363f1a06034c22347d755ead4b974fd7879ce41b29953b41be510705a4806577710bb8e9d32a8034002f6868fea287a214640c80324754ea00
-AUX util-linux-2.36.1-libmount_dont_use_symfollow.patch 1576 BLAKE2B 9248b3a7646881c6cf3b4d53f1e28cf19d4f1444a881310c6569fb87063b5458063b53083872fe316318cd2ad4fd2164792fdfdc506e7371bb8b424f62b79f56 SHA512 fd310fdb8547b86dafd84564b3fb68167c02f25defc9cea1a5b2afc9af9e82f0b108a900b5073dd7394815d4c5bc894ebebe989b2c9a30ebecea7afc4083669f
-AUX util-linux-2.36.1-riscv32.patch 870 BLAKE2B 2e1c23ff3ed47bb3cffef4c3fe049e84d35dc63c6be56bc56f21e14fa9801652cd1b2dde65379251fc265f4da5a4a55eb0ef29548fa4f7543bb5034327c0abbd SHA512 0f7924e98fab102172bedd76cf3a7d7afae1c22a3a9605fd78a4a8d05fb78409cb67592f092f4b720738f1e511a7e0d303eeec0137942be6de7196565a09c677
-DIST util-linux-2.33.2.tar.xz 4707024 BLAKE2B fdeed0a236edd26d268bccca8cde2cf1b7ecbff521ede9fa26ea22c8e5cdfc380a416a168789504b303f1b569d163e41f6630ee28829be7f2b2129fa14c4fffa SHA512 ac88790a0272366b384b54df19cb28318014d98819d5d96aa05528ff17ab57a8c66d012a2f1b59caca4c5d4ea669e8c041e1123517c1f1c2d9960ef701aaf749
-DIST util-linux-2.34.tar.xz 4974812 BLAKE2B d26b2f74d490eaee0a40d4c75a1a351ba165b4a52f9bbf6cf9d1afd7ae1382a3a3dfe41180584e97e9aaad6950f604cad928f30747590e3e1e669c8797689758 SHA512 2d0b76f63d32e7afb7acf61a83fabbfd58baa34ab78b3a331ce87f9c676a5fd71c56a493ded95039540d2c46b6048caaa38d7fb4491eb3d52d7b09dc54655cd7
DIST util-linux-2.35.2.tar.xz 5150488 BLAKE2B 93eb90ab33db7795b46425ec4ec87f8a2d3d6e0dad671345375ea02efd654bf72041932d30b41bea494e4b62952e2fd14ea9f9e6c738d4eb4b050bd170b9bb0e SHA512 59e038ba71aa74c9af6f927b357483a965f675ab3ffcd25cf0c1b043656312d2d2d07c55659fd3da69ede165bec313e0ae7e1cd73758e49681ae610604b399a2
-DIST util-linux-2.36.1.tar.xz 5231880 BLAKE2B 52d867aa0b722a84828c37958d80b0bdcc1ceaae4e46fa6550ad0f2f152c52e4aaf2c8bc5fdf4f27b522037a870ff2554382abac0eaa50a6791d8b8016e3d74c SHA512 9dfd01ae4c16fa35015dafd222d555988b72e4d1d2fbadd140791b9ef78f84fa8254d4d08dc67cabf41e873338867f19e786b989d708ccfe5161c4f7679bba7a
DIST util-linux-2.36.2.tar.xz 5348032 BLAKE2B 17e49515f8d0430f3ed26b80bf1d6e811d847141020d0dae1340dc92887549b7b711f3db6e3913120871fc912435def73586a7aef09d8d9cc6ff7ca331b2770f SHA512 6ab141f44ca4cb6b600081f10eae17e15d23abd122a37eb3ac6c845513a6a4396dc9dcff30b3032de80116ddde50e27dfbc86f92708c1051f84f0c919194664b
-EBUILD util-linux-2.33.2.ebuild 8413 BLAKE2B 91cf11ece3866ee440ab658a0b11891b558fe3cd2c896ab294ecca69d6697ee587d64d16749ca383698ecc422cede27f5474535377e191d777cfa813ccaa0409 SHA512 cc5c0ebddc2e496211ccbd22fd7ff3bc88451de55fc4c0884b700107260fa2867eb17a43a29560f46ce79f12e8c740b041d1806733250804eb2c41b34de40795
-EBUILD util-linux-2.34-r3.ebuild 8446 BLAKE2B a52fb003aaf00e7c9bd49014955c7faffef9f46b1b720a1dc74617699f6717ab2f5d33e9b3f55cad0382704b31ad09a8453723fefe9cc3fa0bbd80448c620db0 SHA512 10344c02f3e30fe2c4441de2ccfd5702cb6395cefff850c3a4fc9625ce06f68ce5ead7834cd6c9994fc2f3000d9c15fa63761216aa61b853fc2ce6efddfc996c
-EBUILD util-linux-2.35.2.ebuild 8890 BLAKE2B 1e8607c649882ed1c9d93f1e15c1bbc54d190f61703a084e97208bc887bc6fc31a0718a324c4e7b33dcdb53fe459ec9632509525084a9fcd2373077880c60151 SHA512 065e3989eabc4d56b6345c38a707cd3af787e5ab92924b96d917f3db8a5a249628725820c733dc86b1ec19cc8fae1a657599e7df0c6189014c81b25578a89d0b
-EBUILD util-linux-2.36.1-r1.ebuild 8936 BLAKE2B b2437c366ed36a232aacf10b6ad5e5a84f0e067f88db4840cd89df78e176410927e0f0aa8e624e6f8e8e76a8bcfbccb928ce41d308b7c4a5644016cbcbbe2402 SHA512 d6145c9114c806f57654dc2a5886cc99223713a3fc7299fb742f7d749196ca757ef389856dac89a9afde0949297a1871d0a52aec98800a474190fb07cce7226a
-EBUILD util-linux-2.36.2.ebuild 8827 BLAKE2B 7224a61ddb2ba83e3b127be0d48c1a26c9588ceebb2610e8ac8a34bd1a7fe945bd6afefd111e9755dcfe1d9b6174c869fc679c13b6c4bb204a6e763d8cfe3bcc SHA512 d32e9ac794a46fe4dcc3e37f405596bb2b4e46a8529396ea926162d4f26d2cef584ffbeb45754465803417dd9d3983644e15ae74d843d5645b9f903273cce8c7
-EBUILD util-linux-9999.ebuild 8762 BLAKE2B 6a64f715d5dbd5b9f57186d2790cd11a78fb2269d89cb65d17db522d09af3e5395c6a5af728287589858018d98564c78ebb44cc14efd8581ab4d8eb5adaf1a70 SHA512 6cf6b4993db8dda2d80c32185ce4b40be86d227a53c78062058e3e0449c0f8ae67ae36fcd21b5861a0c43bf8a169b2ea3f8c9f4897a4bd8b0ec99b3e34b28744
+DIST util-linux-2.37-rc1-manpages.tar.xz 160524 BLAKE2B 3d301478b772f944c7d4cd713130fe9800cc32fb14ac46967c6a64fdca6e561d91f642f839c77cded6f4af8b4487cf3f36ac3f6a72aea50a75c020a1c9862ee0 SHA512 44f45356c2a97f482dc4b0a762e4c2e04fbce0d2268cd765fcff87c40554d0ef3016ff5e1c1165ba93c05ff8390d76ea14fd30f419ce4c86fc5678858cede54b
+DIST util-linux-2.37-rc1.tar.xz 5269776 BLAKE2B cc964e8f1bb50f704d7f207bd166b41d6b70d138b52e140687fe58f77626097d6151ae3f3efdb655b8495a67ad33cdf7fcdb0cf71839ba34963b0f14aace98a5 SHA512 5c3125a0ac42e17c8837f398cc3d59a538f18e823fab4feb9d7756a4c7523dd70fe7a5c94baab2a329d1ce99d85bdb19a14dd5d32d72d479a398f7dbc3003c1a
+EBUILD util-linux-2.35.2.ebuild 9014 BLAKE2B 549633172e6d1dfc1f1c993c2d095ddcae525a40964705263c0694ba4ce91ba1817b9b99d1a34d9bc2f08b3cc8075cd45a5eaea5db2ac3f7f9846e9585399f6b SHA512 19c24c1d5f60a3948614fc588df718de8208e08bd386a6d780921355ce906d41e32b62cf5bc669e032557958bd02357c75491a03abb8d0b0aa4c9c828d284d53
+EBUILD util-linux-2.36.2.ebuild 8942 BLAKE2B e26af16681c038a8d2818bfef7565b106711639e0fee55868a056496180648c6ae390e66595af22c1ac4c444052355ccd1a46ef359624b56ee1f8b3205ac2584 SHA512 4f9165ea6a2397b0b9df2971a8547d03005a3e1333673245b4d9397f2b78632cbab23bc12ccd4392ad6b90f1971fca764240730fd315eb22bfcb495937e5dc44
+EBUILD util-linux-2.37_rc1.ebuild 9754 BLAKE2B 3a0bd9c913eb52b123ab4e4cae17d5003948758a08615448f8450c0833844b0d2aa867f6c040850fa1f31dc91b6ba39f6ba87c47df1eab2f882380cb7be28ff3 SHA512 445c8b441aa14763ca3296c73ae6ad6896df54a4e6ffe6feeb754fb22574dc18ec3f7af1df66ec61612f38b501dcf7f7411e6a0a75a7afba8c1170152dc8498f
+EBUILD util-linux-9999.ebuild 9754 BLAKE2B 3a0bd9c913eb52b123ab4e4cae17d5003948758a08615448f8450c0833844b0d2aa867f6c040850fa1f31dc91b6ba39f6ba87c47df1eab2f882380cb7be28ff3 SHA512 445c8b441aa14763ca3296c73ae6ad6896df54a4e6ffe6feeb754fb22574dc18ec3f7af1df66ec61612f38b501dcf7f7411e6a0a75a7afba8c1170152dc8498f
MISC metadata.xml 1364 BLAKE2B 0221b836433dfffc122d794272c554b6114862efb7d474e68507fb399e56cf32bc86f0dba0d519782634eb45638d2e15dd25c8147d7209f5a3de536ba7ecf38b SHA512 094e0b577f2322b73ace41db762ea88736650a3f3010fb8a26f649a51efc83d09a66bbdaf7a24b24164264b2dbbf7839be49b21e0a125c95ca39f1c4cd6201e4
diff --git a/sys-apps/util-linux/files/util-linux-2.33.1-fix-struct_termios-check.patch b/sys-apps/util-linux/files/util-linux-2.33.1-fix-struct_termios-check.patch
deleted file mode 100644
index df52af45049b..000000000000
--- a/sys-apps/util-linux/files/util-linux-2.33.1-fix-struct_termios-check.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 963413a1adf6767ab17712097e288e1a346f63a7 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 4 Jan 2019 22:38:25 -0800
-Subject: [PATCH] ldattach: Check for value of _HAVE_STRUCT_TERMIOS_C_ISPEED
-
-in glibc 2.29+ checking for just existence of _HAVE_STRUCT_TERMIOS_C_ISPEED
-won't be enough, the value has to be checked
-
-see
-https://sourceware.org/git/?p=glibc.git;a=commit;h=e5a50db36eaa6e8c6427b3a971563240b633ca85
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sys-utils/ldattach.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/sys-utils/ldattach.c b/sys-utils/ldattach.c
-index d33d68535..fb50711eb 100644
---- a/sys-utils/ldattach.c
-+++ b/sys-utils/ldattach.c
-@@ -242,7 +242,7 @@ static int my_cfsetspeed(struct termios *ts, int speed)
- * -- we have to bypass glibc and set the speed manually (because glibc
- * checks for speed and supports Bxxx bit rates only)...
- */
--#ifdef _HAVE_STRUCT_TERMIOS_C_ISPEED
-+#if _HAVE_STRUCT_TERMIOS_C_ISPEED
- # define BOTHER 0010000 /* non standard rate */
- dbg("using non-standard speeds");
- ts->c_ospeed = ts->c_ispeed = speed;
-
diff --git a/sys-apps/util-linux/files/util-linux-2.36.1-libmount_dont_use_symfollow.patch b/sys-apps/util-linux/files/util-linux-2.36.1-libmount_dont_use_symfollow.patch
deleted file mode 100644
index 7c0b73f49d78..000000000000
--- a/sys-apps/util-linux/files/util-linux-2.36.1-libmount_dont_use_symfollow.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 76bb9b30cfcf54b59591a57a3d2a747e514469b2 Mon Sep 17 00:00:00 2001
-From: Karel Zak <kzak@redhat.com>
-Date: Thu, 19 Nov 2020 09:49:16 +0100
-Subject: [PATCH] libmount: don't use "symfollow" for helpers on user mounts
-
-Addresses: https://github.com/karelzak/util-linux/issues/1193
-Signed-off-by: Karel Zak <kzak@redhat.com>
----
- libmount/src/context_mount.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/libmount/src/context_mount.c b/libmount/src/context_mount.c
-index 8c394c1ff..dd1786176 100644
---- a/libmount/src/context_mount.c
-+++ b/libmount/src/context_mount.c
-@@ -415,6 +415,9 @@ static int generate_helper_optstr(struct libmnt_context *cxt, char **optstr)
- * string, because there is nothing like MS_EXEC (we only have
- * MS_NOEXEC in mount flags and we don't care about the original
- * mount string in libmount for VFS options).
-+ *
-+ * This use-case makes sense for MS_SECURE flags only (see
-+ * mnt_optstr_get_flags() and mnt_context_merge_mflags()).
- */
- if (!(cxt->mountflags & MS_NOEXEC))
- mnt_optstr_append_option(optstr, "exec", NULL);
-@@ -422,11 +425,8 @@ static int generate_helper_optstr(struct libmnt_context *cxt, char **optstr)
- mnt_optstr_append_option(optstr, "suid", NULL);
- if (!(cxt->mountflags & MS_NODEV))
- mnt_optstr_append_option(optstr, "dev", NULL);
-- if (!(cxt->mountflags & MS_NOSYMFOLLOW))
-- mnt_optstr_append_option(optstr, "symfollow", NULL);
- }
-
--
- if (cxt->flags & MNT_FL_SAVED_USER)
- rc = mnt_optstr_set_option(optstr, "user", cxt->orig_user);
- if (rc)
---
-2.29.2
-
diff --git a/sys-apps/util-linux/files/util-linux-2.36.1-riscv32.patch b/sys-apps/util-linux/files/util-linux-2.36.1-riscv32.patch
deleted file mode 100644
index b18a01906ebf..000000000000
--- a/sys-apps/util-linux/files/util-linux-2.36.1-riscv32.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 367972fae13d170675768d63678577cae1890143 Mon Sep 17 00:00:00 2001
-From: Pino Toscano <toscano.pino@tiscali.it>
-Date: Tue, 17 Nov 2020 11:32:45 +0100
-Subject: [PATCH] hwclock: do not assume __NR_settimeofday_time32
-
-Check that __NR_settimeofday_time32 exists before trying to use it as
-syscall number.
-
-Signed-off-by: Pino Toscano <toscano.pino@tiscali.it>
----
- sys-utils/hwclock.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/sys-utils/hwclock.c b/sys-utils/hwclock.c
-index 1f7ef3317..db448687d 100644
---- a/sys-utils/hwclock.c
-+++ b/sys-utils/hwclock.c
-@@ -678,7 +678,7 @@ display_time(struct timeval hwctime)
- #ifndef SYS_settimeofday
- # ifdef __NR_settimeofday
- # define SYS_settimeofday __NR_settimeofday
--# else
-+# elif defined(__NR_settimeofday_time32)
- # define SYS_settimeofday __NR_settimeofday_time32
- # endif
- #endif
---
-2.26.2
-
diff --git a/sys-apps/util-linux/util-linux-2.33.2.ebuild b/sys-apps/util-linux/util-linux-2.33.2.ebuild
deleted file mode 100644
index 84549290f15f..000000000000
--- a/sys-apps/util-linux/util-linux-2.33.2.ebuild
+++ /dev/null
@@ -1,290 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python3_7 )
-
-inherit toolchain-funcs libtool flag-o-matic bash-completion-r1 usr-ldscript \
- pam python-r1 multilib-minimal multiprocessing systemd
-
-MY_PV="${PV/_/-}"
-MY_P="${PN}-${MY_PV}"
-
-if [[ ${PV} == 9999 ]] ; then
- inherit git-r3 autotools
- EGIT_REPO_URI="https://git.kernel.org/pub/scm/utils/util-linux/util-linux.git"
-else
- [[ "${PV}" = *_rc* ]] || \
- KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv s390 sparc x86 ~amd64-linux ~x86-linux"
- SRC_URI="https://www.kernel.org/pub/linux/utils/util-linux/v${PV:0:4}/${MY_P}.tar.xz"
-fi
-
-DESCRIPTION="Various useful Linux utilities"
-HOMEPAGE="https://www.kernel.org/pub/linux/utils/util-linux/ https://github.com/karelzak/util-linux"
-
-LICENSE="GPL-2 LGPL-2.1 BSD-4 MIT public-domain"
-SLOT="0"
-IUSE="build caps +cramfs fdformat kill ncurses nls pam python +readline selinux slang static-libs +suid systemd test tty-helpers udev unicode userland_GNU"
-
-# Most lib deps here are related to programs rather than our libs,
-# so we rarely need to specify ${MULTILIB_USEDEP}.
-RDEPEND="caps? ( sys-libs/libcap-ng )
- cramfs? ( sys-libs/zlib:= )
- ncurses? ( >=sys-libs/ncurses-5.2-r2:0=[unicode?] )
- nls? ( virtual/libintl[${MULTILIB_USEDEP}] )
- pam? ( sys-libs/pam )
- python? ( ${PYTHON_DEPS} )
- readline? ( sys-libs/readline:0= )
- selinux? ( >=sys-libs/libselinux-2.2.2-r4[${MULTILIB_USEDEP}] )
- slang? ( sys-libs/slang )
- !build? ( systemd? ( sys-apps/systemd ) )
- udev? ( virtual/libudev:= )"
-DEPEND="${RDEPEND}
- virtual/pkgconfig
- nls? ( sys-devel/gettext )
- test? ( sys-devel/bc )
- virtual/os-headers"
-RDEPEND+="
- kill? (
- !sys-apps/coreutils[kill]
- !sys-process/procps[kill]
- )
- !net-wireless/rfkill
- !<app-shells/bash-completion-2.7-r1"
-
-REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
-RESTRICT="!test? ( test )"
-
-S="${WORKDIR}/${MY_P}"
-
-PATCHES=(
- # In glibc-2.29+, a lot of changes were made to arch-specific
- # handling of `struct termios', which breaks atleast MIPS.
- # The below patch from upstream fixes this, and should be
- # in the next release.
- # See: https://git.kernel.org/pub/scm/utils/util-linux/util-linux.git/commit/?id=963413a1adf6767ab17712097e288e1a346f63a7
- "${FILESDIR}/${PN}-2.33.1-fix-struct_termios-check.patch"
-)
-
-src_prepare() {
- default
-
- # Prevent uuidd test failure due to socket path limit. #593304
- sed -i \
- -e "s|UUIDD_SOCKET=\"\$(mktemp -u \"\${TS_OUTDIR}/uuiddXXXXXXXXXXXXX\")\"|UUIDD_SOCKET=\"\$(mktemp -u \"${T}/uuiddXXXXXXXXXXXXX.sock\")\"|g" \
- tests/ts/uuid/uuidd || die "Failed to fix uuidd test"
-
- if ! use userland_GNU; then
- # test runner is using GNU-specific xargs call
- sed -i -e 's:xargs:gxargs:' tests/run.sh || die
- # test requires util-linux uuidgen (which we don't build)
- rm tests/ts/uuid/oids || die
- fi
-
- if [[ ${PV} == 9999 ]] ; then
- po/update-potfiles
- eautoreconf
- fi
-
- elibtoolize
-}
-
-lfs_fallocate_test() {
- # Make sure we can use fallocate with LFS #300307
- cat <<-EOF > "${T}"/fallocate.${ABI}.c
- #define _GNU_SOURCE
- #include <fcntl.h>
- main() { return fallocate(0, 0, 0, 0); }
- EOF
- append-lfs-flags
- $(tc-getCC) ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} "${T}"/fallocate.${ABI}.c -o /dev/null >/dev/null 2>&1 \
- || export ac_cv_func_fallocate=no
- rm -f "${T}"/fallocate.${ABI}.c
-}
-
-python_configure() {
- local myeconfargs=(
- --disable-all-programs
- --disable-bash-completion
- --without-systemdsystemunitdir
- --with-python
- )
- if use userland_GNU; then
- myeconfargs+=(
- --enable-libblkid
- --enable-libmount
- --enable-pylibmount
- )
- fi
- mkdir "${BUILD_DIR}" || die
- pushd "${BUILD_DIR}" >/dev/null || die
- ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
- popd >/dev/null || die
-}
-
-multilib_src_configure() {
- lfs_fallocate_test
- # The scanf test in a run-time test which fails while cross-compiling.
- # Blindly assume a POSIX setup since we require libmount, and libmount
- # itself fails when the scanf test fails. #531856
- tc-is-cross-compiler && export scanf_cv_alloc_modifier=ms
- export ac_cv_header_security_pam_misc_h=$(multilib_native_usex pam) #485486
- export ac_cv_header_security_pam_appl_h=$(multilib_native_usex pam) #545042
-
- # Undo bad ncurses handling by upstream. Fall back to pkg-config. #601530
- export NCURSES6_CONFIG=false NCURSES5_CONFIG=false
- export NCURSESW6_CONFIG=false NCURSESW5_CONFIG=false
-
- local myeconfargs=(
- --enable-fs-paths-extra="${EPREFIX}/usr/sbin:${EPREFIX}/bin:${EPREFIX}/usr/bin"
- --with-bashcompletiondir="$(get_bashcompdir)"
- --without-python
- $(multilib_native_use_enable suid makeinstall-chown)
- $(multilib_native_use_enable suid makeinstall-setuid)
- $(multilib_native_use_with readline)
- $(multilib_native_use_with slang)
- $(multilib_native_use_with systemd)
- $(multilib_native_use_with udev)
- $(multilib_native_usex ncurses "$(use_with unicode ncursesw)" '--without-ncursesw')
- $(multilib_native_usex ncurses "$(use_with !unicode ncurses)" '--without-ncurses')
- $(tc-has-tls || echo --disable-tls)
- $(use_enable nls)
- $(use_enable unicode widechar)
- $(use_enable static-libs static)
- $(use_with selinux)
- $(use_with ncurses tinfo)
- )
- # build programs only on GNU, on *BSD we want libraries only
- if multilib_is_native_abi && use userland_GNU; then
- myeconfargs+=(
- --disable-chfn-chsh
- --disable-login
- --disable-nologin
- --disable-pylibmount
- --disable-su
- --enable-agetty
- --enable-bash-completion
- --enable-line
- --enable-partx
- --enable-raw
- --enable-rename
- --enable-rfkill
- --enable-schedutils
- --with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
- $(use_enable caps setpriv)
- $(use_enable cramfs)
- $(use_enable fdformat)
- $(use_enable tty-helpers mesg)
- $(use_enable tty-helpers wall)
- $(use_enable tty-helpers write)
- $(use_enable kill)
- )
- else
- myeconfargs+=(
- --disable-all-programs
- --disable-bash-completion
- --without-systemdsystemunitdir
- # build libraries
- --enable-libuuid
- --enable-libblkid
- --enable-libsmartcols
- --enable-libfdisk
- )
- if use userland_GNU; then
- # those libraries don't work on *BSD
- myeconfargs+=(
- --enable-libmount
- )
- fi
- fi
- ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
-
- if multilib_is_native_abi && use python; then
- python_foreach_impl python_configure
- fi
-}
-
-python_compile() {
- pushd "${BUILD_DIR}" >/dev/null || die
- emake all
- popd >/dev/null || die
-}
-
-multilib_src_compile() {
- emake all
-
- if multilib_is_native_abi && use python; then
- python_foreach_impl python_compile
- fi
-}
-
-python_test() {
- pushd "${BUILD_DIR}" >/dev/null || die
- emake check TS_OPTS="--parallel=$(makeopts_jobs) --nonroot"
- popd >/dev/null || die
-}
-
-multilib_src_test() {
- emake check TS_OPTS="--parallel=$(makeopts_jobs) --nonroot"
- if multilib_is_native_abi && use python; then
- python_foreach_impl python_test
- fi
-}
-
-python_install() {
- pushd "${BUILD_DIR}" >/dev/null || die
- emake DESTDIR="${D}" install
- python_optimize
- popd >/dev/null || die
-}
-
-multilib_src_install() {
- if multilib_is_native_abi && use python; then
- python_foreach_impl python_install
- fi
-
- emake DESTDIR="${D}" install
-
- if multilib_is_native_abi && use userland_GNU; then
- # need the libs in /
- gen_usr_ldscript -a blkid fdisk mount smartcols uuid
- fi
-}
-
-multilib_src_install_all() {
- dodoc AUTHORS NEWS README* Documentation/{TODO,*.txt,releases/*}
-
- # e2fsprogs-libs didnt install .la files, and .pc work fine
- find "${ED}" -name "*.la" -delete || die
-
- if ! use userland_GNU; then
- # manpage collisions
- # TODO: figure out a good way to keep them
- rm "${ED%/}"/usr/share/man/man3/uuid* || die
- fi
-
- if use pam; then
- newpamd "${FILESDIR}/runuser.pamd" runuser
- newpamd "${FILESDIR}/runuser-l.pamd" runuser-l
- fi
-
- # Note:
- # Bash completion for "runuser" command is provided by same file which
- # would also provide bash completion for "su" command. However, we don't
- # use "su" command from this package.
- # This triggers a known QA warning which we ignore for now to magically
- # keep bash completion for "su" command which shadow package does not
- # provide.
-}
-
-pkg_postinst() {
- if ! use tty-helpers; then
- elog "The mesg/wall/write tools have been disabled due to USE=-tty-helpers."
- fi
-
- if [[ -z ${REPLACING_VERSIONS} ]]; then
- elog "The agetty util now clears the terminal by default. You"
- elog "might want to add --noclear to your /etc/inittab lines."
- fi
-}
diff --git a/sys-apps/util-linux/util-linux-2.34-r3.ebuild b/sys-apps/util-linux/util-linux-2.34-r3.ebuild
deleted file mode 100644
index 16c378134edc..000000000000
--- a/sys-apps/util-linux/util-linux-2.34-r3.ebuild
+++ /dev/null
@@ -1,301 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python3_7 )
-
-inherit toolchain-funcs libtool flag-o-matic bash-completion-r1 usr-ldscript \
- pam python-r1 multilib-minimal multiprocessing systemd
-
-MY_PV="${PV/_/-}"
-MY_P="${PN}-${MY_PV}"
-
-if [[ ${PV} == 9999 ]] ; then
- inherit git-r3 autotools
- EGIT_REPO_URI="https://git.kernel.org/pub/scm/utils/util-linux/util-linux.git"
-else
- [[ "${PV}" = *_rc* ]] || \
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
- SRC_URI="https://www.kernel.org/pub/linux/utils/util-linux/v${PV:0:4}/${MY_P}.tar.xz"
-fi
-
-DESCRIPTION="Various useful Linux utilities"
-HOMEPAGE="https://www.kernel.org/pub/linux/utils/util-linux/ https://github.com/karelzak/util-linux"
-
-LICENSE="GPL-2 LGPL-2.1 BSD-4 MIT public-domain"
-SLOT="0"
-IUSE="build caps +cramfs fdformat hardlink kill +logger ncurses nls pam python +readline selinux slang static-libs su +suid systemd test tty-helpers udev unicode userland_GNU"
-
-# Most lib deps here are related to programs rather than our libs,
-# so we rarely need to specify ${MULTILIB_USEDEP}.
-RDEPEND="
- caps? ( sys-libs/libcap-ng )
- cramfs? ( sys-libs/zlib:= )
- ncurses? ( >=sys-libs/ncurses-5.2-r2:0=[unicode?] )
- nls? ( virtual/libintl[${MULTILIB_USEDEP}] )
- pam? ( sys-libs/pam )
- python? ( ${PYTHON_DEPS} )
- readline? ( sys-libs/readline:0= )
- selinux? ( >=sys-libs/libselinux-2.2.2-r4[${MULTILIB_USEDEP}] )
- slang? ( sys-libs/slang )
- !build? ( systemd? ( sys-apps/systemd ) )
- udev? ( virtual/libudev:= )"
-BDEPEND="
- virtual/pkgconfig
- nls? ( sys-devel/gettext )
- test? ( sys-devel/bc )
-"
-DEPEND="
- ${RDEPEND}
- virtual/os-headers
-"
-RDEPEND+="
- hardlink? ( !app-arch/hardlink )
- logger? ( !>=app-admin/sysklogd-2.0[logger] )
- kill? (
- !sys-apps/coreutils[kill]
- !sys-process/procps[kill]
- )
- su? (
- !<sys-apps/shadow-4.7-r2
- !>=sys-apps/shadow-4.7-r2[su]
- )
- !net-wireless/rfkill
- !<app-shells/bash-completion-2.7-r1"
-
-REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
-RESTRICT="!test? ( test )"
-
-S="${WORKDIR}/${MY_P}"
-
-src_prepare() {
- default
-
- # Prevent uuidd test failure due to socket path limit. #593304
- sed -i \
- -e "s|UUIDD_SOCKET=\"\$(mktemp -u \"\${TS_OUTDIR}/uuiddXXXXXXXXXXXXX\")\"|UUIDD_SOCKET=\"\$(mktemp -u \"${T}/uuiddXXXXXXXXXXXXX.sock\")\"|g" \
- tests/ts/uuid/uuidd || die "Failed to fix uuidd test"
-
- if ! use userland_GNU; then
- # test runner is using GNU-specific xargs call
- sed -i -e 's:xargs:gxargs:' tests/run.sh || die
- # test requires util-linux uuidgen (which we don't build)
- rm tests/ts/uuid/oids || die
- fi
-
- if [[ ${PV} == 9999 ]] ; then
- po/update-potfiles
- eautoreconf
- fi
-
- elibtoolize
-}
-
-lfs_fallocate_test() {
- # Make sure we can use fallocate with LFS #300307
- cat <<-EOF > "${T}"/fallocate.${ABI}.c
- #define _GNU_SOURCE
- #include <fcntl.h>
- main() { return fallocate(0, 0, 0, 0); }
- EOF
- append-lfs-flags
- $(tc-getCC) ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} "${T}"/fallocate.${ABI}.c -o /dev/null >/dev/null 2>&1 \
- || export ac_cv_func_fallocate=no
- rm -f "${T}"/fallocate.${ABI}.c
-}
-
-python_configure() {
- local myeconfargs=(
- "${commonargs[@]}"
- --disable-all-programs
- --disable-bash-completion
- --without-systemdsystemunitdir
- --with-python
- )
- if use userland_GNU; then
- myeconfargs+=(
- --enable-libblkid
- --enable-libmount
- --enable-pylibmount
- )
- fi
- mkdir "${BUILD_DIR}" || die
- pushd "${BUILD_DIR}" >/dev/null || die
- ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
- popd >/dev/null || die
-}
-
-multilib_src_configure() {
- lfs_fallocate_test
- # The scanf test in a run-time test which fails while cross-compiling.
- # Blindly assume a POSIX setup since we require libmount, and libmount
- # itself fails when the scanf test fails. #531856
- tc-is-cross-compiler && export scanf_cv_alloc_modifier=ms
- export ac_cv_header_security_pam_misc_h=$(multilib_native_usex pam) #485486
- export ac_cv_header_security_pam_appl_h=$(multilib_native_usex pam) #545042
-
- # Undo bad ncurses handling by upstream. Fall back to pkg-config. #601530
- export NCURSES6_CONFIG=false NCURSES5_CONFIG=false
- export NCURSESW6_CONFIG=false NCURSESW5_CONFIG=false
-
- # configure args shared by python and non-python builds
- local commonargs=(
- --enable-fs-paths-extra="${EPREFIX}/usr/sbin:${EPREFIX}/bin:${EPREFIX}/usr/bin"
- )
-
- local myeconfargs=(
- "${commonargs[@]}"
- --with-bashcompletiondir="$(get_bashcompdir)"
- --without-python
- $(multilib_native_use_enable suid makeinstall-chown)
- $(multilib_native_use_enable suid makeinstall-setuid)
- $(multilib_native_use_with readline)
- $(multilib_native_use_with slang)
- $(multilib_native_use_with systemd)
- $(multilib_native_use_with udev)
- $(multilib_native_usex ncurses "$(use_with unicode ncursesw)" '--without-ncursesw')
- $(multilib_native_usex ncurses "$(use_with !unicode ncurses)" '--without-ncurses')
- $(tc-has-tls || echo --disable-tls)
- $(use_enable nls)
- $(use_enable unicode widechar)
- $(use_enable static-libs static)
- $(use_with ncurses tinfo)
- $(use_with selinux)
- )
- # build programs only on GNU, on *BSD we want libraries only
- if multilib_is_native_abi && use userland_GNU; then
- myeconfargs+=(
- --disable-chfn-chsh
- --disable-login
- --disable-nologin
- --disable-pylibmount
- --enable-agetty
- --enable-bash-completion
- --enable-line
- --enable-partx
- --enable-raw
- --enable-rename
- --enable-rfkill
- --enable-schedutils
- --with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
- $(use_enable caps setpriv)
- $(use_enable cramfs)
- $(use_enable fdformat)
- $(use_enable hardlink)
- $(use_enable kill)
- $(use_enable logger)
- $(use_enable su)
- $(use_enable tty-helpers mesg)
- $(use_enable tty-helpers wall)
- $(use_enable tty-helpers write)
- )
- else
- myeconfargs+=(
- --disable-all-programs
- --disable-bash-completion
- --without-systemdsystemunitdir
- # build libraries
- --enable-libuuid
- --enable-libblkid
- --enable-libsmartcols
- --enable-libfdisk
- )
- if use userland_GNU; then
- # those libraries don't work on *BSD
- myeconfargs+=(
- --enable-libmount
- )
- fi
- fi
- ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
-
- if multilib_is_native_abi && use python; then
- python_foreach_impl python_configure
- fi
-}
-
-python_compile() {
- pushd "${BUILD_DIR}" >/dev/null || die
- emake all
- popd >/dev/null || die
-}
-
-multilib_src_compile() {
- emake all
-
- if multilib_is_native_abi && use python; then
- python_foreach_impl python_compile
- fi
-}
-
-python_test() {
- pushd "${BUILD_DIR}" >/dev/null || die
- emake check TS_OPTS="--parallel=$(makeopts_jobs) --nonroot"
- popd >/dev/null || die
-}
-
-multilib_src_test() {
- emake check TS_OPTS="--parallel=$(makeopts_jobs) --nonroot"
- if multilib_is_native_abi && use python; then
- python_foreach_impl python_test
- fi
-}
-
-python_install() {
- pushd "${BUILD_DIR}" >/dev/null || die
- emake DESTDIR="${D}" install
- python_optimize
- popd >/dev/null || die
-}
-
-multilib_src_install() {
- if multilib_is_native_abi && use python; then
- python_foreach_impl python_install
- fi
-
- # This needs to be called AFTER python_install call (#689190)
- emake DESTDIR="${D}" install
-
- if multilib_is_native_abi && use userland_GNU; then
- # need the libs in /
- gen_usr_ldscript -a blkid fdisk mount smartcols uuid
- fi
-}
-
-multilib_src_install_all() {
- dodoc AUTHORS NEWS README* Documentation/{TODO,*.txt,releases/*}
-
- # e2fsprogs-libs didnt install .la files, and .pc work fine
- find "${ED}" -name "*.la" -delete || die
-
- if ! use userland_GNU; then
- # manpage collisions
- # TODO: figure out a good way to keep them
- rm "${ED}"/usr/share/man/man3/uuid* || die
- fi
-
- if use pam; then
- newpamd "${FILESDIR}/runuser.pamd" runuser
- newpamd "${FILESDIR}/runuser-l.pamd" runuser-l
- fi
-
- # Note:
- # Bash completion for "runuser" command is provided by same file which
- # would also provide bash completion for "su" command. However, we don't
- # use "su" command from this package.
- # This triggers a known QA warning which we ignore for now to magically
- # keep bash completion for "su" command which shadow package does not
- # provide.
-}
-
-pkg_postinst() {
- if ! use tty-helpers; then
- elog "The mesg/wall/write tools have been disabled due to USE=-tty-helpers."
- fi
-
- if [[ -z ${REPLACING_VERSIONS} ]]; then
- elog "The agetty util now clears the terminal by default. You"
- elog "might want to add --noclear to your /etc/inittab lines."
- fi
-}
diff --git a/sys-apps/util-linux/util-linux-2.35.2.ebuild b/sys-apps/util-linux/util-linux-2.35.2.ebuild
index ba8b1c61789e..1df44660f8fa 100644
--- a/sys-apps/util-linux/util-linux-2.35.2.ebuild
+++ b/sys-apps/util-linux/util-linux-2.35.2.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -16,7 +16,7 @@ if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/utils/util-linux/util-linux.git"
else
[[ "${PV}" = *_rc* ]] || \
- KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv s390 sparc x86 ~amd64-linux ~x86-linux"
+ KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux"
SRC_URI="https://www.kernel.org/pub/linux/utils/util-linux/v${PV:0:4}/${MY_P}.tar.xz"
fi
@@ -25,7 +25,7 @@ HOMEPAGE="https://www.kernel.org/pub/linux/utils/util-linux/ https://github.com/
LICENSE="GPL-2 GPL-3 LGPL-2.1 BSD-4 MIT public-domain"
SLOT="0"
-IUSE="audit build caps +cramfs cryptsetup fdformat hardlink kill +logger ncurses nls pam python +readline selinux slang static-libs su +suid systemd test tty-helpers udev unicode userland_GNU"
+IUSE="audit build caps +cramfs cryptsetup fdformat hardlink kill +logger magic ncurses nls pam python +readline selinux slang static-libs su +suid systemd test tty-helpers udev unicode userland_GNU"
# Most lib deps here are related to programs rather than our libs,
# so we rarely need to specify ${MULTILIB_USEDEP}.
@@ -36,7 +36,10 @@ RDEPEND="
cramfs? ( sys-libs/zlib:= )
cryptsetup? ( sys-fs/cryptsetup )
hardlink? ( dev-libs/libpcre2:= )
- ncurses? ( >=sys-libs/ncurses-5.2-r2:0=[unicode?] )
+ ncurses? (
+ >=sys-libs/ncurses-5.2-r2:0=[unicode?]
+ magic? ( sys-apps/file:0= )
+ )
nls? ( virtual/libintl[${MULTILIB_USEDEP}] )
pam? ( sys-libs/pam )
ppc? ( sys-libs/librtas )
@@ -164,6 +167,7 @@ multilib_src_configure() {
$(multilib_native_use_with slang)
$(multilib_native_use_with systemd)
$(multilib_native_use_with udev)
+ $(multilib_native_usex ncurses "$(use_with magic libmagic)" '--without-libmagic')
$(multilib_native_usex ncurses "$(use_with unicode ncursesw)" '--without-ncursesw')
$(multilib_native_usex ncurses "$(use_with !unicode ncurses)" '--without-ncurses')
$(multilib_native_use_with audit)
diff --git a/sys-apps/util-linux/util-linux-2.36.2.ebuild b/sys-apps/util-linux/util-linux-2.36.2.ebuild
index daf96cb33aa0..dc8d4da2b30a 100644
--- a/sys-apps/util-linux/util-linux-2.36.2.ebuild
+++ b/sys-apps/util-linux/util-linux-2.36.2.ebuild
@@ -16,7 +16,7 @@ if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/utils/util-linux/util-linux.git"
else
[[ "${PV}" = *_rc* ]] || \
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
+ KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux"
SRC_URI="https://www.kernel.org/pub/linux/utils/util-linux/v${PV:0:4}/${MY_P}.tar.xz"
fi
@@ -25,7 +25,7 @@ HOMEPAGE="https://www.kernel.org/pub/linux/utils/util-linux/ https://github.com/
LICENSE="GPL-2 GPL-3 LGPL-2.1 BSD-4 MIT public-domain"
SLOT="0"
-IUSE="audit build caps +cramfs cryptsetup fdformat hardlink kill +logger ncurses nls pam python +readline selinux slang static-libs su +suid systemd test tty-helpers udev unicode userland_GNU"
+IUSE="audit build caps +cramfs cryptsetup fdformat hardlink kill +logger magic ncurses nls pam python +readline selinux slang static-libs su +suid systemd test tty-helpers udev unicode userland_GNU"
# Most lib deps here are related to programs rather than our libs,
# so we rarely need to specify ${MULTILIB_USEDEP}.
@@ -36,7 +36,10 @@ RDEPEND="
cramfs? ( sys-libs/zlib:= )
cryptsetup? ( sys-fs/cryptsetup )
hardlink? ( dev-libs/libpcre2:= )
- ncurses? ( >=sys-libs/ncurses-5.2-r2:0=[unicode?] )
+ ncurses? (
+ >=sys-libs/ncurses-5.2-r2:0=[unicode?]
+ magic? ( sys-apps/file:0= )
+ )
nls? ( virtual/libintl[${MULTILIB_USEDEP}] )
pam? ( sys-libs/pam )
ppc? ( sys-libs/librtas )
@@ -160,6 +163,7 @@ multilib_src_configure() {
$(multilib_native_use_with slang)
$(multilib_native_use_with systemd)
$(multilib_native_use_with udev)
+ $(multilib_native_usex ncurses "$(use_with magic libmagic)" '--without-libmagic')
$(multilib_native_usex ncurses "$(use_with unicode ncursesw)" '--without-ncursesw')
$(multilib_native_usex ncurses "$(use_with !unicode ncurses)" '--without-ncurses')
$(multilib_native_use_with audit)
diff --git a/sys-apps/util-linux/util-linux-2.36.1-r1.ebuild b/sys-apps/util-linux/util-linux-2.37_rc1.ebuild
index 0e3e92d94d7f..66a36a6cd0cb 100644
--- a/sys-apps/util-linux/util-linux-2.36.1-r1.ebuild
+++ b/sys-apps/util-linux/util-linux-2.37_rc1.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-PYTHON_COMPAT=( python3_{7,8,9} )
+PYTHON_COMPAT=( python3_{7..9} )
inherit toolchain-funcs libtool flag-o-matic bash-completion-r1 usr-ldscript \
pam python-r1 multilib-minimal multiprocessing systemd
@@ -17,7 +17,8 @@ if [[ ${PV} == 9999 ]] ; then
else
[[ "${PV}" = *_rc* ]] || \
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
- SRC_URI="https://www.kernel.org/pub/linux/utils/util-linux/v${PV:0:4}/${MY_P}.tar.xz"
+ SRC_URI="https://www.kernel.org/pub/linux/utils/util-linux/v${PV:0:4}/${MY_P}.tar.xz
+ https://dev.gentoo.org/~polynomial-c/${MY_P}-manpages.tar.xz"
fi
DESCRIPTION="Various useful Linux utilities"
@@ -25,7 +26,7 @@ HOMEPAGE="https://www.kernel.org/pub/linux/utils/util-linux/ https://github.com/
LICENSE="GPL-2 GPL-3 LGPL-2.1 BSD-4 MIT public-domain"
SLOT="0"
-IUSE="audit build caps +cramfs cryptsetup fdformat hardlink kill +logger ncurses nls pam python +readline selinux slang static-libs su +suid systemd test tty-helpers udev unicode userland_GNU"
+IUSE="audit build caps +cramfs cryptsetup fdformat hardlink kill +logger magic ncurses nls pam python +readline selinux slang static-libs su +suid systemd test tty-helpers udev unicode userland_GNU"
# Most lib deps here are related to programs rather than our libs,
# so we rarely need to specify ${MULTILIB_USEDEP}.
@@ -36,7 +37,10 @@ RDEPEND="
cramfs? ( sys-libs/zlib:= )
cryptsetup? ( sys-fs/cryptsetup )
hardlink? ( dev-libs/libpcre2:= )
- ncurses? ( >=sys-libs/ncurses-5.2-r2:0=[unicode?] )
+ ncurses? (
+ >=sys-libs/ncurses-5.2-r2:0=[unicode?]
+ magic? ( sys-apps/file:0= )
+ )
nls? ( virtual/libintl[${MULTILIB_USEDEP}] )
pam? ( sys-libs/pam )
ppc? ( sys-libs/librtas )
@@ -68,7 +72,15 @@ RDEPEND+="
!>=sys-apps/shadow-4.7-r2[su]
)
!net-wireless/rfkill
- !<app-shells/bash-completion-2.7-r1"
+ !<app-shells/bash-completion-2.7-r1
+"
+
+# Required for man-page generation
+if [[ "${PV}" == 9999 ]] ; then
+ BDEPEND+="
+ dev-ruby/asciidoctor
+ "
+fi
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
RESTRICT="!test? ( test )"
@@ -76,10 +88,17 @@ RESTRICT="!test? ( test )"
S="${WORKDIR}/${MY_P}"
PATCHES=(
- "${FILESDIR}/${P}-libmount_dont_use_symfollow.patch" #755878
- "${FILESDIR}/${P}-riscv32.patch"
)
+rm_man() {
+ [[ -n $1 ]] || die
+ local el
+ for el in $1 ; do
+ find "${WORKDIR}/man" -type f -name "${el}.?" -delete \
+ || die
+ done
+}
+
src_prepare() {
default
@@ -88,7 +107,7 @@ src_prepare() {
-e "s|UUIDD_SOCKET=\"\$(mktemp -u \"\${TS_OUTDIR}/uuiddXXXXXXXXXXXXX\")\"|UUIDD_SOCKET=\"\$(mktemp -u \"${T}/uuiddXXXXXXXXXXXXX.sock\")\"|g" \
tests/ts/uuid/uuidd || die "Failed to fix uuidd test"
- if ! use userland_GNU; then
+ if ! use userland_GNU ; then
# test runner is using GNU-specific xargs call
sed -i -e 's:xargs:gxargs:' tests/run.sh || die
# test requires util-linux uuidgen (which we don't build)
@@ -98,6 +117,14 @@ src_prepare() {
if [[ ${PV} == 9999 ]] ; then
po/update-potfiles
eautoreconf
+ else
+ # Conditionally remove some man-pages
+ use hardlink || rm_man "hardlink"
+ use kill || rm_man "kill"
+ use logger || rm_man "logger"
+ use ncurses || rm_man "pg"
+ use su || rm_man "su"
+ use tty-helpers || rm_man "mesg wall write"
fi
elibtoolize
@@ -124,7 +151,7 @@ python_configure() {
--without-systemdsystemunitdir
--with-python
)
- if use userland_GNU; then
+ if use userland_GNU ; then
myeconfargs+=(
--enable-libblkid
--enable-libmount
@@ -165,6 +192,7 @@ multilib_src_configure() {
$(multilib_native_use_with slang)
$(multilib_native_use_with systemd)
$(multilib_native_use_with udev)
+ $(multilib_native_usex ncurses "$(use_with magic libmagic)" '--without-libmagic')
$(multilib_native_usex ncurses "$(use_with unicode ncursesw)" '--without-ncursesw')
$(multilib_native_usex ncurses "$(use_with !unicode ncurses)" '--without-ncurses')
$(multilib_native_use_with audit)
@@ -176,12 +204,14 @@ multilib_src_configure() {
$(use_with selinux)
)
# build programs only on GNU, on *BSD we want libraries only
- if multilib_is_native_abi && use userland_GNU; then
+ if multilib_is_native_abi && use userland_GNU ; then
myeconfargs+=(
--disable-chfn-chsh
--disable-login
+ --disable-newgrp
--disable-nologin
--disable-pylibmount
+ --disable-vipw
--enable-agetty
--enable-bash-completion
--enable-line
@@ -204,9 +234,16 @@ multilib_src_configure() {
$(use_enable tty-helpers write)
$(use_with cryptsetup)
)
+ if [[ ${PV} == *9999 ]] ; then
+ myeconfargs+=( --enable-asciidoc )
+ else
+ # We ship pre-generated man-pages for releases
+ myeconfargs+=( --disable-asciidoc )
+ fi
else
myeconfargs+=(
--disable-all-programs
+ --disable-asciidoc
--disable-bash-completion
--without-systemdsystemunitdir
# build libraries
@@ -215,7 +252,7 @@ multilib_src_configure() {
--enable-libsmartcols
--enable-libfdisk
)
- if use userland_GNU; then
+ if use userland_GNU ; then
# those libraries don't work on *BSD
myeconfargs+=(
--enable-libmount
@@ -224,7 +261,7 @@ multilib_src_configure() {
fi
ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
- if multilib_is_native_abi && use python; then
+ if multilib_is_native_abi && use python ; then
python_foreach_impl python_configure
fi
}
@@ -238,7 +275,7 @@ python_compile() {
multilib_src_compile() {
emake all
- if multilib_is_native_abi && use python; then
+ if multilib_is_native_abi && use python ; then
python_foreach_impl python_compile
fi
}
@@ -251,7 +288,7 @@ python_test() {
multilib_src_test() {
emake check TS_OPTS="--parallel=$(makeopts_jobs) --nonroot"
- if multilib_is_native_abi && use python; then
+ if multilib_is_native_abi && use python ; then
python_foreach_impl python_test
fi
}
@@ -264,14 +301,14 @@ python_install() {
}
multilib_src_install() {
- if multilib_is_native_abi && use python; then
+ if multilib_is_native_abi && use python ; then
python_foreach_impl python_install
fi
# This needs to be called AFTER python_install call (#689190)
emake DESTDIR="${D}" install
- if multilib_is_native_abi && use userland_GNU; then
+ if multilib_is_native_abi && use userland_GNU ; then
# need the libs in /
gen_usr_ldscript -a blkid fdisk mount smartcols uuid
fi
@@ -279,18 +316,21 @@ multilib_src_install() {
multilib_src_install_all() {
dodoc AUTHORS NEWS README* Documentation/{TODO,*.txt,releases/*}
- chmod -x "${ED}"/usr/share/doc/util-linux-${PVR}/getopt/getopt-parse* || die
# e2fsprogs-libs didnt install .la files, and .pc work fine
find "${ED}" -name "*.la" -delete || die
- if ! use userland_GNU; then
+ if [[ ${PV} != 9999 ]] ; then
+ doman "${WORKDIR}"/man/man*/*
+ fi
+
+ if ! use userland_GNU ; then
# manpage collisions
# TODO: figure out a good way to keep them
rm "${ED}"/usr/share/man/man3/uuid* || die
fi
- if use pam; then
+ if use pam ; then
newpamd "${FILESDIR}/runuser.pamd" runuser
newpamd "${FILESDIR}/runuser-l.pamd" runuser-l
fi
@@ -305,11 +345,11 @@ multilib_src_install_all() {
}
pkg_postinst() {
- if ! use tty-helpers; then
+ if ! use tty-helpers ; then
elog "The mesg/wall/write tools have been disabled due to USE=-tty-helpers."
fi
- if [[ -z ${REPLACING_VERSIONS} ]]; then
+ if [[ -z ${REPLACING_VERSIONS} ]] ; then
elog "The agetty util now clears the terminal by default. You"
elog "might want to add --noclear to your /etc/inittab lines."
fi
diff --git a/sys-apps/util-linux/util-linux-9999.ebuild b/sys-apps/util-linux/util-linux-9999.ebuild
index 1a657d941caf..66a36a6cd0cb 100644
--- a/sys-apps/util-linux/util-linux-9999.ebuild
+++ b/sys-apps/util-linux/util-linux-9999.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-PYTHON_COMPAT=( python3_{7,8,9} )
+PYTHON_COMPAT=( python3_{7..9} )
inherit toolchain-funcs libtool flag-o-matic bash-completion-r1 usr-ldscript \
pam python-r1 multilib-minimal multiprocessing systemd
@@ -17,7 +17,8 @@ if [[ ${PV} == 9999 ]] ; then
else
[[ "${PV}" = *_rc* ]] || \
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
- SRC_URI="https://www.kernel.org/pub/linux/utils/util-linux/v${PV:0:4}/${MY_P}.tar.xz"
+ SRC_URI="https://www.kernel.org/pub/linux/utils/util-linux/v${PV:0:4}/${MY_P}.tar.xz
+ https://dev.gentoo.org/~polynomial-c/${MY_P}-manpages.tar.xz"
fi
DESCRIPTION="Various useful Linux utilities"
@@ -25,7 +26,7 @@ HOMEPAGE="https://www.kernel.org/pub/linux/utils/util-linux/ https://github.com/
LICENSE="GPL-2 GPL-3 LGPL-2.1 BSD-4 MIT public-domain"
SLOT="0"
-IUSE="audit build caps +cramfs cryptsetup fdformat hardlink kill +logger ncurses nls pam python +readline selinux slang static-libs su +suid systemd test tty-helpers udev unicode userland_GNU"
+IUSE="audit build caps +cramfs cryptsetup fdformat hardlink kill +logger magic ncurses nls pam python +readline selinux slang static-libs su +suid systemd test tty-helpers udev unicode userland_GNU"
# Most lib deps here are related to programs rather than our libs,
# so we rarely need to specify ${MULTILIB_USEDEP}.
@@ -36,7 +37,10 @@ RDEPEND="
cramfs? ( sys-libs/zlib:= )
cryptsetup? ( sys-fs/cryptsetup )
hardlink? ( dev-libs/libpcre2:= )
- ncurses? ( >=sys-libs/ncurses-5.2-r2:0=[unicode?] )
+ ncurses? (
+ >=sys-libs/ncurses-5.2-r2:0=[unicode?]
+ magic? ( sys-apps/file:0= )
+ )
nls? ( virtual/libintl[${MULTILIB_USEDEP}] )
pam? ( sys-libs/pam )
ppc? ( sys-libs/librtas )
@@ -68,7 +72,15 @@ RDEPEND+="
!>=sys-apps/shadow-4.7-r2[su]
)
!net-wireless/rfkill
- !<app-shells/bash-completion-2.7-r1"
+ !<app-shells/bash-completion-2.7-r1
+"
+
+# Required for man-page generation
+if [[ "${PV}" == 9999 ]] ; then
+ BDEPEND+="
+ dev-ruby/asciidoctor
+ "
+fi
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
RESTRICT="!test? ( test )"
@@ -78,6 +90,15 @@ S="${WORKDIR}/${MY_P}"
PATCHES=(
)
+rm_man() {
+ [[ -n $1 ]] || die
+ local el
+ for el in $1 ; do
+ find "${WORKDIR}/man" -type f -name "${el}.?" -delete \
+ || die
+ done
+}
+
src_prepare() {
default
@@ -86,7 +107,7 @@ src_prepare() {
-e "s|UUIDD_SOCKET=\"\$(mktemp -u \"\${TS_OUTDIR}/uuiddXXXXXXXXXXXXX\")\"|UUIDD_SOCKET=\"\$(mktemp -u \"${T}/uuiddXXXXXXXXXXXXX.sock\")\"|g" \
tests/ts/uuid/uuidd || die "Failed to fix uuidd test"
- if ! use userland_GNU; then
+ if ! use userland_GNU ; then
# test runner is using GNU-specific xargs call
sed -i -e 's:xargs:gxargs:' tests/run.sh || die
# test requires util-linux uuidgen (which we don't build)
@@ -96,6 +117,14 @@ src_prepare() {
if [[ ${PV} == 9999 ]] ; then
po/update-potfiles
eautoreconf
+ else
+ # Conditionally remove some man-pages
+ use hardlink || rm_man "hardlink"
+ use kill || rm_man "kill"
+ use logger || rm_man "logger"
+ use ncurses || rm_man "pg"
+ use su || rm_man "su"
+ use tty-helpers || rm_man "mesg wall write"
fi
elibtoolize
@@ -122,7 +151,7 @@ python_configure() {
--without-systemdsystemunitdir
--with-python
)
- if use userland_GNU; then
+ if use userland_GNU ; then
myeconfargs+=(
--enable-libblkid
--enable-libmount
@@ -163,6 +192,7 @@ multilib_src_configure() {
$(multilib_native_use_with slang)
$(multilib_native_use_with systemd)
$(multilib_native_use_with udev)
+ $(multilib_native_usex ncurses "$(use_with magic libmagic)" '--without-libmagic')
$(multilib_native_usex ncurses "$(use_with unicode ncursesw)" '--without-ncursesw')
$(multilib_native_usex ncurses "$(use_with !unicode ncurses)" '--without-ncurses')
$(multilib_native_use_with audit)
@@ -174,12 +204,14 @@ multilib_src_configure() {
$(use_with selinux)
)
# build programs only on GNU, on *BSD we want libraries only
- if multilib_is_native_abi && use userland_GNU; then
+ if multilib_is_native_abi && use userland_GNU ; then
myeconfargs+=(
--disable-chfn-chsh
--disable-login
+ --disable-newgrp
--disable-nologin
--disable-pylibmount
+ --disable-vipw
--enable-agetty
--enable-bash-completion
--enable-line
@@ -202,9 +234,16 @@ multilib_src_configure() {
$(use_enable tty-helpers write)
$(use_with cryptsetup)
)
+ if [[ ${PV} == *9999 ]] ; then
+ myeconfargs+=( --enable-asciidoc )
+ else
+ # We ship pre-generated man-pages for releases
+ myeconfargs+=( --disable-asciidoc )
+ fi
else
myeconfargs+=(
--disable-all-programs
+ --disable-asciidoc
--disable-bash-completion
--without-systemdsystemunitdir
# build libraries
@@ -213,7 +252,7 @@ multilib_src_configure() {
--enable-libsmartcols
--enable-libfdisk
)
- if use userland_GNU; then
+ if use userland_GNU ; then
# those libraries don't work on *BSD
myeconfargs+=(
--enable-libmount
@@ -222,7 +261,7 @@ multilib_src_configure() {
fi
ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
- if multilib_is_native_abi && use python; then
+ if multilib_is_native_abi && use python ; then
python_foreach_impl python_configure
fi
}
@@ -236,7 +275,7 @@ python_compile() {
multilib_src_compile() {
emake all
- if multilib_is_native_abi && use python; then
+ if multilib_is_native_abi && use python ; then
python_foreach_impl python_compile
fi
}
@@ -249,7 +288,7 @@ python_test() {
multilib_src_test() {
emake check TS_OPTS="--parallel=$(makeopts_jobs) --nonroot"
- if multilib_is_native_abi && use python; then
+ if multilib_is_native_abi && use python ; then
python_foreach_impl python_test
fi
}
@@ -262,14 +301,14 @@ python_install() {
}
multilib_src_install() {
- if multilib_is_native_abi && use python; then
+ if multilib_is_native_abi && use python ; then
python_foreach_impl python_install
fi
# This needs to be called AFTER python_install call (#689190)
emake DESTDIR="${D}" install
- if multilib_is_native_abi && use userland_GNU; then
+ if multilib_is_native_abi && use userland_GNU ; then
# need the libs in /
gen_usr_ldscript -a blkid fdisk mount smartcols uuid
fi
@@ -281,13 +320,17 @@ multilib_src_install_all() {
# e2fsprogs-libs didnt install .la files, and .pc work fine
find "${ED}" -name "*.la" -delete || die
- if ! use userland_GNU; then
+ if [[ ${PV} != 9999 ]] ; then
+ doman "${WORKDIR}"/man/man*/*
+ fi
+
+ if ! use userland_GNU ; then
# manpage collisions
# TODO: figure out a good way to keep them
rm "${ED}"/usr/share/man/man3/uuid* || die
fi
- if use pam; then
+ if use pam ; then
newpamd "${FILESDIR}/runuser.pamd" runuser
newpamd "${FILESDIR}/runuser-l.pamd" runuser-l
fi
@@ -302,11 +345,11 @@ multilib_src_install_all() {
}
pkg_postinst() {
- if ! use tty-helpers; then
+ if ! use tty-helpers ; then
elog "The mesg/wall/write tools have been disabled due to USE=-tty-helpers."
fi
- if [[ -z ${REPLACING_VERSIONS} ]]; then
+ if [[ -z ${REPLACING_VERSIONS} ]] ; then
elog "The agetty util now clears the terminal by default. You"
elog "might want to add --noclear to your /etc/inittab lines."
fi