gnu: libretro-lowresnx: Update to 1.2.
[jackhill/guix/guix.git] / gnu / packages / nicotine.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2020 Martin Becze <mjbecze@riseup.net>
3 ;;;
4 ;;; This file is part of GNU Guix.
5 ;;;
6 ;;; GNU Guix is free software; you can redistribute it and/or modify it
7 ;;; under the terms of the GNU General Public License as published by
8 ;;; the Free Software Foundation; either version 3 of the License, or (at
9 ;;; your option) any later version.
10 ;;;
11 ;;; GNU Guix is distributed in the hope that it will be useful, but
12 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
13 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 ;;; GNU General Public License for more details.
15 ;;;
16 ;;; You should have received a copy of the GNU General Public License
17 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
18
19 (define-module (gnu packages nicotine)
20 #:use-module ((guix licenses) #:prefix license:)
21 #:use-module (guix packages)
22 #:use-module (guix git-download)
23 #:use-module (guix build-system python)
24 #:use-module (gnu packages glib)
25 #:use-module (gnu packages gettext)
26 #:use-module (gnu packages gtk)
27 #:use-module (gnu packages check)
28 #:use-module (gnu packages mp3))
29
30 (define-public nicotine+
31 (package
32 (name "nicotine+")
33 (version "2.1.2")
34 (source (origin
35 (method git-fetch)
36 (uri (git-reference
37 (url "https://github.com/Nicotine-Plus/nicotine-plus")
38 (commit version)))
39 (file-name (git-file-name name version))
40 (sha256 (base32 "18rra8yqjr10z23chzcp53ncbd5fhm0iqgqxpbxfq7a10za02v6l"))))
41 (build-system python-build-system)
42 (arguments
43 `(#:imported-modules ((guix build glib-or-gtk-build-system)
44 ,@%python-build-system-modules)
45 #:modules
46 ((guix build utils)
47 (guix build python-build-system)
48 ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:))
49 #:phases
50 (modify-phases %standard-phases
51 (add-after 'install 'wrap-program
52 (lambda* (#:key outputs #:allow-other-keys)
53 (let ((prog (string-append
54 (assoc-ref outputs "out")
55 "/bin/nicotine"))
56 (gi-typelib-path (getenv "GI_TYPELIB_PATH")))
57 (wrap-program prog
58 `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path)))
59 #t)))
60 (add-after 'wrap-program 'glib-or-gtk-wrap
61 (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))
62 (add-after 'glib-or-gtk-wrap 'glib-or-gtk-compile-schemas
63 (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-compile-schemas)))))
64 (inputs
65 `(("gtk+" ,gtk+)
66 ("python-pygobject" ,python-pygobject)
67 ("python-pytaglib" ,python-pytaglib)))
68 (native-inputs
69 `(("python-pytest" ,python-pytest)
70 ("gettext" ,gettext-minimal)))
71 (home-page "https://nicotine-plus.github.io/nicotine-plus/")
72 (synopsis "Graphical client for Soulseek")
73 (description
74 "Nicotine+ is a graphical client for the Soulseek peer-to-peer
75 file sharing network. It is an attempt to keep Nicotine working with
76 the latest libraries, kill bugs, keep current with the Soulseek protocol,
77 and add some new features that users want and/or need.")
78 (license license:gpl3+)))