diff mbox series

[bug#65479,core-updates,v2,30/62] gnu: colord-gtk: Build documentation.

Message ID 7a7d7d3f55e09e8922c77cb05a394aa32f1904f6.1695478390.git.mirai@makinata.eu
State New
Headers show
Series Docbook & XML/SGML improvements. | expand

Commit Message

Bruno Victal Sept. 23, 2023, 2:20 p.m. UTC
* gnu/packages/freedesktop.scm (colord-gtk): Build documentation.
[arguments]<#:configure-flags>: Remove.
<#:phases>: Add 'split-package phase.
[native-inputs]: Add docbook-xsl, gtk-doc/stable and libxslt.
[outputs]: Add 'doc output.
---
 gnu/packages/freedesktop.scm | 21 ++++++++++++++++-----
 1 file changed, 16 insertions(+), 5 deletions(-)
diff mbox series

Patch

diff --git a/gnu/packages/freedesktop.scm b/gnu/packages/freedesktop.scm
index bb47d2311f..04b9ac3fd0 100644
--- a/gnu/packages/freedesktop.scm
+++ b/gnu/packages/freedesktop.scm
@@ -2020,13 +2020,23 @@  (define-public colord-gtk
                (base32
                 "1l61ydb0zv2ffilwpapgz5mm3bznr28zl16xqbxnz6kdsrb6cimr"))))
     (build-system meson-build-system)
-    (arguments '(#:tests? #f            ;require the colord system service
-                 ;; Building documentation fails with: "Cannot build man pages
-                 ;; without docbook-xsl-ns".
-                 #:configure-flags (list "-Ddocs=false" "-Dman=false")))
+    (arguments
+     (list
+      #:tests? #f            ;require the colord system service
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'install 'split-package
+            (lambda _
+              (let* ((old (string-append #$output "/share/gtk-doc"))
+                     (new (string-append #$output:doc "/share/gtk-doc")))
+                (mkdir-p (dirname new))
+                (rename-file old new)))))))
     (native-inputs
-     (list gettext-minimal
+     (list docbook-xsl
+           gettext-minimal
            gobject-introspection
+           gtk-doc/stable
+           libxslt
            pkg-config
            vala))
     (inputs
@@ -2034,6 +2044,7 @@  (define-public colord-gtk
     (propagated-inputs
      ;; colord-gtk.pc refers to all these.
      (list colord gtk))
+    (outputs (list "out" "doc"))
     (synopsis "GTK integration for libcolord")
     (home-page "https://www.freedesktop.org/software/colord/")
     (description