From c41cbdf2de156d3b75e758c32da89aa6e68fdc66 Mon Sep 17 00:00:00 2001 From: Hihin Ruslan Date: Sat, 14 May 2022 12:10:56 +0300 Subject: [PATCH] New file: lightdm-webkit2-greeter.conf --- .gear/rules | 1 + lightdm-webkit2-greeter-3.4.1-opt.patch | 11 ++++++++ lightdm-webkit2-greeter.conf | 35 +++++++++++++++++++++++++ lightdm-webkit2-greeter.spec | 19 +++++++++++--- 4 files changed, 63 insertions(+), 3 deletions(-) create mode 100644 lightdm-webkit2-greeter-3.4.1-opt.patch create mode 100644 lightdm-webkit2-greeter.conf diff --git a/.gear/rules b/.gear/rules index 8729190..de20ae5 100644 --- a/.gear/rules +++ b/.gear/rules @@ -1,2 +1,3 @@ tar: @version@:. copy: *.patch +copy: *.conf diff --git a/lightdm-webkit2-greeter-3.4.1-opt.patch b/lightdm-webkit2-greeter-3.4.1-opt.patch new file mode 100644 index 0000000..4e78b6c --- /dev/null +++ b/lightdm-webkit2-greeter-3.4.1-opt.patch @@ -0,0 +1,11 @@ +diff -uNrBbwp lightdm-webkit2-greeter-3.4.1/dist/web-greeter.desktop lightdm-webkit2-greeter-3.4.1-new/dist/web-greeter.desktop +--- lightdm-webkit2-greeter-3.4.1/dist/web-greeter.desktop 2022-04-11 22:18:38.000000000 +0000 ++++ lightdm-webkit2-greeter-3.4.1-new/dist/web-greeter.desktop 2022-05-14 10:38:14.893467344 +0000 +@@ -1,6 +1,6 @@ + [Desktop Entry] + Name=web-greeter +-Exec=/opt/web-greeter/web-greeter %U ++Exec=/usr/bin/web-greeter %U + Terminal=false + Type=Application + StartupWMClass=web-greeter diff --git a/lightdm-webkit2-greeter.conf b/lightdm-webkit2-greeter.conf new file mode 100644 index 0000000..88c2a0a --- /dev/null +++ b/lightdm-webkit2-greeter.conf @@ -0,0 +1,35 @@ +# +# [greeter] +# debug_mode = Greeter theme debug mode. +# detect_theme_errors = Provide an option to load a fallback theme when theme errors are detected. +# screensaver_timeout = Blank the screen after this many seconds of inactivity. +# secure_mode = Don't allow themes to make remote http requests. +# time_format = A moment.js format string so the greeter can generate localized time for display. +# time_language = Language to use when displaying the time or "auto" to use the system's language. +# webkit_theme = Webkit theme to use. +# +# NOTE: See moment.js documentation for format string options: http://momentjs.com/docs/#/displaying/format/ +# + +[greeter] +debug_mode = false +detect_theme_errors = true +screensaver_timeout = 300 +secure_mode = true +time_format = LT +time_language = auto +webkit_theme = antergos + +# +# [branding] +# background_images = Path to directory that contains background images for use by themes. +# logo = Path to logo image for use by greeter themes. +# user_image = Default user image/avatar. This is used by themes for users that have no .face image. +# +# NOTE: Paths must be accessible to the lightdm system user account (so they cannot be anywhere in /home) +# + +[branding] +background_images = /usr/share/backgrounds +#logo = /usr/share/lightdm-webkit/themes/antergos/img/antergos.png +#user_image = /usr/share/lightdm-webkit/themes/antergos/img/antergos-logo-user.png diff --git a/lightdm-webkit2-greeter.spec b/lightdm-webkit2-greeter.spec index f9d2273..579b5a5 100644 --- a/lightdm-webkit2-greeter.spec +++ b/lightdm-webkit2-greeter.spec @@ -12,15 +12,19 @@ Packager: Hihin Ruslan ExcludeArch: ppc64le Source: %name-%version.tar +Source1: %name.conf Patch: lightdm-webkit2-greeter-3.4.1-makefile.patch Patch1: lightdm-webkit2-greeter-3.4.1-basedir.patch +Patch2: lightdm-webkit2-greeter-3.4.1-opt.patch +%add_python3_path %_libdir/web-greeter/bridge/__init__.py +%add_python3_path %_bindir/web-greeter + %add_findprov_skiplist %_libdir/web-greeter/*.py %add_findreq_skiplist %_libdir/web-greeter/*.py -%add_python3_path %_libdir/web-greeter/bridge/__init__.py BuildRequires(pre): rpm-build-python3 @@ -36,6 +40,8 @@ BuildRequires: bash-completion zsh-completions BuildRequires: /usr/bin/python3 +Requires: python3-module-ruamel-yaml python3-module-PyQt5 python3-module-PyQtWebEngin python3-module-pygobject3 liblightdm-gobject + %description A modern, visually appealing greeter for LightDM, that allows to create web based themes with HTML, CSS and JavaScript. This is a fork of the Antergos web-greeter that tries to fix and improve this project for a modern and current use. Due to this, some API changes are needed, which implies that current themes would need to do changes to work correctly. @@ -46,10 +52,13 @@ Also, check out nody-greeter, a greeter made in Node.js with Electron! (Actually %make clean %patch -p1 %patch1 -p1 +%patch2 -p1 + subst 's,\,%_lib,g' Makefile + %build #configure %make @@ -57,14 +66,18 @@ subst 's,\,%_lib,g' Makefile %install %makeinstall_std +install -m 644 %SOURCE1 %buildroot%_sysconfdir/lightdm/ #check #make check %files + +%config(noreplace) %_sysconfdir/lightdm/%name.conf + %_sysconfdir/lightdm/Xgreeter %_sysconfdir/lightdm/web-greeter.yml -%_sysconfdir/xdg/lightdm/lightdm.conf.d/90-greeter-wrapper.conf +%config(noreplace) %_sysconfdir/xdg/lightdm/lightdm.conf.d/90-greeter-wrapper.conf %_bindir/web-greeter @@ -75,7 +88,7 @@ subst 's,\,%_lib,g' Makefile %_datadir/bash-completion/* %_datadir/metainfo/* %_datadir/web-greeter/* -%_datadir/xgreeters +%_datadir/xgreeters/* %_datadir/zsh/site-functions/* %_docdir/web-greeter/*