Commit 68ef1fdc authored by Olivier Duchateau's avatar Olivier Duchateau
Browse files

Update to 0.6.52

parent adcab7f9
......@@ -2,7 +2,7 @@
# $FreeBSD: head/sysutils/accountsservice/Makefile 517057 2019-11-08 13:11:05Z tobik $
PORTNAME= accountsservice
PORTVERSION= 0.6.50
PORTVERSION= 0.6.52
CATEGORIES= sysutils devel
MASTER_SITES= http://www.freedesktop.org/software/${PORTNAME}/
......@@ -12,30 +12,22 @@ COMMENT= D-Bus interface for user account query and manipulation
LICENSE= GPLv3+
LICENSE_FILE= ${WRKSRC}/COPYING
BUILD_DEPENDS= dbus>0:devel/dbus
LIB_DEPENDS= libpolkit-gobject-1.so:sysutils/polkit
USE_GNOME= glib20 intltool introspection:build libxslt
USES= cpe gettext gmake gnome libtool localbase:ldflags pathfix \
USES= cpe gettext gnome localbase:ldflags meson \
pkgconfig tar:xz
CPE_VENDOR= ray_stode
GNU_CONFIGURE= yes
USE_LDCONFIG= yes
CONFIGURE_ARGS= --disable-systemd \
--disable-elogind \
--without-html-dir \
--without-systemdsystemunitdir \
--with-gdmconffile=${LOCALBASE}/etc/gdm/custom.conf \
--localstatedir=/var/
INSTALL_TARGET= install-strip
# XXX HACK! this file isn't present on the pristine jails of the builders
# and configure breaks without it. Beter solutions welcome.
.if defined(PACKAGE_BUILDING)
CONFIGURE_ENV+= ac_cv_file__var_log_utx_log=yes
.endif
post-patch:
@${REINPLACE_CMD} -e 's|/lib/AccountsService|/db/AccountsService|g' \
${WRKSRC}/src/Makefile.in
MESON_ARGS= -Dsystemdsystemunitdir=no \
-Dgdmconffile=${LOCALBASE}/etc/gdm/custom.conf \
-Dsystemd=false \
-Delogind=false \
-Dlocalstatedir=/var
#post-patch:
# @${REINPLACE_CMD} -e 's|/lib/AccountsService|/db/AccountsService|g' \
# ${WRKSRC}/src/Makefile.in
.include <bsd.port.mk>
TIMESTAMP = 1600439523
SHA256 (accountsservice-0.6.50.tar.xz) = 035928f5dea46f2220657e0bd669bc7fac45165b700c0a81b2b66ff2c3dbc74a
SIZE (accountsservice-0.6.50.tar.xz) = 384484
TIMESTAMP = 1600451786
SHA256 (accountsservice-0.6.52.tar.xz) = 2b395c143bc1a4e0b99cf9378f895c2357b597db309d1293340eb3719115c303
SIZE (accountsservice-0.6.52.tar.xz) = 93000
--- configure.orig 2014-03-15 15:02:28.000000000 +0100
+++ configure 2014-03-15 15:03:01.000000000 +0100
@@ -14527,6 +14527,18 @@
done
+for ac_func in fgetpwent
+do :
+ ac_fn_c_check_func "$LINENO" "fgetpwent" "ac_cv_func_fgetpwent"
+if test "x$ac_cv_func_fgetpwent" = xyes; then :
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_FGETPWENT 1
+_ACEOF
+
+fi
+done
+
+
--- meson.build.orig 2018-09-26 13:20:49 UTC
+++ meson.build
@@ -82,8 +82,11 @@ if cc.has_header_symbol('utmpx.h', 'WTMPX_FILENAME', p
elif cc.has_header_symbol('paths.h', '_PATH_WTMPX')
config_h.set('PATH_WTMP', '_PATH_WTMPX')
else
- assert(run_command('test', '-e', '/var/log/utx.log').returncode() == 0, 'Do not know which filename to watch for wtmp changes')
- config_h.set('PATH_WTMP', '/var/log/utx.log')
+ _system = host_machine.system().to_lower()
+ if _system.contains('freebsd')
+ # Ugly fix, for jails builders!
+ config_h.set_quoted('PATH_WTMP', '/var/log/utx.log')
+ endif
endif
# compiler flags
--- meson_post_install.py.orig 2018-09-26 13:20:49 UTC
+++ meson_post_install.py
@@ -9,8 +9,8 @@ localstatedir = os.path.normpath(destdir + os.sep + sy
# FIXME: meson will not track the creation of these directories
# https://github.com/mesonbuild/meson/blob/master/mesonbuild/scripts/uninstall.py#L39
dst_dirs = [
- os.path.join(localstatedir, 'lib', 'AccountsService', 'icons'),
- os.path.join(localstatedir, 'lib', 'AccountsService', 'users'),
+ os.path.join(localstatedir, 'db', 'AccountsService', 'icons'),
+ os.path.join(localstatedir, 'db', 'AccountsService', 'users'),
]
for dst_dir in dst_dirs:
--- src/daemon.c.orig 2018-06-13 16:39:06 UTC
--- src/daemon.c.orig 2018-09-26 13:20:49 UTC
+++ src/daemon.c
@@ -79,7 +79,11 @@ struct DaemonPrivate {
@@ -79,7 +79,11 @@ typedef struct {
GHashTable *extension_ifaces;
};
} DaemonPrivate;
+#ifdef HAVE_SHADOW_H
typedef struct passwd * (* EntryGeneratorFunc) (Daemon *, GHashTable *, gpointer *, struct spwd **shadow_entry);
......@@ -12,7 +12,7 @@
static void daemon_accounts_accounts_iface_init (AccountsAccountsIface *iface);
@@ -156,17 +160,25 @@ remove_cache_files (const gchar *user_name)
@@ -154,17 +158,25 @@ remove_cache_files (const gchar *user_name)
}
static struct passwd *
......@@ -38,7 +38,7 @@
struct {
FILE *fp;
@@ -177,6 +189,7 @@ entry_generator_fgetpwent (Daemon *daemon,
@@ -175,6 +187,7 @@ entry_generator_fgetpwent (Daemon *daemon,
if (*state == NULL) {
GHashTable *shadow_users = NULL;
FILE *fp;
......@@ -46,7 +46,7 @@
struct spwd *shadow_entry;
fp = fopen (PATH_SHADOW, "r");
@@ -210,6 +223,7 @@ entry_generator_fgetpwent (Daemon *daemon,
@@ -208,6 +221,7 @@ entry_generator_fgetpwent (Daemon *daemon,
g_clear_pointer (&shadow_users, g_hash_table_unref);
return NULL;
}
......@@ -54,7 +54,7 @@
fp = fopen (PATH_PASSWD, "r");
if (fp == NULL) {
@@ -231,12 +245,17 @@ entry_generator_fgetpwent (Daemon *daemon,
@@ -229,12 +243,17 @@ entry_generator_fgetpwent (Daemon *daemon,
if (g_hash_table_size (users) < MAX_LOCAL_USERS) {
pwent = fgetpwent (generator_state->fp);
if (pwent != NULL) {
......@@ -72,7 +72,7 @@
}
}
@@ -250,10 +269,16 @@ entry_generator_fgetpwent (Daemon *daemon,
@@ -248,10 +267,16 @@ entry_generator_fgetpwent (Daemon *daemon,
}
static struct passwd *
......@@ -89,7 +89,7 @@
{
struct passwd *pwent;
g_autoptr(GError) error = NULL;
@@ -296,7 +321,9 @@ entry_generator_cachedir (Daemon *daemon,
@@ -293,7 +318,9 @@ entry_generator_cachedir (Daemon *daemon,
errno = 0;
pwent = getpwnam (name);
if (pwent != NULL) {
......@@ -99,7 +99,7 @@
return pwent;
} else if (errno == 0) {
@@ -330,10 +357,16 @@ entry_generator_cachedir (Daemon *daemon,
@@ -329,10 +356,16 @@ entry_generator_cachedir (Daemon *daemon,
}
static struct passwd *
......@@ -114,8 +114,8 @@
+ gpointer *state)
+#endif
{
DaemonPrivate *priv = daemon_get_instance_private (daemon);
struct passwd *pwent;
GList *node;
@@ -360,7 +393,9 @@ entry_generator_requested_users (Daemon *daemon,
if (pwent == NULL) {
g_debug ("user '%s' requested previously but not present on system", name);
......@@ -126,8 +126,8 @@
return pwent;
}
@@ -382,19 +417,29 @@ load_entries (Daemon *daemon,
{
@@ -383,19 +418,29 @@ load_entries (Daemon *daemon,
DaemonPrivate *priv = daemon_get_instance_private (daemon);
gpointer generator_state = NULL;
struct passwd *pwent;
+#ifdef HAVE_SHADOW_H
......@@ -156,7 +156,7 @@
g_debug ("skipping user: %s", pwent->pw_name);
continue;
}
@@ -416,7 +461,11 @@ load_entries (Daemon *daemon,
@@ -417,7 +462,11 @@ load_entries (Daemon *daemon,
/* freeze & update users not already in the new list */
g_object_freeze_notify (G_OBJECT (user));
......@@ -168,7 +168,7 @@
g_hash_table_insert (users, g_strdup (user_get_user_name (user)), user);
g_debug ("loaded user: %s", user_get_user_name (user));
@@ -807,14 +856,23 @@ throw_error (GDBusMethodInvocation *context,
@@ -823,15 +872,24 @@ throw_error (GDBusMethodInvocation *context,
}
static User *
......@@ -181,6 +181,7 @@
+ struct passwd *pwent)
+#endif
{
DaemonPrivate *priv = daemon_get_instance_private (daemon);
User *user;
user = user_new (daemon, pwent->pw_uid);
......@@ -191,9 +192,9 @@
+#endif
user_register (user);
g_hash_table_insert (daemon->priv->users,
@@ -842,9 +900,13 @@ daemon_local_find_user_by_id (Daemon *daemon,
user = g_hash_table_lookup (daemon->priv->users, pwent->pw_name);
g_hash_table_insert (priv->users,
@@ -860,9 +918,13 @@ daemon_local_find_user_by_id (Daemon *daemon,
user = g_hash_table_lookup (priv->users, pwent->pw_name);
if (user == NULL) {
+#ifdef HAVE_SHADOW_H
......@@ -204,10 +205,10 @@
+ user = add_new_user_for_pwent (daemon, pwent);
+#endif
daemon->priv->explicitly_requested_users = g_list_append (daemon->priv->explicitly_requested_users,
g_strdup (pwent->pw_name));
@@ -869,9 +931,13 @@ daemon_local_find_user_by_name (Daemon *daemon,
user = g_hash_table_lookup (daemon->priv->users, pwent->pw_name);
priv->explicitly_requested_users = g_list_append (priv->explicitly_requested_users,
g_strdup (pwent->pw_name));
@@ -888,9 +950,13 @@ daemon_local_find_user_by_name (Daemon *daemon,
user = g_hash_table_lookup (priv->users, pwent->pw_name);
if (user == NULL) {
+#ifdef HAVE_SHADOW_H
......@@ -218,9 +219,9 @@
+ user = add_new_user_for_pwent (daemon, pwent);
+#endif
daemon->priv->explicitly_requested_users = g_list_append (daemon->priv->explicitly_requested_users,
g_strdup (pwent->pw_name));
@@ -1071,10 +1137,12 @@ daemon_create_user_authorized_cb (Daemon
priv->explicitly_requested_users = g_list_append (priv->explicitly_requested_users,
g_strdup (pwent->pw_name));
@@ -1095,10 +1161,12 @@ daemon_create_user_authorized_cb (Daemon
sys_log (context, "create user '%s'", cd->user_name);
......@@ -237,7 +238,7 @@
if (cd->account_type == ACCOUNT_TYPE_ADMINISTRATOR) {
if (EXTRA_ADMIN_GROUPS != NULL && EXTRA_ADMIN_GROUPS[0] != '\0')
admin_groups = g_strconcat (ADMIN_GROUP, ",",
@@ -1082,15 +1150,11 @@ daemon_create_user_authorized_cb (Daemon
@@ -1106,15 +1174,11 @@ daemon_create_user_authorized_cb (Daemon
else
admin_groups = g_strdup (ADMIN_GROUP);
......@@ -255,7 +256,7 @@
argv[6] = NULL;
}
else {
@@ -1255,7 +1319,7 @@ daemon_delete_user_authorized_cb (Daemon
@@ -1281,7 +1345,7 @@ daemon_delete_user_authorized_cb (Daemon
DeleteUserData *ud = data;
g_autoptr(GError) error = NULL;
struct passwd *pwent;
......@@ -264,9 +265,9 @@
User *user;
pwent = getpwuid (ud->uid);
@@ -1279,19 +1343,16 @@ daemon_delete_user_authorized_cb (Daemon
@@ -1307,19 +1371,16 @@ daemon_delete_user_authorized_cb (Daemon
remove_cache_files (pwent->pw_name);
user_set_saved (user, FALSE);
- argv[0] = "/usr/sbin/userdel";
+ argv[0] = "/usr/sbin/pw";
......
--- src/meson.build.orig 2018-09-26 13:20:49 UTC
+++ src/meson.build
@@ -26,8 +26,8 @@ deps = [
cflags = [
'-DLOCALSTATEDIR="@0@"'.format(act_localstatedir),
'-DDATADIR="@0@"'.format(act_datadir),
- '-DICONDIR="@0@"'.format(join_paths(act_localstatedir, 'lib', meson.project_name(), 'icons')),
- '-DUSERDIR="@0@"'.format(join_paths(act_localstatedir, 'lib', meson.project_name(), 'users')),
+ '-DICONDIR="@0@"'.format(join_paths(act_localstatedir, 'db/AccountsService', 'icons')),
+ '-DUSERDIR="@0@"'.format(join_paths(act_localstatedir, 'db/AccountsService', 'users')),
]
libaccounts_generated = static_library(
......@@ -3,8 +3,7 @@ include/accountsservice-1.0/act/act-user-enum-types.h
include/accountsservice-1.0/act/act-user-manager.h
include/accountsservice-1.0/act/act-user.h
include/accountsservice-1.0/act/act.h
lib/girepository-1.0/AccountsService-1.0.typelib
lib/libaccountsservice.a
lib/girepository-1.0/accountsservice-1.0.typelib
lib/libaccountsservice.so
lib/libaccountsservice.so.0
lib/libaccountsservice.so.0.0.0
......@@ -13,7 +12,7 @@ libexec/accounts-daemon
share/dbus-1/interfaces/org.freedesktop.Accounts.User.xml
share/dbus-1/interfaces/org.freedesktop.Accounts.xml
share/dbus-1/system-services/org.freedesktop.Accounts.service
share/gir-1.0/AccountsService-1.0.gir
share/gir-1.0/accountsservice-1.0.gir
share/locale/ar/LC_MESSAGES/accounts-service.mo
share/locale/bg/LC_MESSAGES/accounts-service.mo
share/locale/bn_IN/LC_MESSAGES/accounts-service.mo
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment