Commit | Line | Data |
---|---|---|
3889a82e | 1 | ;;; GNU Guix --- Functional package management for GNU |
00f2bf34 | 2 | ;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org> |
7873318d | 3 | ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr> |
d6b8cb5c | 4 | ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org> |
7fb51d97 | 5 | ;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org> |
22b0caa3 | 6 | ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il> |
3889a82e NK |
7 | ;;; |
8 | ;;; This file is part of GNU Guix. | |
9 | ;;; | |
10 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
11 | ;;; under the terms of the GNU General Public License as published by | |
12 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
13 | ;;; your option) any later version. | |
14 | ;;; | |
15 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
16 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
17 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
18 | ;;; GNU General Public License for more details. | |
19 | ;;; | |
20 | ;;; You should have received a copy of the GNU General Public License | |
21 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
22 | ||
943f33a3 | 23 | (define-module (gnu packages glib) |
b5b73a82 | 24 | #:use-module ((guix licenses) #:prefix license:) |
3889a82e NK |
25 | #:use-module (guix packages) |
26 | #:use-module (guix download) | |
a1de06b6 | 27 | #:use-module (guix utils) |
3889a82e | 28 | #:use-module (guix build-system gnu) |
00f2bf34 | 29 | #:use-module (guix build-system python) |
943f33a3 LC |
30 | #:use-module (gnu packages) |
31 | #:use-module (gnu packages base) | |
9ceb630c | 32 | #:use-module (gnu packages bison) |
943f33a3 | 33 | #:use-module (gnu packages compression) |
9ceb630c | 34 | #:use-module (gnu packages flex) |
1dba6407 | 35 | #:use-module (gnu packages gettext) |
9ceb630c | 36 | #:use-module (gnu packages gtk) |
943f33a3 | 37 | #:use-module (gnu packages libffi) |
d6b8cb5c | 38 | #:use-module (gnu packages perl) |
943f33a3 LC |
39 | #:use-module (gnu packages pkg-config) |
40 | #:use-module (gnu packages python) | |
7bc5cc2b | 41 | #:use-module (gnu packages xml) |
5aa601a3 | 42 | #:use-module (gnu packages bash) |
80370441 LC |
43 | #:use-module (gnu packages file) |
44 | #:use-module (gnu packages xorg) | |
a5a7d374 | 45 | #:use-module (gnu packages m4) |
943f33a3 | 46 | |
80370441 LC |
47 | ;; Export variables up-front to allow circular dependency with the 'xorg' |
48 | ;; module. | |
49 | #:export (dbus | |
50 | glib | |
6ac6a6b9 | 51 | gobject-introspection |
80370441 LC |
52 | dbus-glib |
53 | intltool | |
a5a7d374 LC |
54 | itstool |
55 | libsigc++ | |
7873318d AE |
56 | glibmm |
57 | telepathy-glib)) | |
80370441 LC |
58 | |
59 | (define dbus | |
943f33a3 LC |
60 | (package |
61 | (name "dbus") | |
bbe04ae1 | 62 | (version "1.10.0") |
943f33a3 | 63 | (source (origin |
25087f60 SB |
64 | (method url-fetch) |
65 | (uri (string-append | |
7fb51d97 | 66 | "https://dbus.freedesktop.org/releases/dbus/dbus-" |
25087f60 SB |
67 | version ".tar.gz")) |
68 | (sha256 | |
69 | (base32 | |
f5a91039 LC |
70 | "0jwj7wlrhq5y0fwfh8k2d9rgdpfax06lj8698g6iqbwrzd2rgyqx")) |
71 | (patches | |
72 | (list (search-patch "dbus-helper-search-path.patch"))))) | |
943f33a3 | 73 | (build-system gnu-build-system) |
8eaa8a3b | 74 | (arguments |
25087f60 SB |
75 | '(#:configure-flags |
76 | (list | |
77 | ;; Install the system bus socket under /var. | |
78 | "--localstatedir=/var" | |
8eaa8a3b | 79 | |
25087f60 SB |
80 | ;; Install the session bus socket under /tmp. |
81 | "--with-session-socket-dir=/tmp" | |
8eaa8a3b | 82 | |
25087f60 SB |
83 | ;; Use /etc/dbus-1 for system-wide config. |
84 | ;; Look for configuration file under | |
85 | ;; /etc/dbus-1. This is notably required by | |
86 | ;; 'dbus-daemon-launch-helper', which looks for | |
87 | ;; the 'system.conf' file in that place, | |
88 | ;; regardless of what '--config-file' was | |
89 | ;; passed to 'dbus-daemon' on the command line; | |
90 | ;; see <https://bugs.freedesktop.org/show_bug.cgi?id=92458>. | |
91 | "--sysconfdir=/etc") | |
92 | #:phases | |
93 | (modify-phases %standard-phases | |
94 | (replace 'install | |
95 | (lambda _ | |
96 | ;; Don't try to create /var and /etc. | |
97 | (system* "make" | |
98 | "localstatedir=/tmp/dummy" | |
99 | "sysconfdir=/tmp/dummy" | |
100 | "install")))))) | |
708be46b LC |
101 | (native-inputs |
102 | `(("pkg-config" ,pkg-config))) | |
943f33a3 | 103 | (inputs |
d6b8cb5c | 104 | `(("expat" ,expat) |
80370441 LC |
105 | |
106 | ;; Add a dependency on libx11 so that 'dbus-launch' has support for | |
107 | ;; '--autolaunch'. | |
108 | ("libx11" ,libx11))) | |
109 | ||
943f33a3 LC |
110 | (home-page "http://dbus.freedesktop.org/") |
111 | (synopsis "Message bus for inter-process communication (IPC)") | |
112 | (description | |
113 | "D-Bus is a message bus system, a simple way for applications to | |
35b9e423 | 114 | talk to one another. In addition to interprocess communication, D-Bus |
943f33a3 LC |
115 | helps coordinate process lifecycle; it makes it simple and reliable to |
116 | code a \"single instance\" application or daemon, and to launch | |
117 | applications and daemons on demand when their services are needed. | |
118 | ||
119 | D-Bus supplies both a system daemon (for events such as \"new hardware | |
120 | device added\" or \"printer queue changed\") and a | |
121 | per-user-login-session daemon (for general IPC needs among user | |
35b9e423 | 122 | applications). Also, the message bus is built on top of a general |
943f33a3 LC |
123 | one-to-one message passing framework, which can be used by any two apps |
124 | to communicate directly (without going through the message bus | |
35b9e423 | 125 | daemon). Currently the communicating applications are on one computer, |
943f33a3 LC |
126 | or through unencrypted TCP/IP suitable for use behind a firewall with |
127 | shared NFS home directories.") | |
d6b8cb5c | 128 | (license license:gpl2+))) ; or Academic Free License 2.1 |
3889a82e | 129 | |
80370441 | 130 | (define glib |
3889a82e NK |
131 | (package |
132 | (name "glib") | |
3c19c6a4 | 133 | (version "2.46.1") |
3889a82e NK |
134 | (source (origin |
135 | (method url-fetch) | |
785db4d8 | 136 | (uri (string-append "mirror://gnome/sources/" |
d274f499 | 137 | name "/" (string-take version 4) "/" |
943f33a3 | 138 | name "-" version ".tar.xz")) |
3889a82e | 139 | (sha256 |
f47f6761 | 140 | (base32 |
3c19c6a4 | 141 | "1yzxr1ip3l0m9ydk5nq32piq70c9f17p5f0jyvlsghzbaawh67ss")) |
01eafd38 LC |
142 | (patches (list (search-patch "glib-tests-homedir.patch") |
143 | (search-patch "glib-tests-desktop.patch") | |
ca9ea1a8 | 144 | (search-patch "glib-tests-prlimit.patch") |
36d2a3af LC |
145 | (search-patch "glib-tests-timer.patch") |
146 | (search-patch "glib-tests-gapplication.patch"))))) | |
3889a82e | 147 | (build-system gnu-build-system) |
426adbe8 LC |
148 | (outputs '("out" ; everything |
149 | "bin" ; glib-mkenums, gtester, etc.; depends on Python | |
150 | "doc")) ; 20 MiB of GTK-Doc reference | |
3889a82e NK |
151 | (inputs |
152 | `(("coreutils" ,coreutils) | |
3889a82e | 153 | ("libffi" ,libffi) |
c4c4cc05 JD |
154 | ("zlib" ,zlib) |
155 | ("tzdata" ,tzdata))) ; for tests/gdatetime.c | |
156 | (native-inputs | |
59bad04f | 157 | `(("gettext" ,gnu-gettext) |
c4c4cc05 | 158 | ("dbus" ,dbus) ; for GDBus tests |
3889a82e | 159 | ("pkg-config" ,pkg-config) |
ee3e314b | 160 | ("python" ,python-wrapper) |
943f33a3 | 161 | ("perl" ,perl) ; needed by GIO tests |
c4c4cc05 | 162 | ("bash" ,bash))) |
943f33a3 | 163 | (arguments |
01eafd38 | 164 | '(#:phases (alist-cons-before |
943f33a3 LC |
165 | 'build 'pre-build |
166 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
7bc5cc2b LC |
167 | ;; For tests/gdatetime.c. |
168 | (setenv "TZDIR" | |
169 | (string-append (assoc-ref inputs "tzdata") | |
170 | "/share/zoneinfo")) | |
171 | ||
172 | ;; Some tests want write access there. | |
173 | (setenv "XDG_CACHE_HOME" (getcwd)) | |
174 | ||
943f33a3 LC |
175 | (substitute* '("glib/gspawn.c" |
176 | "glib/tests/utils.c" | |
177 | "tests/spawn-test.c") | |
7bc5cc2b | 178 | (("/bin/sh") |
ee28fc64 MW |
179 | (string-append (assoc-ref inputs "bash") "/bin/sh"))) |
180 | ||
181 | ;; Disable a test that requires dbus. | |
182 | (substitute* "gio/tests/gdbus-serialization.c" | |
a124bbd2 SB |
183 | (("g_test_add_func \ |
184 | \\(\"/gdbus/message-serialize/double-array\", test_double_array\\);" all) | |
ee28fc64 | 185 | (string-append "/* " all " */")))) |
943f33a3 LC |
186 | %standard-phases) |
187 | ||
188 | ;; Note: `--docdir' and `--htmldir' are not honored, so work around it. | |
189 | #:configure-flags (list (string-append "--with-html-dir=" | |
190 | (assoc-ref %outputs "doc") | |
b2a80c78 | 191 | "/share/gtk-doc/html")) |
00585a55 LC |
192 | |
193 | ;; In 'gio/tests', 'gdbus-test-codegen-generated.h' is #included in a | |
194 | ;; file that gets compiled possibly before it has been fully generated. | |
195 | #:parallel-tests? #f)) | |
ce2df078 LC |
196 | |
197 | (native-search-paths | |
198 | ;; This variable is not really "owned" by GLib, but several related | |
199 | ;; packages refer to it: gobject-introspection's tools use it as a search | |
200 | ;; path for .gir files, and it's also a search path for schemas produced | |
201 | ;; by 'glib-compile-schemas'. | |
202 | (list (search-path-specification | |
203 | (variable "XDG_DATA_DIRS") | |
1b85e57f SB |
204 | (files '("share"))) |
205 | ;; To load extra gio modules from glib-networking, etc. | |
206 | (search-path-specification | |
207 | (variable "GIO_EXTRA_MODULES") | |
208 | (files '("lib/gio/modules"))))) | |
ce2df078 LC |
209 | (search-paths native-search-paths) |
210 | ||
f50d2669 | 211 | (synopsis "Thread-safe general utility library; basis of GTK+ and GNOME") |
3889a82e NK |
212 | (description |
213 | "GLib provides data structure handling for C, portability wrappers, | |
214 | and interfaces for such runtime functionality as an event loop, threads, | |
215 | dynamic loading, and an object system.") | |
216 | (home-page "http://developer.gnome.org/glib/") | |
d6b8cb5c | 217 | (license license:lgpl2.0+))) ; some files are under lgpl2.1+ |
71eb5c10 | 218 | |
6ac6a6b9 | 219 | (define gobject-introspection |
9ceb630c CR |
220 | (package |
221 | (name "gobject-introspection") | |
ed89d901 | 222 | (version "1.46.0") |
9ceb630c CR |
223 | (source (origin |
224 | (method url-fetch) | |
cc84b08c | 225 | (uri (string-append "mirror://gnome/sources/" |
2474b81d FB |
226 | "gobject-introspection/" (version-major+minor version) |
227 | "/gobject-introspection-" version ".tar.xz")) | |
9ceb630c | 228 | (sha256 |
ed89d901 SB |
229 | (base32 "0cs27r18fga44ypp8icy62fwx6nh70r1bvhi4lzfn4w85cybsn36")) |
230 | (modules '((guix build utils))) | |
231 | (snippet | |
232 | '(substitute* "tools/g-ir-tool-template.in" | |
233 | (("#!/usr/bin/env @PYTHON@") "#!@PYTHON@"))) | |
7ca0dbc3 | 234 | (patches (list |
2474b81d | 235 | (search-patch "gobject-introspection-cc.patch") |
94987ebe FB |
236 | (search-patch |
237 | "gobject-introspection-girepository.patch") | |
7ca0dbc3 | 238 | (search-patch |
2474b81d | 239 | "gobject-introspection-absolute-shlib-path.patch"))))) |
9ceb630c CR |
240 | (build-system gnu-build-system) |
241 | (inputs | |
242 | `(("bison" ,bison) | |
243 | ("cairo" ,cairo) | |
244 | ("flex" ,flex) | |
245 | ("glib" ,glib) | |
9ceb630c | 246 | ("python-2" ,python-2))) |
426adbe8 | 247 | (native-inputs |
d7e92b87 ML |
248 | `(("glib" ,glib "bin") |
249 | ("pkg-config" ,pkg-config))) | |
af949e8e CR |
250 | (propagated-inputs |
251 | `(;; In practice, GIR users will need libffi when using | |
252 | ;; gobject-introspection. | |
253 | ("libffi" ,libffi))) | |
5a4753a6 FB |
254 | (native-search-paths |
255 | (list (search-path-specification | |
256 | (variable "GI_TYPELIB_PATH") | |
af070955 | 257 | (files '("lib/girepository-1.0"))))) |
5a4753a6 | 258 | (search-paths native-search-paths) |
9ceb630c | 259 | (arguments |
2474b81d FB |
260 | `(;; The patch 'gobject-introspection-absolute-shlib-path.patch' causes |
261 | ;; some tests to fail. | |
cc84b08c | 262 | #:tests? #f)) |
9ceb630c CR |
263 | (home-page "https://wiki.gnome.org/GObjectIntrospection") |
264 | (synopsis "Generate interface introspection data for GObject libraries") | |
265 | (description | |
266 | "GObject introspection is a middleware layer between C libraries (using | |
267 | GObject) and language bindings. The C library can be scanned at compile time | |
268 | and generate a metadata file, in addition to the actual native C library. Then | |
269 | at runtime, language bindings can read this metadata and automatically provide | |
270 | bindings to call into the C library.") | |
271 | ; Some bits are distributed under the LGPL2+, others under the GPL2+ | |
272 | (license license:gpl2+))) | |
273 | ||
80370441 | 274 | (define intltool |
71eb5c10 LC |
275 | (package |
276 | (name "intltool") | |
fa09ebfa | 277 | (version "0.51.0") |
71eb5c10 LC |
278 | (source (origin |
279 | (method url-fetch) | |
d6b8cb5c AE |
280 | (uri (string-append "https://launchpad.net/intltool/trunk/" |
281 | version "/+download/intltool-" | |
282 | version ".tar.gz")) | |
71eb5c10 LC |
283 | (sha256 |
284 | (base32 | |
fa09ebfa | 285 | "1karx4sb7bnm2j67q0q74hspkfn6lqprpy5r99vkn5bb36a4viv7")))) |
71eb5c10 | 286 | (build-system gnu-build-system) |
93882f0e EB |
287 | (inputs |
288 | `(("file" ,file))) | |
71eb5c10 | 289 | (propagated-inputs |
107b415e LC |
290 | `(;; Propagate gettext because users expect it to be there, and so does |
291 | ;; the `intltool-update' script. | |
1dba6407 | 292 | ("gettext" ,gnu-gettext) |
107b415e | 293 | |
e33d9d6f | 294 | ("perl-xml-parser" ,perl-xml-parser) |
107b415e | 295 | ("perl" ,perl))) |
93882f0e EB |
296 | (arguments |
297 | `(#:phases (alist-cons-after | |
298 | 'unpack 'patch-file-references | |
299 | (lambda* (#:key inputs #:allow-other-keys) | |
300 | (let ((file (assoc-ref inputs "file"))) | |
301 | (substitute* "intltool-update.in" | |
302 | (("`file") (string-append "`" file "/bin/file"))))) | |
303 | %standard-phases))) | |
d6b8cb5c AE |
304 | (home-page "https://launchpad.net/intltool/+download") |
305 | (synopsis "Tools to centralise translations of different file formats") | |
71eb5c10 | 306 | (description |
35b9e423 | 307 | "Intltool is a set of tools to centralise translations of many different |
71eb5c10 LC |
308 | file formats using GNU gettext-compatible PO files. |
309 | ||
310 | The intltool collection can be used to do these things: | |
311 | ||
312 | Extract translatable strings from various source files (.xml.in, | |
313 | glade, .desktop.in, .server.in, .oaf.in). | |
314 | ||
315 | Collect the extracted strings together with messages from traditional | |
316 | source files (.c, .h) in po/$(PACKAGE).pot. | |
317 | ||
318 | Merge back the translations from .po files into .xml, .desktop and | |
35b9e423 | 319 | oaf files. This merge step will happen at build resp. installation time.") |
d6b8cb5c | 320 | (license license:gpl2+))) |
24b5c463 | 321 | |
80370441 | 322 | (define itstool |
20a26ff5 CR |
323 | (package |
324 | (name "itstool") | |
3c87c02e | 325 | (version "2.0.2") |
20a26ff5 CR |
326 | (source (origin |
327 | (method url-fetch) | |
328 | (uri (string-append "http://files.itstool.org/itstool/itstool-" | |
329 | version ".tar.bz2")) | |
330 | (sha256 | |
331 | (base32 | |
3c87c02e | 332 | "0fh34wi52i0qikgvlmrcpf1vx6gc1xqdad4539l4d9hikfsrz45z")))) |
20a26ff5 | 333 | (build-system gnu-build-system) |
4b58d88b | 334 | (inputs |
f922fc42 | 335 | `(("libxml2" ,libxml2) |
264d57b6 | 336 | ("python2-libxml2" ,python2-libxml2) |
f922fc42 | 337 | ("python-2" ,python-2))) |
4b58d88b SB |
338 | (arguments |
339 | '(#:phases | |
340 | (modify-phases %standard-phases | |
341 | (add-after | |
342 | 'install 'wrap-program | |
343 | (lambda* (#:key outputs #:allow-other-keys) | |
344 | (let ((prog (string-append (assoc-ref outputs "out") | |
345 | "/bin/itstool"))) | |
346 | (wrap-program prog | |
347 | `("PYTHONPATH" = (,(getenv "PYTHONPATH")))))))))) | |
20a26ff5 CR |
348 | (home-page "http://www.itstool.org") |
349 | (synopsis "Tool to translate XML documents with PO files") | |
350 | (description | |
351 | "ITS Tool allows you to translate your XML documents with PO files, using | |
352 | rules from the W3C Internationalization Tag Set (ITS) to determine what to | |
353 | translate and how to separate it into PO file messages. | |
354 | ||
355 | PO files are the standard translation format for GNU and other Unix-like | |
356 | systems. They present translatable information as discrete messages, allowing | |
357 | each message to be translated independently. In contrast to whole-page | |
358 | translation, translating with a message-based format like PO means you can | |
359 | easily track changes to the source document down to the paragraph. When new | |
360 | strings are added or existing strings are modified, you only need to update the | |
361 | corresponding messages. | |
362 | ||
363 | ITS Tool is designed to make XML documents translatable through PO files by | |
364 | applying standard ITS rules, as well as extension rules specific to ITS Tool. | |
365 | ITS also provides an industry standard way for authors to override translation | |
366 | information in their documents, such as whether a particular element should be | |
367 | translated.") | |
a129e0d8 | 368 | (license license:gpl3+))) |
20a26ff5 | 369 | |
80370441 | 370 | (define dbus-glib |
24b5c463 AE |
371 | (package |
372 | (name "dbus-glib") | |
cb77ade6 | 373 | (version "0.104") |
24b5c463 AE |
374 | (source (origin |
375 | (method url-fetch) | |
376 | (uri | |
5cc3096c | 377 | (string-append "https://dbus.freedesktop.org/releases/dbus-glib/dbus-glib-" |
24b5c463 AE |
378 | version ".tar.gz")) |
379 | (sha256 | |
380 | (base32 | |
cb77ade6 | 381 | "1xi1v1msz75qs0s4lkyf1psrksdppa3hwkg0mznc6gpw5flg3hdz")))) |
24b5c463 | 382 | (build-system gnu-build-system) |
2e88d113 | 383 | (propagated-inputs ; according to dbus-glib-1.pc |
24b5c463 | 384 | `(("dbus" ,dbus) |
44add1ce | 385 | ("glib" ,glib))) |
2e88d113 AE |
386 | (inputs |
387 | `(("expat" ,expat))) | |
44add1ce LC |
388 | (native-inputs |
389 | `(("glib" ,glib "bin") | |
24b5c463 AE |
390 | ("pkg-config" ,pkg-config))) |
391 | (home-page "http://dbus.freedesktop.org/doc/dbus-glib/") | |
392 | (synopsis "D-Bus GLib bindings") | |
393 | (description | |
394 | "GLib bindings for D-Bus. The package is obsolete and superseded | |
395 | by GDBus included in Glib.") | |
396 | (license license:gpl2))) ; or Academic Free License 2.1 | |
a5a7d374 LC |
397 | |
398 | (define libsigc++ | |
399 | (package | |
400 | (name "libsigc++") | |
93d809b0 | 401 | (version "2.6.1") |
a5a7d374 LC |
402 | (source (origin |
403 | (method url-fetch) | |
e7a720e6 SB |
404 | (uri (string-append "mirror://gnome/sources/libsigc++/" |
405 | (version-major+minor version) "/" | |
406 | name "-" version ".tar.xz")) | |
a5a7d374 LC |
407 | (sha256 |
408 | (base32 | |
93d809b0 | 409 | "06xyvxaaxh3nbpjg86gcq5zcc2qnpx354wcfrqlhbndkq5kj2vqq")))) |
a5a7d374 | 410 | (build-system gnu-build-system) |
41eb1198 LC |
411 | (native-inputs `(("pkg-config" ,pkg-config) |
412 | ("m4" ,m4))) | |
a5a7d374 LC |
413 | (home-page "http://libsigc.sourceforge.net/") |
414 | (synopsis "Type-safe callback system for standard C++") | |
415 | (description | |
35b9e423 | 416 | "Libsigc++ implements a type-safe callback system for standard C++. It |
a5a7d374 LC |
417 | allows you to define signals and to connect those signals to any callback |
418 | function, either global or a member function, regardless of whether it is | |
419 | static or virtual. | |
420 | ||
421 | It also contains adaptor classes for connection of dissimilar callbacks and | |
422 | has an ease of use unmatched by other C++ callback libraries.") | |
423 | (license license:lgpl2.1+))) | |
424 | ||
425 | (define glibmm | |
426 | (package | |
427 | (name "glibmm") | |
22b0caa3 | 428 | (version "2.46.3") |
a5a7d374 LC |
429 | (source (origin |
430 | (method url-fetch) | |
3d6befa4 MW |
431 | (uri (string-append "mirror://gnome/sources/glibmm/" |
432 | (version-major+minor version) | |
433 | "/glibmm-" version ".tar.xz")) | |
a5a7d374 LC |
434 | (sha256 |
435 | (base32 | |
22b0caa3 | 436 | "1kw65mlabwdjw86jybxslncbnnx40hcx4z6xpq9i4ymjvsnm91n7")))) |
a5a7d374 LC |
437 | (build-system gnu-build-system) |
438 | (arguments | |
439 | `(#:phases (alist-cons-before | |
440 | 'build 'pre-build | |
441 | (lambda _ | |
442 | ;; This test uses /etc/fstab as an example file to read | |
443 | ;; from; choose a better example. | |
444 | (substitute* "tests/giomm_simple/main.cc" | |
445 | (("/etc/fstab") | |
446 | (string-append (getcwd) | |
447 | "/tests/giomm_simple/main.cc"))) | |
448 | ||
449 | ;; This test does a DNS lookup, and then expects to be able | |
450 | ;; to open a TLS session; just skip it. | |
451 | (substitute* "tests/giomm_tls_client/main.cc" | |
452 | (("Gio::init.*$") | |
453 | "return 77;\n"))) | |
454 | %standard-phases))) | |
41eb1198 LC |
455 | (native-inputs `(("pkg-config" ,pkg-config) |
456 | ("glib" ,glib "bin"))) | |
a5a7d374 LC |
457 | (propagated-inputs |
458 | `(("libsigc++" ,libsigc++) | |
459 | ("glib" ,glib))) | |
460 | (home-page "http://gtkmm.org/") | |
461 | (synopsis "C++ interface to the GLib library") | |
462 | (description | |
35b9e423 | 463 | "Glibmm provides a C++ programming interface to the part of GLib that are |
a5a7d374 LC |
464 | useful for C++.") |
465 | (license license:lgpl2.1+))) | |
a1de06b6 EB |
466 | |
467 | (define-public python2-pygobject-2 | |
468 | (package | |
469 | (name "python2-pygobject") | |
470 | ;; This was the last version to declare the 2.0 platform number, i.e. its | |
471 | ;; pkg-config files were named pygobject-2.0.pc | |
472 | (version "2.28.6") | |
473 | (source | |
474 | (origin | |
475 | (method url-fetch) | |
476 | (uri (string-append "mirror://gnome/sources/pygobject/" | |
477 | (version-major+minor version) | |
478 | "/pygobject-" version ".tar.xz")) | |
479 | (sha256 | |
480 | (base32 | |
481 | "1f5dfxjnil2glfwxnqr14d2cjfbkghsbsn8n04js2c2icr7iv2pv")) | |
482 | (patches | |
483 | (list (search-patch | |
484 | "python2-pygobject-2-gi-info-type-error-domain.patch"))))) | |
485 | (build-system gnu-build-system) | |
486 | (native-inputs | |
487 | `(("which" ,which) | |
488 | ("glib-bin" ,glib "bin") ;for tests: glib-compile-schemas | |
489 | ("pkg-config" ,pkg-config) | |
490 | ("dbus" ,dbus))) ;for tests | |
491 | (inputs | |
492 | `(("python" ,python-2) | |
493 | ("glib" ,glib) | |
7ca0dbc3 | 494 | ("python2-pycairo" ,python2-pycairo) |
a1de06b6 EB |
495 | ("gobject-introspection" ,gobject-introspection))) |
496 | (propagated-inputs | |
497 | `(("libffi" ,libffi))) ;mentioned in pygobject-2.0.pc | |
498 | (arguments | |
499 | `(#:tests? #f ;segfaults during tests | |
500 | #:configure-flags '("LIBS=-lcairo-gobject"))) | |
501 | (home-page "https://pypi.python.org/pypi/PyGObject") | |
502 | (synopsis "Python bindings for GObject") | |
503 | (description | |
504 | "Python bindings for GLib, GObject, and GIO.") | |
505 | (license license:lgpl2.1+))) | |
506 | ||
507 | (define-public python-pygobject | |
508 | (package | |
509 | (name "python-pygobject") | |
13ddcf40 | 510 | (version "3.18.0") |
a1de06b6 EB |
511 | (source |
512 | (origin | |
513 | (method url-fetch) | |
514 | (uri (string-append "mirror://gnome/sources/pygobject/" | |
515 | (version-major+minor version) | |
516 | "/pygobject-" version ".tar.xz")) | |
517 | (sha256 | |
518 | (base32 | |
13ddcf40 | 519 | "1jbd2m39vcjh5h3m33l0317ziq8dxfzi40r6hrfcs4rp5l8s2fqw")))) |
a1de06b6 EB |
520 | (build-system gnu-build-system) |
521 | (native-inputs | |
522 | `(("which" ,which) | |
523 | ("glib-bin" ,glib "bin") ;for tests: glib-compile-schemas | |
524 | ("pkg-config" ,pkg-config))) | |
525 | (inputs | |
526 | `(("python" ,python) | |
a1de06b6 | 527 | ("python-pycairo" ,python-pycairo) |
fa7cf82e SB |
528 | ("gobject-introspection" ,gobject-introspection))) |
529 | (propagated-inputs | |
530 | ;; pygobject-3.0.pc refers to all these. | |
531 | `(("glib" ,glib) | |
a1de06b6 EB |
532 | ("libffi" ,libffi))) |
533 | (arguments | |
534 | ;; TODO: failing tests: test_native_calls_async | |
535 | ;; test_native_calls_async_errors test_native_calls_sync | |
536 | ;; test_native_calls_sync_errors test_python_calls_async | |
537 | ;; test_python_calls_async_error test_python_calls_async_error_result | |
538 | ;; test_python_calls_sync test_python_calls_sync_errors | |
539 | ;; test_python_calls_sync_noargs test_callback_user_data_middle_none | |
540 | ;; test_callback_user_data_middle_single | |
541 | ;; test_callback_user_data_middle_tuple | |
542 | '(#:tests? #f)) | |
e28f95a9 SB |
543 | ;; For finding typelib files, since gobject-introscpetion isn't propagated. |
544 | (native-search-paths (package-native-search-paths gobject-introspection)) | |
594a362b | 545 | (home-page "https://live.gnome.org/PyGObject") |
a1de06b6 EB |
546 | (synopsis "Python bindings for GObject") |
547 | (description | |
548 | "Python bindings for GLib, GObject, and GIO.") | |
00f2bf34 LC |
549 | (license license:lgpl2.1+) |
550 | (properties `((python2-variant . ,(delay python2-pygobject)))))) | |
7873318d | 551 | |
0f49d7ba | 552 | (define-public python2-pygobject |
00f2bf34 | 553 | (package (inherit (strip-python2-variant python-pygobject)) |
0f49d7ba RW |
554 | (name "python2-pygobject") |
555 | (inputs | |
556 | `(("python" ,python-2) | |
0f49d7ba | 557 | ("python-pycairo" ,python2-pycairo) |
fa7cf82e | 558 | ("gobject-introspection" ,gobject-introspection))))) |
0f49d7ba | 559 | |
7873318d AE |
560 | (define telepathy-glib |
561 | (package | |
562 | (name "telepathy-glib") | |
563 | (version "0.24.1") | |
564 | (source | |
565 | (origin | |
566 | (method url-fetch) | |
567 | (uri | |
568 | (string-append | |
5cc3096c | 569 | "https://telepathy.freedesktop.org/releases/telepathy-glib/" |
7873318d AE |
570 | "telepathy-glib-" version ".tar.gz")) |
571 | (sha256 | |
572 | (base32 | |
7f48be41 SB |
573 | "1symyzbjmxvksn2ifdkk50lafjm2llf2sbmky062gq2pz3cg23cy")) |
574 | (patches | |
575 | (list | |
576 | ;; Don't use the same test name for multiple tests. | |
577 | ;; <https://bugs.freedesktop.org/show_bug.cgi?id=92245> | |
578 | (origin | |
579 | (method url-fetch) | |
580 | (uri "https://bugs.freedesktop.org/attachment.cgi?id=118608") | |
581 | (file-name (string-append "telepathy-glib-duplicate-tests.patch")) | |
582 | (sha256 | |
583 | (base32 | |
584 | "0z261fwrszxb28ccg3hsg9rizig4s84zvwmx6y31a4pyv7bvs5w3"))))))) | |
7873318d AE |
585 | (build-system gnu-build-system) |
586 | (native-inputs | |
587 | `(("glib" ,glib "bin") ; uses glib-mkenums | |
d2ab0e90 | 588 | ("gobject-introspection" ,gobject-introspection) |
7873318d | 589 | ("pkg-config" ,pkg-config) |
d2ab0e90 SB |
590 | ("python" ,python-2) |
591 | ("xsltproc" ,libxslt))) | |
592 | (propagated-inputs | |
593 | ;; There are all in the Requires.private field of telepathy-glib.pc. | |
7873318d AE |
594 | `(("dbus" ,dbus) |
595 | ("dbus-glib" ,dbus-glib) | |
d2ab0e90 | 596 | ("glib" ,glib))) |
7873318d AE |
597 | (home-page "http://telepathy.freedesktop.org/wiki/") |
598 | (synopsis "GLib Real-time communications framework over D-Bus") | |
599 | (description "Telepathy is a flexible, modular communications framework | |
600 | that enables real-time communication over D-Bus via pluggable protocol | |
601 | backends. Telepathy is a communications service that can be accessed by | |
602 | many applications simultaneously. | |
603 | ||
604 | This package provides the library for GLib applications.") | |
605 | (license license:lgpl2.1+))) |