Gentoo Archives: gentoo-commits

From: Andreas Sturmlechner <asturm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-auth/elogind/, sys-auth/elogind/files/
Date: Sun, 29 Apr 2018 19:25:40
Message-Id: 1525028967.55dd8bb9d34c6a2a9f538e9b6fdbd4d2d4bb7c20.asturm@gentoo
1 commit: 55dd8bb9d34c6a2a9f538e9b6fdbd4d2d4bb7c20
2 Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
3 AuthorDate: Sun Apr 29 19:09:27 2018 +0000
4 Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
5 CommitDate: Sun Apr 29 19:09:27 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=55dd8bb9
7
8 sys-auth/elogind: 236.1 version bump
9
10 Bug: https://bugs.gentoo.org/644118
11 Bug: https://bugs.gentoo.org/649834
12 Closes: https://bugs.gentoo.org/654166
13 Package-Manager: Portage-2.3.31, Repoman-2.3.9
14
15 sys-auth/elogind/Manifest | 1 +
16 sys-auth/elogind/elogind-236.1.ebuild | 118 ++++++++++++++++++++++++
17 sys-auth/elogind/files/elogind-236.1-docs.patch | 24 +++++
18 3 files changed, 143 insertions(+)
19
20 diff --git a/sys-auth/elogind/Manifest b/sys-auth/elogind/Manifest
21 index 25d08cb3a62..fb21f216ddf 100644
22 --- a/sys-auth/elogind/Manifest
23 +++ b/sys-auth/elogind/Manifest
24 @@ -1 +1,2 @@
25 DIST elogind-235.2.tar.gz 975652 BLAKE2B c568b5eec89da14f55211cf4405d96b4bb1ea274d1237739a92c4f3585a6181a3e17dc7ed2af5161c649cae2149b3bd25f4212cf5a304383b254e39d7aa0b378 SHA512 6fa9194e8c21fa3d3caf6f9499f772dbfe38b9d40d8a0fe43ee32ad4b2acd672a78798d00694d1e0d6107625f4f3f06b71e0a5466ed4be446d670f9bcd961313
26 +DIST elogind-236.1.tar.gz 1050387 BLAKE2B d0d295210eb07374cae738f55b472d9410f68c9e7f318dd736b5fcb5c0409c3da144988d8042b1e3b103d34d7a02471b4e316a924c9b1640c605fc73972de3da SHA512 ab4989f4467ef001bb8b837035bee870beaf5ec5fa2389649bdcad2fe7bbf82691bfd3176cf9a3bf3b5c232c77210f431f2d38ebdbfd09f5a7868cd50e476c59
27
28 diff --git a/sys-auth/elogind/elogind-236.1.ebuild b/sys-auth/elogind/elogind-236.1.ebuild
29 new file mode 100644
30 index 00000000000..4a29aef9281
31 --- /dev/null
32 +++ b/sys-auth/elogind/elogind-236.1.ebuild
33 @@ -0,0 +1,118 @@
34 +# Copyright 1999-2018 Gentoo Foundation
35 +# Distributed under the terms of the GNU General Public License v2
36 +
37 +EAPI=6
38 +
39 +inherit linux-info meson pam udev xdg-utils
40 +
41 +DESCRIPTION="The systemd project's logind, extracted to a standalone package"
42 +HOMEPAGE="https://github.com/elogind/elogind"
43 +SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
44 +
45 +LICENSE="CC0-1.0 LGPL-2.1+ public-domain"
46 +SLOT="0"
47 +KEYWORDS="~amd64 ~arm ~x86"
48 +IUSE="+acl debug doc +pam +policykit selinux"
49 +
50 +COMMON_DEPEND="
51 + sys-apps/util-linux
52 + sys-libs/libcap
53 + virtual/libudev:=
54 + acl? ( sys-apps/acl )
55 + pam? ( virtual/pam )
56 + selinux? ( sys-libs/libselinux )
57 +"
58 +DEPEND="${COMMON_DEPEND}
59 + app-text/docbook-xml-dtd:4.2
60 + app-text/docbook-xml-dtd:4.5
61 + app-text/docbook-xsl-stylesheets
62 + dev-util/gperf
63 + dev-util/intltool
64 + sys-devel/libtool
65 + virtual/pkgconfig
66 +"
67 +RDEPEND="${COMMON_DEPEND}
68 + !sys-apps/systemd
69 +"
70 +PDEPEND="
71 + sys-apps/dbus
72 + policykit? ( sys-auth/polkit )
73 +"
74 +
75 +PATCHES=( "${FILESDIR}/${P}-docs.patch" )
76 +
77 +pkg_setup() {
78 + local CONFIG_CHECK="~CGROUPS ~EPOLL ~INOTIFY_USER ~SIGNALFD ~TIMERFD"
79 +
80 + if use kernel_linux; then
81 + linux-info_pkg_setup
82 + fi
83 +}
84 +
85 +src_prepare() {
86 + default
87 + xdg_environment_reset
88 +}
89 +
90 +src_configure() {
91 + local rccgroupmode="$(grep rc_cgroup_mode /etc/rc.conf | cut -d '"' -f 2)"
92 + local cgroupmode="legacy"
93 +
94 + if [[ "xhybrid" = "x${rccgroupmode}" ]] ; then
95 + cgroupmode="hybrid"
96 + elif [[ "xunified" = "x${rccgroupmode}" ]] ; then
97 + cgroupmode="unified"
98 + fi
99 +
100 + local emesonargs=(
101 + -Ddocdir="${EPREFIX}/usr/share/doc/${PF}"
102 + -Dhtmldir="${EPREFIX}/usr/share/doc/${PF}/html"
103 + -Dpamlibdir=$(getpam_mod_dir)
104 + -Dudevrulesdir="$(get_udevdir)"/rules.d
105 + --libdir="${EPREFIX}"/usr/$(get_libdir)
106 + -Drootlibdir="${EPREFIX}"/$(get_libdir)
107 + -Drootlibexecdir="${EPREFIX}"/$(get_libdir)/elogind
108 + -Drootprefix="${EPREFIX}/"
109 + -Dbashcompletiondir="${EPREFIX}/usr/share/bash-completion/completions"
110 + -Dman=auto
111 + -Dsmack=true
112 + -Dcgroup-controller=openrc
113 + -Ddefault-hierarchy=${cgroupmode}
114 + -Ddefault-kill-user-processes=false
115 + -Dacl=$(usex acl true false)
116 + -Ddebug=$(usex debug elogind false)
117 + --buildtype $(usex debug debug release)
118 + -Dhtml=$(usex doc auto false)
119 + -Dpam=$(usex pam true false)
120 + -Dselinux=$(usex selinux true false)
121 + )
122 +
123 + meson_src_configure
124 +}
125 +
126 +src_install() {
127 + DOCS+=( src/libelogind/sd-bus/GVARIANT-SERIALIZATION )
128 +
129 + meson_src_install
130 +
131 + newinitd "${FILESDIR}"/${PN}.init ${PN}
132 +
133 + sed -e "s/@libdir@/$(get_libdir)/" "${FILESDIR}"/${PN}.conf.in > ${PN}.conf || die
134 + newconfd ${PN}.conf ${PN}
135 +}
136 +
137 +pkg_postinst() {
138 + if [[ "$(rc-config list boot | grep elogind)" != "" ]]; then
139 + elog "elogind is currently started from boot runlevel."
140 + elif [[ "$(rc-config list default | grep elogind)" != "" ]]; then
141 + ewarn "elogind is currently started from default runlevel."
142 + ewarn "Please remove elogind from the default runlevel and"
143 + ewarn "add it to the boot runlevel by:"
144 + ewarn "# rc-update del elogind default"
145 + ewarn "# rc-update add elogind boot"
146 + else
147 + ewarn "elogind is currently not started from any runlevel."
148 + ewarn "You may add it to the boot runlevel by:"
149 + ewarn "# rc-update add elogind boot"
150 + fi
151 +}
152
153 diff --git a/sys-auth/elogind/files/elogind-236.1-docs.patch b/sys-auth/elogind/files/elogind-236.1-docs.patch
154 new file mode 100644
155 index 00000000000..46c6fa9b9ce
156 --- /dev/null
157 +++ b/sys-auth/elogind/files/elogind-236.1-docs.patch
158 @@ -0,0 +1,24 @@
159 +--- a/meson.build 2018-04-20 17:19:23.912940283 +0200
160 ++++ b/meson.build 2018-04-20 17:20:02.265941434 +0200
161 +@@ -2800,20 +2800,7 @@
162 + # install_data('modprobe.d/systemd.conf',
163 + # install_dir : modprobedir)
164 + #endif // 0
165 +-install_data('README',
166 +- 'NEWS',
167 +- 'CODING_STYLE',
168 +-#if 0 /// UNNEEDED by elogind
169 +-# 'DISTRO_PORTING',
170 +-# 'ENVIRONMENT.md',
171 +-#endif // 0
172 +- 'LICENSE.GPL2',
173 +- 'LICENSE.LGPL2.1',
174 +- 'src/libelogind/sd-bus/GVARIANT-SERIALIZATION',
175 +-#if 0 /// UNNEEDED by elogind
176 +-# 'TRANSIENT-SETTINGS.md',
177 +-# 'UIDS-GIDS.md',
178 +-#endif // 0
179 ++install_data('src/libelogind/sd-bus/GVARIANT-SERIALIZATION',
180 + install_dir : docdir)
181 +
182 + #if 0 /// UNNEEDED by elogind