From e8eca868dd9a7b389b272b517e5e181175d9668c Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Wed, 5 Aug 2020 15:55:06 -0400 Subject: [PATCH 27/44] gnu: malcontent: Update package definition. * gnu/packages/freedesktop.scm (malcontent): Update package definition. [outputs]: New output "help". [arguments]<#:phases>['skip-gtk-update-icon-cache]: New phase. ['move-help]: New phase. [native-inputs]: Remove gtk+:bin. [inputs]: Remove libostree. Move accountsservice, flatpack, glib and gtk+ to ... [propagated-inputs]: ... here. [license]: Modify. --- gnu/packages/freedesktop.scm | 41 ++++++++++++++++++++++++++---------- 1 file changed, 30 insertions(+), 11 deletions(-) diff --git a/gnu/packages/freedesktop.scm b/gnu/packages/freedesktop.scm index b471a6e46d..2357805125 100644 --- a/gnu/packages/freedesktop.scm +++ b/gnu/packages/freedesktop.scm @@ -151,6 +151,7 @@ tests.") (sha256 (base32 "0vnf0pk516fwwh41v96c29l2i7h1pnwhivlkbf53kkx1q35g7lb3")))) (build-system meson-build-system) + (outputs '("out" "help")) (arguments `(#:glib-or-gtk? #t #:phases @@ -160,28 +161,42 @@ tests.") (lambda _ (substitute* "libmalcontent/tests/app-filter.c" (("g_test_add_func \\(\"/app-filter/appinfo\", test_app_filter_appinfo\\);") - "")) - #t))))) + "")) + #t)) + (add-before 'configure 'skip-gtk-update-icon-cache + (lambda _ + (substitute* "build-aux/meson_post_install.py" + (("gtk-update-icon-cache") + "true")) + #t)) + (add-after 'install 'move-help + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (help (assoc-ref outputs "help"))) + (mkdir-p (string-append help "/share")) + (rename-file + (string-append out "/share/help") + (string-append help "/share/help")) + #t)))))) (native-inputs `(("desktop-file-utils" ,desktop-file-utils) ("gettext" ,gettext-minimal) ("glib:bin" ,glib "bin") ("gobject-introspection" ,gobject-introspection) - ("gtk+:bin" ,gtk+ "bin") ("itstool" ,itstool) ("libglib-testing" ,libglib-testing) - ("libxml2" ,libxml2) - ("pkg-config" ,pkg-config))) + ("pkg-config" ,pkg-config) + ("xmllint" ,libxml2))) (inputs - `(("accountsservice" ,accountsservice) - ("appstream-glib" ,appstream-glib) + `(("appstream-util" ,appstream-glib) ("dbus" ,dbus) - ("flatpak" ,flatpak) - ("glib" ,glib) - ("gtk+" ,gtk+) - ("libostree" ,libostree) ("linux-pam" ,linux-pam) ("polkit" ,polkit))) + (propagated-inputs + `(("accountsservice" ,accountsservice) + ("flatpak" ,flatpak) + ("glib" ,glib) + ("gtk+" ,gtk+))) (synopsis "Parental controls support") (description "MalContent implements parental controls support which can be used by applications to filter or limit the access of child accounts to @@ -189,7 +204,11 @@ inappropriate content.") (home-page "https://gitlab.freedesktop.org/pwithnall/malcontent") (license (list + ;; Documentation + license:cc-by-sa3.0 + ;; Application license:gpl2+ + ;; Library license:lgpl2.1+)))) (define-public xdg-utils -- 2.28.0