From 855797d1a637f342c43ac663e07c8bdcd642607b Mon Sep 17 00:00:00 2001 From: Ryan Prior Date: Fri, 15 May 2020 14:56:34 -0500 Subject: [PATCH 2/6] gnu: Add sideload. * gnu/packages/pantheon.scm (sideload): New variable. --- gnu/packages/pantheon.scm | 57 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) diff --git a/gnu/packages/pantheon.scm b/gnu/packages/pantheon.scm index 834ea74f37..a5ee6fafce 100644 --- a/gnu/packages/pantheon.scm +++ b/gnu/packages/pantheon.scm @@ -17,11 +17,15 @@ ;;; along with GNU Guix. If not, see . (define-module (gnu packages pantheon) + #:use-module (gnu packages cmake) + #:use-module (gnu packages freedesktop) #:use-module (gnu packages gettext) #:use-module (gnu packages glib) #:use-module (gnu packages gnome) #:use-module (gnu packages gtk) + #:use-module (gnu packages package-management) #:use-module (gnu packages pkg-config) + #:use-module (gnu packages xml) #:use-module (gnu packages) #:use-module (guix build-system meson) #:use-module (guix git-download) @@ -59,3 +63,56 @@ things, it provides complex widgets and convenience functions designed for use in apps built for the Pantheon desktop.") (license license:lgpl3+))) + +(define-public sideload + (package + (name "sideload") + (version "1.1.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/elementary/sideload.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1nnaq4vc0aag6pckxhrma5qv8al7i00rrlg95ac4iqqmivja7i92")))) + (build-system meson-build-system) + (arguments + `(#:glib-or-gtk? #t + #:configure-flags (list (string-append "-Dflatpak=" + (assoc-ref %build-inputs "flatpak") + "/include")) + #:phases + (modify-phases %standard-phases + (add-after 'install 'install-symlinks + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin/io.elementary.sideload")) + (link (string-append out "/bin/sideload"))) + (symlink bin link))))))) + (inputs + `(("flatpak" ,flatpak) + ("granite" ,granite) + ("gtk" ,gtk+) + ("libostree" ,libostree))) + (propagated-inputs + `(("glib-networking" ,glib-networking))) + (native-inputs + `(("cmake" ,cmake) + ("desktop-file-utils" ,desktop-file-utils) ; for update-desktop-database + ("gettext" ,gettext-minimal) + ("glib" ,glib) + ("glib:bin" ,glib "bin") + ("gobject-introspection" ,gobject-introspection) + ("libgee" ,libgee) + ("libxml2" ,libxml2) + ("pkg-config" ,pkg-config) + ("vala" ,vala))) + (home-page "https://github.com/elementary/sideload") + (synopsis "Graphical application to side-load Flatpaks") + (description "Sideload handles flatpakref files, like those you might find +on Flathub or another third-party website providing a Flatpak app for +download.") + (license license:gpl3))) -- 2.17.1