summaryrefslogtreecommitdiff
path: root/gnu/packages/glib.scm
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2021-04-08 15:47:00 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2021-04-08 15:47:00 -0400
commit533a893cc6b03f100566760d6e0c8e0500ed7082 (patch)
tree0ecbf89895a400c43d16bb1f6539f1a88aeaa4cf /gnu/packages/glib.scm
parent6a2546f92d07df04e5d700924edd027ed1e2ef11 (diff)
parentc762df54786fd6f005f3b5307323f1d2df3cbf0b (diff)
Merge branch 'master' into staging
Conflicts: .guix-authorizations gnu/ci.scm gnu/packages/base.scm gnu/packages/databases.scm gnu/packages/gnome.scm gnu/packages/gtk.scm gnu/packages/imagemagick.scm gnu/packages/password-utils.scm gnu/packages/python-xyz.scm gnu/packages/web-browsers.scm
Diffstat (limited to 'gnu/packages/glib.scm')
-rw-r--r--gnu/packages/glib.scm118
1 files changed, 88 insertions, 30 deletions
diff --git a/gnu/packages/glib.scm b/gnu/packages/glib.scm
index 8de6e198be..88b5831a6d 100644
--- a/gnu/packages/glib.scm
+++ b/gnu/packages/glib.scm
@@ -2,7 +2,7 @@
;;; Copyright © 2013, 2014, 2015, 2016, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr>
;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
-;;; Copyright © 2014, 2015, 2016, 2017, 2018 Mark H Weaver <mhw@netris.org>
+;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2021 Mark H Weaver <mhw@netris.org>
;;; Copyright © 2016, 2020 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
;;; Copyright © 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
@@ -172,6 +172,7 @@ shared NFS home directories.")
(package
(name "glib")
(version "2.62.6")
+ (replacement glib/fixed)
(source (origin
(method url-fetch)
(uri (string-append "mirror://gnome/sources/"
@@ -234,7 +235,7 @@ shared NFS home directories.")
(lambda _
(substitute* "meson.build"
(("test_timeout = 60")
- "test_timeout = 90")
+ "test_timeout = 120")
(("test_timeout_slow = 120")
"test_timeout_slow = 180")))))
'())
@@ -390,6 +391,34 @@ dynamic loading, and an object system.")
(home-page "https://developer.gnome.org/glib/")
(license license:lgpl2.1+)))
+(define glib/fixed
+ (package
+ (inherit glib)
+ (source (origin
+ (inherit (package-source glib))
+ (patches
+ (append (search-patches "glib-CVE-2021-27218.patch"
+ "glib-CVE-2021-27219-01.patch"
+ "glib-CVE-2021-27219-02.patch"
+ "glib-CVE-2021-27219-03.patch"
+ "glib-CVE-2021-27219-04.patch"
+ "glib-CVE-2021-27219-05.patch"
+ "glib-CVE-2021-27219-06.patch"
+ "glib-CVE-2021-27219-07.patch"
+ "glib-CVE-2021-27219-08.patch"
+ "glib-CVE-2021-27219-09.patch"
+ "glib-CVE-2021-27219-10.patch"
+ "glib-CVE-2021-27219-11.patch"
+ "glib-CVE-2021-27219-12.patch"
+ "glib-CVE-2021-27219-13.patch"
+ "glib-CVE-2021-27219-14.patch"
+ "glib-CVE-2021-27219-15.patch"
+ "glib-CVE-2021-27219-16.patch"
+ "glib-CVE-2021-27219-17.patch"
+ "glib-CVE-2021-27219-18.patch"
+ "glib-CVE-2021-28153.patch")
+ (origin-patches (package-source glib))))))))
+
(define-public glib-with-documentation
;; glib's doc must be built in a separate package since it requires gtk-doc,
;; which in turn depends on glib.
@@ -417,6 +446,34 @@ dynamic loading, and an object system.")
(delete-file-recursively (string-append out html))
#t)))))))))
+;;; TODO: Merge into glib as a 'static' output on core-updates.
+(define-public glib-static
+ (hidden-package
+ (package
+ (inherit glib)
+ (name "glib-static")
+ (outputs '("out"))
+ (arguments
+ (substitute-keyword-arguments (package-arguments glib)
+ ((#:configure-flags flags ''())
+ `(cons* "--default-library=static"
+ "-Dselinux=disabled"
+ "-Dman=false"
+ "-Dgtk_doc=false"
+ "-Dinternal_pcre=false"
+ ,flags))
+ ((#:phases phases)
+ `(modify-phases ,phases
+ (delete 'move-executables)
+ (replace 'install
+ ;; Only install the static libraries.
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (lib (string-append out "/lib")))
+ (for-each (lambda (f)
+ (install-file f lib))
+ (find-files "." "\\.a$"))))))))))))
+
(define gobject-introspection
(package
(name "gobject-introspection")
@@ -776,32 +833,33 @@ useful for C++.")
(properties `((python2-variant . ,(delay python2-pygobject))))))
(define-public python2-pygobject
- (package (inherit (strip-python2-variant python-pygobject))
- (name "python2-pygobject")
+ (let ((base (strip-python2-variant python-pygobject)))
+ (package/inherit base
+ (name "python2-pygobject")
- ;; Note: We use python-build-system here, because Meson only supports
- ;; Python 3, and needs PYTHONPATH etc set up correctly, which makes it
- ;; difficult to use for Python 2 projects.
- (build-system python-build-system)
- (arguments
- `(#:python ,python-2
- #:phases
- (modify-phases %standard-phases
- (add-after 'unpack 'delete-broken-tests
- (lambda _
- ;; FIXME: this test freezes and times out.
- (delete-file "tests/test_mainloop.py")
- ;; FIXME: this test fails with this kind of error:
- ;; AssertionError: <Handlers.SIG_IGN: 1> != <built-in function default_int_handler
- (delete-file "tests/test_ossig.py")
- #t)))))
- (inputs
- `(("python-pycairo" ,python2-pycairo)
- ("gobject-introspection" ,gobject-introspection)))
- (native-inputs
- `(("glib-bin" ,glib "bin")
- ("pkg-config" ,pkg-config)
- ("python-pytest" ,python2-pytest)))))
+ ;; Note: We use python-build-system here, because Meson only supports
+ ;; Python 3, and needs PYTHONPATH etc set up correctly, which makes it
+ ;; difficult to use for Python 2 projects.
+ (build-system python-build-system)
+ (arguments
+ `(#:python ,python-2
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'delete-broken-tests
+ (lambda _
+ ;; FIXME: this test freezes and times out.
+ (delete-file "tests/test_mainloop.py")
+ ;; FIXME: this test fails with this kind of error:
+ ;; AssertionError: <Handlers.SIG_IGN: 1> != <built-in function default_int_handler
+ (delete-file "tests/test_ossig.py")
+ #t)))))
+ (inputs
+ `(("python-pycairo" ,python2-pycairo)
+ ("gobject-introspection" ,gobject-introspection)))
+ (native-inputs
+ `(("glib-bin" ,glib "bin")
+ ("pkg-config" ,pkg-config)
+ ("python-pytest" ,python2-pytest))))))
(define-public perl-glib
(package
@@ -938,8 +996,8 @@ This package provides the library for GLib applications.")
#t)))))
(synopsis "D-Bus API for C++")
(description "This package provides D-Bus client API bindings for the C++
-programming language. It also contains the utility
-@command{dbuscxx-xml2cpp}.")
+programming language. It also provides the @command{dbusxx-xml2cpp} and
+@command{dbusxx-introspect} commands.")
(home-page "https://sourceforge.net/projects/dbus-cplusplus/")
(license license:lgpl2.1+)))
@@ -1107,7 +1165,7 @@ other API remains the same.")
`(("bison" ,bison)
("flex" ,flex)
("glib:bin" ,glib "bin") ;; For glib-mkenums
- ("gtk-doc" ,gtk-doc)
+ ("gtk-doc" ,gtk-doc/stable)
("pkg-config" ,pkg-config)
("vala" ,vala)))
(home-page "https://gitlab.gnome.org/GNOME/template-glib")