Commit | Line | Data |
---|---|---|
a9f847ad | 1 | ;;; GNU Guix --- Functional package management for GNU |
6bd561b8 | 2 | ;;; Copyright © 2019, 2020 Pierre Langlois <pierre.langlois@gmx.com> |
a9f847ad PL |
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 gpodder) | |
20 | #:use-module (guix download) | |
de5ea7d9 | 21 | #:use-module (guix git-download) |
a9f847ad PL |
22 | #:use-module (guix packages) |
23 | #:use-module ((guix licenses) #:prefix license:) | |
24 | #:use-module (guix build-system cmake) | |
8f2b7077 | 25 | #:use-module (guix build-system python) |
a9f847ad | 26 | #:use-module (gnu packages) |
8f2b7077 | 27 | #:use-module (gnu packages check) |
de5ea7d9 PL |
28 | #:use-module (gnu packages freedesktop) |
29 | #:use-module (gnu packages glib) | |
30 | #:use-module (gnu packages gtk) | |
a9f847ad | 31 | #:use-module (gnu packages pkg-config) |
de5ea7d9 PL |
32 | #:use-module (gnu packages python-web) |
33 | #:use-module (gnu packages python-xyz) | |
569832df PL |
34 | #:use-module (gnu packages qt) |
35 | #:use-module (gnu packages video)) | |
a9f847ad | 36 | |
de5ea7d9 PL |
37 | (define-public gpodder |
38 | (package | |
39 | (name "gpodder") | |
6bd561b8 | 40 | (version "3.10.13") |
de5ea7d9 PL |
41 | (source |
42 | (origin | |
43 | (method git-fetch) | |
44 | (uri (git-reference | |
45 | (url "https://github.com/gpodder/gpodder.git") | |
46 | (commit version))) | |
47 | (sha256 | |
48 | (base32 | |
6bd561b8 | 49 | "1h542syaxsx1hslfzlk3fx1nbp190zjw35kigw7a1kx1jwvfwapg")) |
de5ea7d9 PL |
50 | (file-name (git-file-name name version)))) |
51 | (build-system python-build-system) | |
52 | (native-inputs | |
53 | `(("intltool" ,intltool))) | |
54 | (inputs | |
55 | `(("gtk+" ,gtk+) | |
56 | ("python-pygobject" ,python-pygobject) | |
57 | ("python-pycairo" ,python-pycairo) | |
58 | ("python-dbus" ,python-dbus) | |
59 | ("python-html5lib" ,python-html5lib) | |
60 | ("python-mygpoclient" ,python-mygpoclient) | |
61 | ("python-podcastparser" ,python-podcastparser) | |
569832df | 62 | ("youtube-dl" ,youtube-dl) |
de5ea7d9 PL |
63 | ("xdg-utils" ,xdg-utils))) |
64 | (arguments | |
65 | '(#:phases | |
66 | (modify-phases %standard-phases | |
67 | ;; Avoid needing xdg-utils as a propagated input. | |
68 | (add-after 'unpack 'patch-xdg-open | |
69 | (lambda* (#:key inputs #:allow-other-keys) | |
70 | (let ((xdg-utils (assoc-ref inputs "xdg-utils"))) | |
71 | (substitute* "src/gpodder/util.py" | |
72 | (("xdg-open") (string-append xdg-utils "/bin/xdg-open"))) | |
73 | #t))) | |
7a352f76 PL |
74 | ;; 'msgmerge' introduces non-determinism by resetting the |
75 | ;; POT-Creation-Date in .po files. | |
76 | (add-before 'install 'do-not-run-msgmerge | |
77 | (lambda _ | |
78 | (substitute* "makefile" | |
79 | (("msgmerge") "true")) | |
80 | #t)) | |
de5ea7d9 PL |
81 | (add-before 'install 'make-po-files-writable |
82 | (lambda _ | |
83 | (for-each | |
84 | (lambda (f) | |
85 | (chmod f #o664)) | |
e22edabb EF |
86 | (find-files "po")) |
87 | #t)) | |
de5ea7d9 PL |
88 | (replace 'install |
89 | (lambda* (#:key outputs #:allow-other-keys) | |
90 | (setenv "PREFIX" (assoc-ref outputs "out")) | |
e22edabb | 91 | (invoke "make" "install"))) |
de5ea7d9 PL |
92 | (add-after 'install 'wrap-gpodder |
93 | (lambda* (#:key outputs #:allow-other-keys) | |
94 | (let ((out (assoc-ref outputs "out")) | |
95 | (gi-typelib-path (getenv "GI_TYPELIB_PATH"))) | |
96 | (wrap-program (string-append out "/bin/gpodder") | |
97 | `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))) | |
98 | #t)))))) | |
99 | (home-page "https://gpodder.github.io") | |
100 | (synopsis "Simple podcast client") | |
101 | (description "gPodder is a podcatcher, i.e. an application that allows | |
102 | podcast feeds (RSS, Atom, Youtube, Soundcloud, Vimeo and XSPF) to be | |
103 | subscribed to, checks for new episodes and allows the podcast to be saved | |
104 | locally for later listening.") | |
105 | (license license:gpl3+))) | |
106 | ||
a9f847ad PL |
107 | (define-public libmygpo-qt |
108 | (package | |
109 | (name "libmygpo-qt") | |
110 | (version "1.1.0") | |
111 | (source (origin | |
112 | (method url-fetch) | |
113 | (uri (string-append "http://stefan.derkits.at/files/" | |
114 | "libmygpo-qt/libmygpo-qt." version ".tar.gz")) | |
115 | (sha256 | |
116 | (base32 | |
117 | "1kg18qrq2rsswgzhl65r3mlyx7kpqg4wwnbp4yiv6svvmadmlxl2")) | |
118 | (patches (search-patches "libmygpo-qt-fix-qt-5.11.patch" | |
119 | "libmygpo-qt-missing-qt5-modules.patch")))) | |
120 | (build-system cmake-build-system) | |
121 | (native-inputs | |
122 | `(("pkg-config" ,pkg-config))) | |
123 | (inputs | |
124 | `(("qt" ,qtbase))) | |
125 | (arguments | |
126 | `(#:configure-flags '("-DMYGPO_BUILD_TESTS=ON") | |
127 | ;; TODO: Enable tests when https://github.com/gpodder/gpodder/issues/446 | |
128 | ;; is fixed. | |
129 | #:tests? #f)) | |
130 | (home-page "http://wiki.gpodder.org/wiki/Libmygpo-qt") | |
131 | (synopsis "Qt/C++ library wrapping the gpodder web service") | |
132 | (description "@code{libmygpo-qt} is a Qt/C++ library wrapping the | |
133 | @url{https://gpodder.net} APIs. It allows applications to discover, manage | |
134 | and track podcasts.") | |
135 | (license license:lgpl2.1+))) | |
8f2b7077 | 136 | |
b58ab159 PL |
137 | (define-public python-mygpoclient |
138 | (package | |
139 | (name "python-mygpoclient") | |
140 | (version "1.8") | |
141 | (source | |
142 | (origin | |
143 | (method url-fetch) | |
144 | (uri (pypi-uri "mygpoclient" version)) | |
145 | (sha256 | |
146 | (base32 | |
147 | "1fi5x6k1mngr0iviw2s4n1f3y2x7pwqy5ivkcrjdprzvwr37f0mh")))) | |
148 | (build-system python-build-system) | |
149 | (native-inputs | |
150 | `(("python-coverage" ,python-coverage) | |
151 | ("python-minimock" ,python-minimock) | |
152 | ("python-nose" ,python-nose))) | |
153 | (arguments | |
154 | `(#:phases | |
155 | (modify-phases %standard-phases | |
156 | (replace 'check | |
157 | (lambda _ | |
158 | (invoke "make" "test")))))) | |
159 | (home-page "https://mygpoclient.readthedocs.io") | |
160 | (synopsis "Python library for the gPodder web service") | |
161 | (description "@code{mygpoclient} provides an easy and structured way to | |
162 | access the @url{https://gpodder.net} web services. In addition to | |
163 | subscription list synchronization and storage, the API supports uploading and | |
164 | downloading episode status changes.") | |
165 | (license license:gpl3+))) | |
166 | ||
8f2b7077 PL |
167 | (define-public python-podcastparser |
168 | (package | |
169 | (name "python-podcastparser") | |
170 | (version "0.6.4") | |
171 | (source | |
172 | (origin | |
173 | (method url-fetch) | |
174 | (uri (pypi-uri "podcastparser" version)) | |
175 | (sha256 | |
176 | (base32 | |
177 | "1ksj1gcmbnm5i43xhpqxbs2mqi6xzawwwkwbh9h6lwa1wxxvv247")))) | |
178 | (native-inputs | |
179 | `(("python-nose" ,python-nose))) | |
180 | (build-system python-build-system) | |
181 | (home-page "http://gpodder.org/podcastparser") | |
182 | (synopsis "Simplified and fast RSS parser Python library") | |
183 | (description "@code{podcastparser} is a library for the gPodder project to | |
184 | provide an easy and reliable way of parsing RSS and Atom-based podcast feeds | |
185 | in Python.") | |
186 | (license license:isc))) |