added my Recipes
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
From ff0718174faf1167fb4765ebe4bd280bbe8d2ac6 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
|
||||
Date: Sun, 8 Dec 2019 23:42:00 +0100
|
||||
Subject: [PATCH] musl: Hack to fix configure
|
||||
|
||||
Upstream-Status: Inappropriate [Musl Specific]
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
---
|
||||
meson.build | 11 ++++++++---
|
||||
1 file changed, 8 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index 075776f..dfd7421 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -101,9 +101,14 @@ 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).returncode() == 0, 'Do not know which filename to watch for wtmp changes')
|
||||
- config_h.set_quoted('PATH_WTMP', path_wtmp)
|
||||
+ # musl: This is just a build fix hack.
|
||||
+ # As usual they know better, consider all other projects crap and offer zero
|
||||
+ # alternatives: So wtmp is a dead stub only [1] (= /dev/null/wtmp - taken
|
||||
+ # from musl sources).
|
||||
+ # Maybe a hero comes along and adds utmps [2] to make accountsservice useful for musl
|
||||
+ # [1] https://wiki.musl-libc.org/faq.html#Q:-Why-is-the-utmp/wtmp-functionality-only-implemented-as-stubs?
|
||||
+ # [2] https://github.com/skarnet/utmps
|
||||
+ config_h.set_quoted('PATH_WTMP', '/dev/null/wtmp')
|
||||
endif
|
||||
|
||||
# compiler flags
|
||||
--
|
||||
2.34.1
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
From 7401e682400df87f3258f795bb1d143f64a35a9f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
|
||||
Date: Mon, 9 Dec 2019 00:12:08 +0100
|
||||
Subject: [PATCH] musl: add missing fgetspent_r
|
||||
|
||||
Stolen from void-linux
|
||||
|
||||
Upstream-Status: Inappropriate [musl-specific]
|
||||
|
||||
---
|
||||
src/daemon.c | 20 ++++++++++++++++++++
|
||||
1 file changed, 20 insertions(+)
|
||||
|
||||
diff --git a/src/daemon.c b/src/daemon.c
|
||||
index c52bda3..a7676fe 100644
|
||||
--- a/src/daemon.c
|
||||
+++ b/src/daemon.c
|
||||
@@ -164,6 +164,26 @@ remove_cache_files (const gchar *user_name)
|
||||
g_remove (icon_filename);
|
||||
}
|
||||
|
||||
+/* 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;
|
||||
+}
|
||||
+
|
||||
static struct passwd *
|
||||
entry_generator_fgetpwent (Daemon *daemon,
|
||||
GHashTable *users,
|
||||
@@ -0,0 +1,32 @@
|
||||
DESCRIPTION = "D-Bus interfaces for querying and manipulating user account information"
|
||||
HOMEPAGE = "https://www.freedesktop.org/wiki/Software/AccountsService/"
|
||||
LICENSE = "GPL-3.0-only"
|
||||
LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
|
||||
|
||||
DEPENDS = " \
|
||||
dbus \
|
||||
polkit \
|
||||
"
|
||||
|
||||
inherit meson gobject-introspection gtk-doc features_check systemd vala
|
||||
|
||||
REQUIRED_DISTRO_FEATURES = "polkit"
|
||||
|
||||
SRC_URI = "https://www.freedesktop.org/software/${BPN}/${BPN}-${PV}.tar.xz"
|
||||
SRC_URI:append:libc-musl = " \
|
||||
file://0001-musl-Hack-to-fix-build.patch \
|
||||
file://0002-musl-add-missing-fgetspent_r.patch \
|
||||
"
|
||||
SRC_URI[sha256sum] = "909997a76919fe7dc138a9a01cea70bd622d5a932dbc9fb13010113023a7a391"
|
||||
|
||||
GTKDOC_MESON_OPTION = "gtk_doc"
|
||||
|
||||
PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
|
||||
PACKAGECONFIG[systemd] = ", -Dsystemdsystemunitdir='no', systemd"
|
||||
|
||||
SYSTEMD_SERVICE:${PN} = "accounts-daemon.service"
|
||||
|
||||
FILES:${PN} += " \
|
||||
${datadir}/dbus-1 \
|
||||
${datadir}/polkit-1 \
|
||||
"
|
||||
Reference in New Issue
Block a user