diff mbox series

[bug#60640] Gnu: Add gdcm

Message ID 87bkn1m4dj.fsf@gmail.com
State New
Headers show
Series [bug#60640] Gnu: Add gdcm | expand

Commit Message

Tor-björn Claesson Jan. 14, 2023, 5:06 p.m. UTC
And here is a second patch adding documentation to gdcm 3.0.20
Cheers,
Tor-björn Claesson

Comments

Ludovic Courtès Jan. 17, 2023, 2:38 p.m. UTC | #1
Tor-björn Claesson <tclaesson@gmail.com> skribis:

> From 9ec1adbf72f3b122a484fe449e3b950fcee4b221 Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?Tor-bj=C3=B6rn=20Claesson?= <tclaesson@gmail.com>
> Date: Sat, 14 Jan 2023 19:03:39 +0200
> Subject: [PATCH] gnu: gdcm: Add documentation.
>
> ---
>  gnu/packages/bioinformatics.scm | 17 ++++++++++++++++-
>  1 file changed, 16 insertions(+), 1 deletion(-)

[...]

> +              "-DGDCM_DOCUMENTATION:BOOL=ON"
> +              "-DGDCM_PDF_DOCUMENTATION:BOOL=ON"
> +              (string-append "-DGDCM_INSTALL_DOC_DIR="
> +                             #$output:doc "/share/doc/" #$name)
> +              "-DGDCM_BUILD_DOCBOOK_MANPAGES:BOOL=OFF"))) ; TODO: need ‘xsl-ns’
> +    (native-inputs (list doxygen ghostscript graphviz texlive))

In general, we don’t install documentation as PDF/PS, unless there’s no
other choice (preferred formats are Info, man pages, and HTML).

Is there such an option?

Furthermore, we shouldn’t depend on ‘texlive’, which is the big
monolithic package:

  https://guix.gnu.org/manual/devel/en/html_node/Using-TeX-and-LaTeX.html

Could you send an updated patch?

Ludo’.
Tor-björn Claesson Jan. 20, 2023, 11:30 a.m. UTC | #2
Hi,

Den tis 17 jan. 2023 kl 16:38 skrev Ludovic Courtès <ludo@gnu.org>:

>
> In general, we don’t install documentation as PDF/PS, unless there’s no
> other choice (preferred formats are Info, man pages, and HTML).
>
> Is there such an option?
>
The new version of the patch builds HTML documentation, but not man-pages
(because of a xsl-requirement and including libxslt as a native input
causes the build to fail.)

I wrote the previous answer in a rush, and failed to properly address this
question. For this I apologize, it was not meant to be disrespectful.

Tor-björn
diff mbox series

Patch

From 9ec1adbf72f3b122a484fe449e3b950fcee4b221 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tor-bj=C3=B6rn=20Claesson?= <tclaesson@gmail.com>
Date: Sat, 14 Jan 2023 19:03:39 +0200
Subject: [PATCH] gnu: gdcm: Add documentation.

---
 gnu/packages/bioinformatics.scm | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 5b886526ad..aa54ec7ff7 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -93,6 +93,7 @@  (define-module (gnu packages bioinformatics)
   #:use-module (gnu packages gawk)
   #:use-module (gnu packages gcc)
   #:use-module (gnu packages gd)
+  #:use-module (gnu packages ghostscript)
   #:use-module (gnu packages golang)
   #:use-module (gnu packages glib)
   #:use-module (gnu packages graph)
@@ -17854,8 +17855,16 @@  (define-public gdcm
                (base32
                 "1w78cmm9q7aavs7svdkl4dgilcqk4yazci9m6x7icrssb7cj991i"))))
     (build-system cmake-build-system)
+    (outputs '("out" "doc"))
     (arguments
      (list
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-before 'build 'set-HOME
+                 ;; The build spams ‘Fontconfig error: No writable cache
+                 ;; directories’ in a seemingly endless loop otherwise.
+                 (lambda _
+                   (setenv "HOME" "/tmp"))))
       #:configure-flags
       #~(list "-DGDCM_BUILD_TESTING=true"
               (string-append "-DCMAKE_CTEST_ARGUMENTS=-E;"
@@ -17863,7 +17872,13 @@  (define-public gdcm
                              "|TestElement2"
                              "|TestSCUValidation"
                              "|TestEcho"
-                             "|TestFind'"))))
+                             "|TestFind'")
+              "-DGDCM_DOCUMENTATION:BOOL=ON"
+              "-DGDCM_PDF_DOCUMENTATION:BOOL=ON"
+              (string-append "-DGDCM_INSTALL_DOC_DIR="
+                             #$output:doc "/share/doc/" #$name)
+              "-DGDCM_BUILD_DOCBOOK_MANPAGES:BOOL=OFF"))) ; TODO: need ‘xsl-ns’
+    (native-inputs (list doxygen ghostscript graphviz texlive))
     (home-page "https://gdcm.sourceforge.net/wiki/index.php/Main_Page")
     (synopsis "Grassroots DICOM library")
     (description
-- 
2.38.1