From 0f7fa27327031be0f07bba0abd3fc3f90177792b Mon Sep 17 00:00:00 2001 From: "Benjamin S. Kirk" Date: Thu, 22 Dec 2022 03:28:30 -0700 Subject: librsvg: add 2.40.21, which does not require rust (#34585) * librsvg: add 2.40.21, which does not require rust and has some security backports https://download.gnome.org/sources/librsvg/2.40/librsvg-2.40.21.news * librsvg: prevent finding broken gtkdoc binaries when ~doc is selected. On my CentOS7 hosts, ./configure finds e.g. /bin/gtkdoc-rebase even when ~doc is selected. These tools use Python2, and fail with an error: "ImportError: No module named site" So prevent ./configure from finding these broken tools when not building the +doc variant. --- var/spack/repos/builtin/packages/librsvg/package.py | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'var') diff --git a/var/spack/repos/builtin/packages/librsvg/package.py b/var/spack/repos/builtin/packages/librsvg/package.py index 6723c1bd23..208feb7e13 100644 --- a/var/spack/repos/builtin/packages/librsvg/package.py +++ b/var/spack/repos/builtin/packages/librsvg/package.py @@ -16,12 +16,13 @@ class Librsvg(AutotoolsPackage): version("2.50.2", sha256="6211f271ce4cd44a7318190d36712e9cea384a933d3e3570004edeb210a056d3") version("2.50.0", sha256="b3fadba240f09b9c9898ab20cb7311467243e607cf8f928b7c5f842474ee3df4") version("2.44.14", sha256="6a85a7868639cdd4aa064245cc8e9d864dad8b8e9a4a8031bb09a4796bc4e303") + version("2.40.21", sha256="f7628905f1cada84e87e2b14883ed57d8094dca3281d5bcb24ece4279e9a92ba") variant("doc", default=False, description="Build documentation with gtk-doc") depends_on("gobject-introspection", type="build") depends_on("pkgconfig", type="build") - depends_on("rust", type="build") + depends_on("rust", type="build", when="@2.41:") depends_on("gtk-doc", type="build", when="+doc") depends_on("cairo+gobject") depends_on("gdk-pixbuf") @@ -52,4 +53,16 @@ class Librsvg(AutotoolsPackage): env.prepend_path("XDG_DATA_DIRS", self.prefix.share) def configure_args(self): - return ["--enable-gtk-doc=" + ("yes" if self.spec.variants["doc"].value else "no")] + args = [] + if "+doc" in self.spec: + args.append("--enable-gtk-doc") + else: + args.extend( + [ + "--disable-gtk-doc", + "GTKDOC_MKPDF=/bin/true", + "GTKDOC_REBASE=/bin/true", + "GTKDOC_CHECK_PATH=/bin/true", + ] + ) + return args -- cgit v1.2.3-70-g09d2