diff options
author | Ludovic Courtès <ludo@gnu.org> | 2013-01-16 23:01:24 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2013-01-19 22:20:47 +0100 |
commit | 943f33a3263af38c69a2eb60440fe10602104607 (patch) | |
tree | 7786acdae26e1d815771f1a4ecce0639c412cda4 /gnu/packages/glib.scm | |
parent | 3889a82ef889004bb0835c54e8dc8b23a4a6758f (diff) | |
download | guix-943f33a3263af38c69a2eb60440fe10602104607.tar.gz |
distro: glib: Run the test suite; add DBus.
* distro/packages/glib.scm: Rename to... * gnu/packages/glib.scm: ... this. Update module declaration accordingly. (dbus): New variable. (glib): Change version number to 2.34.3, and adjust URL accordingly. Add a "doc" output. Add #:configure-flags, #:patches, and #:phases arguments. Add DBUS as an input, as well a three patches. * Makefile.am (MODULES): Adjust to file renaming. (dist_patch_DATA): Add `glib-tests-timezone.patch', `glib-tests-homedir.patch', and `glib-tests-desktop.patch'.
Diffstat (limited to 'gnu/packages/glib.scm')
-rw-r--r-- | gnu/packages/glib.scm | 99 |
1 files changed, 83 insertions, 16 deletions
diff --git a/gnu/packages/glib.scm b/gnu/packages/glib.scm index bbf64f2800..1286700911 100644 --- a/gnu/packages/glib.scm +++ b/gnu/packages/glib.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org> +;;; Copyright © 2013 Ludovic Courtès <ludo@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -16,44 +17,110 @@ ;;; You should have received a copy of the GNU General Public License ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. -(define-module (distro packages glib) - #:use-module ((guix licenses) #:select (lgpl2.0+)) +(define-module (gnu packages glib) + #:use-module ((guix licenses) #:select (lgpl2.0+ gpl2+)) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix build-system gnu) - #:use-module (distro packages base) - #:use-module (distro packages compression) - #:use-module ((distro packages gettext) + #:use-module (gnu packages) + #:use-module (gnu packages base) + #:use-module (gnu packages compression) + #:use-module ((gnu packages gettext) #:renamer (symbol-prefix-proc 'guix:)) - #:use-module (distro packages libffi) - #:use-module (distro packages pkg-config) - #:use-module (distro packages python)) + #:use-module (gnu packages libffi) + #:use-module (gnu packages pkg-config) + #:use-module (gnu packages python) + #:use-module (gnu packages perl) + #:use-module ((gnu packages xml) + #:renamer (symbol-prefix-proc 'xml:))) + +(define-public dbus + (package + (name "dbus") + (version "1.6.4") + (source (origin + (method url-fetch) + (uri + (string-append "http://dbus.freedesktop.org/releases/dbus/dbus-" + version ".tar.gz")) + (sha256 + (base32 + "1wacqyfkcpayg7f8rvx9awqg275n5pksxq5q7y21lxjx85x6pfjz")))) + (build-system gnu-build-system) + (inputs + `(("expat" ,xml:expat) + ("pkg-config" ,pkg-config))) + (home-page "http://dbus.freedesktop.org/") + (synopsis "Message bus for inter-process communication (IPC)") + (description + "D-Bus is a message bus system, a simple way for applications to +talk to one another. In addition to interprocess communication, D-Bus +helps coordinate process lifecycle; it makes it simple and reliable to +code a \"single instance\" application or daemon, and to launch +applications and daemons on demand when their services are needed. + +D-Bus supplies both a system daemon (for events such as \"new hardware +device added\" or \"printer queue changed\") and a +per-user-login-session daemon (for general IPC needs among user +applications). Also, the message bus is built on top of a general +one-to-one message passing framework, which can be used by any two apps +to communicate directly (without going through the message bus +daemon). Currently the communicating applications are on one computer, +or through unencrypted TCP/IP suitable for use behind a firewall with +shared NFS home directories.") + (license gpl2+))) ; or Academic Free License 2.1 (define-public glib (package (name "glib") - (version "2.34") + (version "2.34.3") (source (origin (method url-fetch) (uri (string-append "http://ftp.gnome.org/pub/gnome/sources/" - name "/" version "/" - name "-" version ".3" ".tar.xz")) + name "/2.34/" + name "-" version ".tar.xz")) (sha256 (base32 "19sq4rhl2vr8ikjvl8qh51vr38yqfhbkb3imi2s6ac5rgkwcnpw5")))) (build-system gnu-build-system) + (outputs '("out" ; everything + "doc")) ; 20 MiB of GTK-Doc reference (inputs `(("coreutils" ,coreutils) ("gettext" ,guix:gettext) ("libffi" ,libffi) ("pkg-config" ,pkg-config) ("python" ,python) - ("zlib" ,zlib))) - (arguments `(#:tests? #f)) ; XXX: tests fail - (synopsis - "GLib, a library that provides the core application building blocks") + ("zlib" ,zlib) + ("perl" ,perl) ; needed by GIO tests + ("dbus" ,dbus) ; for GDBus tests + + ("patch/tests-tzdata" + ,(search-patch "glib-tests-timezone.patch")) + ("patch/tests-homedir" + ,(search-patch "glib-tests-homedir.patch")) + ("patch/tests-desktop" + ,(search-patch "glib-tests-desktop.patch")))) + (arguments + '(#:patches (list (assoc-ref %build-inputs "patch/tests-tzdata") + (assoc-ref %build-inputs "patch/tests-homedir") + (assoc-ref %build-inputs "patch/tests-desktop")) + #:phases (alist-cons-before + 'build 'pre-build + (lambda* (#:key inputs outputs #:allow-other-keys) + (substitute* '("glib/gspawn.c" + "glib/tests/utils.c" + "tests/spawn-test.c") + (("/bin/sh") (which "sh")))) + %standard-phases) + + ;; Note: `--docdir' and `--htmldir' are not honored, so work around it. + #:configure-flags (list (string-append "--with-html-dir=" + (assoc-ref %outputs "doc") + "/share/gtk-doc")))) + (synopsis "C library that provides core application building blocks") (description "GLib provides data structure handling for C, portability wrappers, and interfaces for such runtime functionality as an event loop, threads, dynamic loading, and an object system.") (home-page "http://developer.gnome.org/glib/") - (license lgpl2.0+))) ; some files are under lgpl2.1+ \ No newline at end of file + (license lgpl2.0+))) ; some files are under lgpl2.1+ |