summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-apps/accountsservice')
-rw-r--r--sys-apps/accountsservice/Manifest2
-rw-r--r--sys-apps/accountsservice/accountsservice-0.6.50-r1.ebuild61
-rw-r--r--sys-apps/accountsservice/accountsservice-23.13.9.ebuild98
-rw-r--r--sys-apps/accountsservice/files/accountsservice-0.6.50-loaded-state.patch36
-rw-r--r--sys-apps/accountsservice/files/accountsservice-22.04.62-gentoo-system-users.patch (renamed from sys-apps/accountsservice/files/accountsservice-0.6.35-gentoo-system-users.patch)35
-rw-r--r--sys-apps/accountsservice/files/accountsservice-23.13.9-generate-version.patch30
-rw-r--r--sys-apps/accountsservice/files/accountsservice-23.13.9-musl-fixes.patch52
-rw-r--r--sys-apps/accountsservice/metadata.xml22
8 files changed, 214 insertions, 122 deletions
diff --git a/sys-apps/accountsservice/Manifest b/sys-apps/accountsservice/Manifest
index a3e3d7211afc..144f62adb755 100644
--- a/sys-apps/accountsservice/Manifest
+++ b/sys-apps/accountsservice/Manifest
@@ -1 +1 @@
-DIST accountsservice-0.6.50.tar.xz 384484 BLAKE2B 52c06ba85498f292204834f967211d8f0940786dc2ea3070124d3aecccd551375bfbc8fc31f23a2c3c86e23359294307656c3b927c4e819fc102d8626ae0dd82 SHA512 6e07cd318452b1cbedeacd729f0ebb200525caf1b09981abb2bac16fd90756a790ebec08aca0a0cea016f14ab27c159a68fe1332ef4bc636c5863b8c61040f64
+DIST accountsservice-23.13.9.tar.xz 636064 BLAKE2B 74dbbe816937e626ba0f6524b4293466ac2905f474396f5d23633e966d46e013de110671abcbfe2911fffa1e98872e2525b61594a967f917975ebf18d39b8547 SHA512 c6eb543ce2e07b61bbdfa454e388949bc688517be0536b14f30c66383ed105b15d3fab8b6c62b1eaa08f67d9bdc29b928729d9f7c704f47de4decf0de8e12f89
diff --git a/sys-apps/accountsservice/accountsservice-0.6.50-r1.ebuild b/sys-apps/accountsservice/accountsservice-0.6.50-r1.ebuild
deleted file mode 100644
index 231fdc7776b3..000000000000
--- a/sys-apps/accountsservice/accountsservice-0.6.50-r1.ebuild
+++ /dev/null
@@ -1,61 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-GNOME2_EAUTORECONF="yes"
-
-inherit gnome2 systemd
-
-DESCRIPTION="D-Bus interfaces for querying and manipulating user account information"
-HOMEPAGE="https://www.freedesktop.org/wiki/Software/AccountsService/"
-SRC_URI="https://www.freedesktop.org/software/${PN}/${P}.tar.xz"
-
-LICENSE="GPL-3+"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 ~ia64 ppc ppc64 ~sparc x86"
-
-IUSE="doc consolekit elogind +introspection selinux systemd"
-REQUIRED_USE="^^ ( consolekit elogind systemd )"
-
-CDEPEND="
- >=dev-libs/glib-2.44:2
- sys-auth/polkit
- consolekit? ( sys-auth/consolekit )
- elogind? ( >=sys-auth/elogind-229.4 )
- introspection? ( >=dev-libs/gobject-introspection-0.9.12:= )
- systemd? ( >=sys-apps/systemd-186:0= )
-"
-DEPEND="${CDEPEND}
- dev-libs/libxslt
- dev-util/gdbus-codegen
- >=dev-util/gtk-doc-am-1.15
- >=dev-util/intltool-0.40
- sys-devel/gettext
- virtual/pkgconfig
- doc? (
- app-text/docbook-xml-dtd:4.1.2
- app-text/xmlto )
-"
-RDEPEND="${CDEPEND}
- selinux? ( sec-policy/selinux-accountsd )
-"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-0.6.35-gentoo-system-users.patch
-
- # lib: don't set loaded state until seat is fetched (from 'master')
- "${FILESDIR}"/${P}-loaded-state.patch
-)
-
-src_configure() {
- gnome2_src_configure \
- --disable-static \
- --disable-more-warnings \
- --localstatedir="${EPREFIX}"/var \
- --enable-admin-group="wheel" \
- --with-systemdsystemunitdir="$(systemd_get_systemunitdir)" \
- $(use_enable doc docbook-docs) \
- $(use_enable elogind) \
- $(use_enable introspection) \
- $(use_enable systemd)
-}
diff --git a/sys-apps/accountsservice/accountsservice-23.13.9.ebuild b/sys-apps/accountsservice/accountsservice-23.13.9.ebuild
new file mode 100644
index 000000000000..61e932e21ed9
--- /dev/null
+++ b/sys-apps/accountsservice/accountsservice-23.13.9.ebuild
@@ -0,0 +1,98 @@
+# Copyright 2011-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+PYTHON_COMPAT=( python3_{9..11} )
+inherit meson python-any-r1 systemd
+
+DESCRIPTION="D-Bus interfaces for querying and manipulating user account information"
+HOMEPAGE="https://www.freedesktop.org/wiki/Software/AccountsService/"
+SRC_URI="https://www.freedesktop.org/software/${PN}/${P}.tar.xz"
+
+LICENSE="GPL-3+"
+SLOT="0"
+KEYWORDS="~alpha amd64 arm arm64 ~ia64 ~loong ppc ppc64 ~riscv ~sparc x86"
+
+IUSE="doc elogind gtk-doc +introspection selinux systemd test"
+RESTRICT="!test? ( test )"
+REQUIRED_USE="^^ ( elogind systemd )"
+
+CDEPEND="
+ >=dev-libs/glib-2.63.5:2
+ sys-auth/polkit
+ virtual/libcrypt:=
+ elogind? ( >=sys-auth/elogind-229.4 )
+ introspection? ( >=dev-libs/gobject-introspection-0.9.12:= )
+ systemd? ( >=sys-apps/systemd-186:0= )
+"
+DEPEND="${CDEPEND}
+ sys-apps/dbus
+"
+BDEPEND="
+ dev-libs/libxslt
+ dev-util/gdbus-codegen
+ dev-util/glib-utils
+ sys-devel/gettext
+ virtual/pkgconfig
+ doc? (
+ app-text/docbook-xml-dtd:4.1.2
+ app-text/xmlto
+ )
+ gtk-doc? (
+ dev-util/gtk-doc
+ app-text/docbook-xml-dtd:4.3
+ )
+ test? (
+ $(python_gen_any_dep '
+ dev-python/python-dbusmock[${PYTHON_USEDEP}]
+ ')
+ )
+"
+RDEPEND="${CDEPEND}
+ selinux? ( sec-policy/selinux-accountsd )
+"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-22.04.62-gentoo-system-users.patch
+ "${FILESDIR}"/${PN}-23.13.9-generate-version.patch #905770
+ # From Alpine Linux
+ # https://gitlab.freedesktop.org/accountsservice/accountsservice/-/merge_requests/97
+ "${FILESDIR}"/${PN}-23.13.9-musl-fixes.patch
+)
+
+python_check_deps() {
+ if use test; then
+ python_has_version "dev-python/python-dbusmock[${PYTHON_USEDEP}]"
+ fi
+}
+
+src_configure() {
+ # No option to disable tests
+ if ! use test; then
+ sed -e "/subdir('tests')/d" -i meson.build || die
+ fi
+
+ local emesonargs=(
+ --localstatedir="${EPREFIX}/var"
+ -Dsystemdsystemunitdir="$(systemd_get_systemunitdir)"
+ -Dadmin_group="wheel"
+ $(meson_use elogind)
+ $(meson_use introspection)
+ $(meson_use doc docbook)
+ $(meson_use gtk-doc gtk_doc)
+ -Dvapi=false
+ )
+ meson_src_configure
+}
+
+src_install() {
+ meson_src_install
+
+ # https://gitlab.freedesktop.org/accountsservice/accountsservice/-/issues/90
+ if use doc; then
+ mv "${ED}/usr/share/doc/${PN}" "${ED}/usr/share/doc/${PF}" || die
+ fi
+
+ # This directories are created at runtime when needed
+ rm -r "${ED}"/var/lib || die
+}
diff --git a/sys-apps/accountsservice/files/accountsservice-0.6.50-loaded-state.patch b/sys-apps/accountsservice/files/accountsservice-0.6.50-loaded-state.patch
deleted file mode 100644
index 901704bc601f..000000000000
--- a/sys-apps/accountsservice/files/accountsservice-0.6.50-loaded-state.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From c7fa612023a163e8b2352e1170c6df3fceb19b27 Mon Sep 17 00:00:00 2001
-From: Ray Strode <rstrode@redhat.com>
-Date: Thu, 19 Jul 2018 13:14:09 -0400
-Subject: lib: don't set loaded state until seat is fetched
-
-At the moment we set is-loaded on the user-manager
-object as soon as we start fetching the seat, but
-we should waiting until the seat is fetched, so
-that can_switch() will return the correct value
-if the caller waited until the loaded signal
-to use it.
-
-This commit changes the >= to > which I believe
-was the original intention anyway.
-
-https://bugs.freedesktop.org/show_bug.cgi?id=107298
----
- src/libaccountsservice/act-user-manager.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/libaccountsservice/act-user-manager.c b/src/libaccountsservice/act-user-manager.c
-index 325421b..e7e26b1 100644
---- a/src/libaccountsservice/act-user-manager.c
-+++ b/src/libaccountsservice/act-user-manager.c
-@@ -2382,7 +2382,7 @@ maybe_set_is_loaded (ActUserManager *manager)
- /* Don't set is_loaded yet unless the seat is already loaded enough
- * or failed to load.
- */
-- if (manager->priv->seat.state >= ACT_USER_MANAGER_SEAT_STATE_GET_ID) {
-+ if (manager->priv->seat.state > ACT_USER_MANAGER_SEAT_STATE_GET_ID) {
- g_debug ("ActUserManager: Seat loaded, so now setting loaded property");
- } else if (manager->priv->seat.state == ACT_USER_MANAGER_SEAT_STATE_UNLOADED) {
- g_debug ("ActUserManager: Seat wouldn't load, so giving up on it and setting loaded property");
---
-cgit v1.1
-
diff --git a/sys-apps/accountsservice/files/accountsservice-0.6.35-gentoo-system-users.patch b/sys-apps/accountsservice/files/accountsservice-22.04.62-gentoo-system-users.patch
index 39ebf42ea6ac..d65fa2f89d8a 100644
--- a/sys-apps/accountsservice/files/accountsservice-0.6.35-gentoo-system-users.patch
+++ b/sys-apps/accountsservice/files/accountsservice-22.04.62-gentoo-system-users.patch
@@ -1,9 +1,22 @@
---- a/src/user-classify.c.old 2013-12-04 20:29:48.944454769 +0100
-+++ b/src/user-classify.c 2013-12-04 20:32:59.728283477 +0100
-@@ -55,6 +55,48 @@
+From 0db673b94a6031640ae5faa3b79c4a1fea078350 Mon Sep 17 00:00:00 2001
+From: Matt Turner <mattst88@gmail.com>
+Date: Sun, 30 Jan 2022 12:00:09 -0800
+Subject: [PATCH] Add more users
+
+---
+ src/user-classify.c | 35 ++++++++++++++++++++++++++++++++++-
+ 1 file changed, 34 insertions(+), 1 deletion(-)
+
+diff --git a/src/user-classify.c b/src/user-classify.c
+index 9224905..70f1877 100644
+--- a/src/user-classify.c
++++ b/src/user-classify.c
+@@ -52,7 +52,40 @@ static const char *default_excludes[] = {
"at",
"gdm",
- "gnome-initial-setup"
+ "gnome-initial-setup",
+- "git"
++ "git",
+ /* Additional Gentoo system users with non-trivial login shell */
+ "amanda",
+ "backuppc",
@@ -12,15 +25,6 @@
+ "flexlm",
+ "foldingathome",
+ "geneweb",
-+ "git",
-+ "gnump3d",
-+ "hacluster",
-+ "hg",
-+ "hsqldb",
-+ "infinote",
-+ "foldingathome",
-+ "geneweb",
-+ "git",
+ "gnump3d",
+ "hacluster",
+ "hg",
@@ -48,4 +52,7 @@
+ "vdradmin",
};
- #define PATH_NOLOGIN "/sbin/nologin"
+ static gboolean
+--
+2.34.1
+
diff --git a/sys-apps/accountsservice/files/accountsservice-23.13.9-generate-version.patch b/sys-apps/accountsservice/files/accountsservice-23.13.9-generate-version.patch
new file mode 100644
index 000000000000..162b914b1828
--- /dev/null
+++ b/sys-apps/accountsservice/files/accountsservice-23.13.9-generate-version.patch
@@ -0,0 +1,30 @@
+https://bugs.gentoo.org/905770
+https://gitlab.freedesktop.org/accountsservice/accountsservice/-/merge_requests/136
+https://gitlab.freedesktop.org/accountsservice/accountsservice/-/commit/c9c16b3c47e13e90bb2213141f6f309e2d474396
+
+From c9c16b3c47e13e90bb2213141f6f309e2d474396 Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Fri, 5 May 2023 07:43:48 -0700
+Subject: [PATCH] generate-version.sh: fix script inside of a tarball
+
+---
+ generate-version.sh | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/generate-version.sh b/generate-version.sh
+index 3f88bff..8375c86 100755
+--- a/generate-version.sh
++++ b/generate-version.sh
+@@ -4,11 +4,10 @@ exec 3>&2 2> /dev/null
+ SRCDIR=$(dirname "$0")
+ cd "$SRCDIR"
+ CWD=$(realpath "$PWD")
+-TOPLEVEL_WORKING_DIR=$(realpath "$(git rev-parse --show-toplevel)")
+ exec 2>&3
+
+ # If it's not from a git checkout, assume it's from a tarball
+-if [ "$TOPLEVEL_WORKING_DIR" != "$CWD" ]; then
++if ! git rev-parse --is-inside-git-dir > /dev/null 2>&1; then
+ VERSION_FROM_DIR_NAME=$(basename "$CWD" | sed -n 's/^accountsservice-\([^-]*\)$/\1/p')
+
+ if [ -n "$VERSION_FROM_DIR_NAME" ]; then
diff --git a/sys-apps/accountsservice/files/accountsservice-23.13.9-musl-fixes.patch b/sys-apps/accountsservice/files/accountsservice-23.13.9-musl-fixes.patch
new file mode 100644
index 000000000000..abb59a137bfd
--- /dev/null
+++ b/sys-apps/accountsservice/files/accountsservice-23.13.9-musl-fixes.patch
@@ -0,0 +1,52 @@
+From 962a66aa12932c7899cda78c4cbda0f581947285 Mon Sep 17 00:00:00 2001
+From: germ <germtoo@outlook.com>
+Date: Mon, 30 Oct 2023 06:16:16 -0400
+Subject: [PATCH 1/1] This applies two apatches to sys-apps/accountsserice
+ https://gitlab.alpinelinux.org/alpine/aports/-/raw/75528d8dc4206a74501799f6a6042be20b80801d/community/accountsservice/musl-fgetspent_r.patch
+ https://gitlab.alpinelinux.org/alpine/aports/-/raw/75528d8dc4206a74501799f6a6042be20b80801d/community/accountsservice/musl-wtmp.patch
+
+--- a/meson.build
++++ b/meson.build
+@@ -103,8 +103,7 @@ elif cc.has_header_symbol('paths.h', '_PATH_WTMPX')
+
+ config_h.set('PATH_WTMP', '_PATH_WTMPX')
+ else
+- path_wtmp = '/var/log/utx.log'
+- assert(run_command('test', '-e', path_wtmp, check: false).returncode() == 0, 'Do not know which filename to watch for wtmp changes')
++ path_wtmp = '/var/log/wtmp'
+ config_h.set_quoted('PATH_WTMP', path_wtmp)
+ endif
+
+--- a/src/daemon.c
++++ b/src/daemon.c
+@@ -215,6 +215,27 @@ remove_cache_files (const gchar *user_name)
+ g_remove (icon_filename);
+ }
+
++#ifndef __GLIBC__
++/* Musl libc does not support fgetspent_r(), write own
++* wrapper
++*/
++static int fgetspent_r(FILE *fp, struct spwd *spbuf, char *buf, size_t buflen, struct spwd **spbufp) {
++ struct spwd *shadow_entry = fgetspent(fp);
++ if(!shadow_entry)
++ return -1;
++ size_t namplen = strlen(shadow_entry->sp_namp);
++ size_t pwdplen = strlen(shadow_entry->sp_pwdp);
++
++ if(namplen + pwdplen + 2 > buflen)
++ return -1;
++ *spbufp = memcpy(spbuf, shadow_entry, sizeof(struct spwd));
++ spbuf->sp_namp = strncpy(buf, shadow_entry->sp_namp, namplen + 1);
++ spbuf->sp_pwdp = strncpy(buf + namplen + 1, shadow_entry->sp_pwdp, pwdplen + 1);
++
++ return 0;
++}
++#endif
++
+ static struct passwd *
+ entry_generator_fgetpwent (Daemon *daemon,
+ GHashTable *users,
+--
+2.42.0
+
diff --git a/sys-apps/accountsservice/metadata.xml b/sys-apps/accountsservice/metadata.xml
index 35e1d4b2c2bd..a5e0c3471d4e 100644
--- a/sys-apps/accountsservice/metadata.xml
+++ b/sys-apps/accountsservice/metadata.xml
@@ -1,13 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
- <maintainer type="project">
- <email>gnome@gentoo.org</email>
- <name>Gentoo GNOME Desktop</name>
- </maintainer>
- <use>
- <flag name="consolekit">Use <pkg>sys-auth/consolekit</pkg> for session tracking</flag>
- <flag name="elogind">Use <pkg>sys-auth/elogind</pkg> for session tracking</flag>
- <flag name="systemd">Use <pkg>sys-apps/systemd</pkg> for session tracking</flag>
- </use>
+ <maintainer type="project">
+ <email>gnome@gentoo.org</email>
+ <name>Gentoo GNOME Desktop</name>
+ </maintainer>
+ <use>
+ <flag name="elogind">Use <pkg>sys-auth/elogind</pkg> for session tracking</flag>
+ <flag name="systemd">Use <pkg>sys-apps/systemd</pkg> for session tracking</flag>
+ </use>
+ <upstream>
+ <remote-id type="freedesktop-gitlab">accountsservice/accountsservice</remote-id>
+ </upstream>
</pkgmetadata>