all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: 59313-done@debbugs.gnu.org, mail@cbaines.net
Subject: bug#59313: [PATCH] gnu: linux-libre: Enable building html and info doc.
Date: Thu, 24 Nov 2022 16:37:30 -0500	[thread overview]
Message-ID: <87edtskp9h.fsf@gmail.com> (raw)
In-Reply-To: <877cznjxl5.fsf_-_@gnu.org> ("Ludovic Courtès"'s message of "Tue, 22 Nov 2022 07:46:14 +0100")

Hi Ludo,

Ludovic Courtès <ludo@gnu.org> writes:

> Hi Maxim,
>
> Maxim Cournoyer <maxim.cournoyer@gmail.com> skribis:
>
>> * gnu/packages/patches/linux-libre-infodocs-target.patch: New file.
>> * gnu/local.mk (dist_patch_DATA): Register it.
>> (linux-libre-6.0-source, linux-libre-5.15-source)
>> (linux-libre-5.10-source): Apply above patch.
>> (doc-supported?):
>
> Looks like these 3 lines are misplaced.

Fixed.

>
>> * gnu/packages/linux.scm (make-linux-libre) [DOC-SUPPORTED?]: Add new patch in
>> the default patches used.  Add a BUILD-DOC? argument.
>> (make-linux-libre*): Add a BUILD-DOC? argument.  Validate BUILD-DOC? for
>> supported VERSION.
>> [outputs]: New field.
>> [phases]: Conditionally add the build-doc and install-doc phases.
>
> Nitpick: I’d write “[arguments]” rather than “[phases]”.

Adjusted.

>> [native-inputs]: Conditionally add fontconfig, graphviz, python-wrapper,
>> python-sphinx, python-sphinx-rtd-theme, texinfo and which.
>
> [...]
>
>> +                 #~((add-before 'configure 'build-doc
>> +                      (lambda _
>> +                        (substitute* "Documentation/Makefile"
>> +                          ;; Remove problematic environment check script.
>> +                          ((".*scripts/sphinx-pre-install.*") ""))
>> +                        (invoke "make" "infodocs" "htmldocs")))
>> +                    (add-after 'build-doc 'install-doc
>> +                      (lambda _
>> +                        (with-directory-excursion "Documentation/output"
>> +                          (let ((docdir (string-append
>> +                                         #$output:doc
>> +                                         "/share/doc/linux-libre/html")))
>> +                            (mkdir-p docdir)
>> +                            (copy-recursively "html" docdir))
>> +                          (invoke "make" "-C" "texinfo" "install-info"
>> +                                  (string-append "infodir=" #$output
>> +                                                 "/share/info"))))))
>
> I would keep only Info documentation, which is much smaller than HTML.
> This is what we do for every packages where we have that possibility.

Done, like this:

--8<---------------cut here---------------start------------->8---
modified   gnu/packages/linux.scm
@@ -815,8 +815,6 @@ (define* (make-linux-libre* version gnu-revision source supported-systems
     (version version)
     (source source)
     (supported-systems supported-systems)
-    (outputs `("out"
-               ,@(if build-doc? '("doc") '())))
     (build-system gnu-build-system)
     (arguments
      (list
@@ -840,15 +838,10 @@ (define* (make-linux-libre* version gnu-revision source supported-systems
                         (substitute* "Documentation/Makefile"
                           ;; Remove problematic environment check script.
                           ((".*scripts/sphinx-pre-install.*") ""))
-                        (invoke "make" "infodocs" "htmldocs")))
+                        (invoke "make" "infodocs")))
                     (add-after 'build-doc 'install-doc
                       (lambda _
                         (with-directory-excursion "Documentation/output"
-                          (let ((docdir (string-append
-                                         #$output:doc
-                                         "/share/doc/linux-libre/html")))
-                            (mkdir-p docdir)
-                            (copy-recursively "html" docdir))
                           (invoke "make" "-C" "texinfo" "install-info"
                                   (string-append "infodir=" #$output
                                                  "/share/info"))))))
--8<---------------cut here---------------end--------------->8---

(as well as python-sphinx-rtd, not shown above) and pushed.

Thanks for the review!

-- 
Thanks,
Maxim




  parent reply	other threads:[~2022-11-24 21:46 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-16 16:55 [bug#59313] [PATCH] gnu: linux-libre: Enable building html and info doc Maxim Cournoyer
2022-11-20 11:31 ` Christopher Baines
2022-11-21  0:57   ` Maxim Cournoyer
2022-11-21  1:03   ` [bug#59313] [PATCH v2] " Maxim Cournoyer
2022-11-22  6:46     ` [bug#59313] [PATCH] " Ludovic Courtès
2022-11-22  6:49       ` ( via Guix-patches via
2022-11-22 10:32         ` Maxim Cournoyer
2022-11-24 21:37       ` Maxim Cournoyer [this message]
2023-02-26  2:21 ` bug#61798: infodoc patch doesn't apply to linux 6.2 Leo Famulari
2023-02-26  4:23   ` Maxim Cournoyer
2023-02-26 17:38     ` Leo Famulari
2023-02-27 13:40       ` Maxim Cournoyer
2023-03-04  0:34         ` Leo Famulari

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87edtskp9h.fsf@gmail.com \
    --to=maxim.cournoyer@gmail.com \
    --cc=59313-done@debbugs.gnu.org \
    --cc=ludo@gnu.org \
    --cc=mail@cbaines.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.