all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Marius Bakke <mbakke@fastmail.com>
To: Danny Milosavljevic <dannym@scratchpost.org>
Cc: 25177@debbugs.gnu.org
Subject: bug#25177: [PATCH v6] gnu: python-sphinx: Update to 1.4.8.
Date: Sat, 14 Jan 2017 16:28:27 +0100	[thread overview]
Message-ID: <87ziit4q5g.fsf@kirby.i-did-not-set--mail-host-address--so-tickle-me> (raw)
In-Reply-To: <20170114145402.084adfbb@scratchpost.org>

[-- Attachment #1: Type: text/plain, Size: 3619 bytes --]

Danny Milosavljevic <dannym@scratchpost.org> writes:

> Hi,
>
> I've fixed python-matplotlib locally. It builds fine now.
>
> The fix itself would be:
>
> +                 (substitute* "users/intro.rst"
> +                   ;; Fix reST markup error (see <https://github.com/sphinx-doc/sphinx/issues/3044>)
> +                   (("[[][*][]]") "[#]"))
>
> However, I've also changed alist-cons* phase construction to modify-phases. That would make the patch look real scary.
>
> So here is a weird patch created via "git diff -b" where you can actually see what's happening without all the noise caused by indentation changes:
>
> diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
> index c540d7b5a..a5220e05e 100644
> --- a/gnu/packages/python.scm
> +++ b/gnu/packages/python.scm
> @@ -3723,8 +3723,8 @@ transcendental functions).")
>         ("texinfo" ,texinfo)))
>      (arguments
>       `(#:phases
> -       (alist-cons-before
> -        'build 'configure-environment
> +       (modify-phases %standard-phases
> +         (add-before 'build 'configure-environment
>             (lambda* (#:key outputs inputs #:allow-other-keys)
>               (let ((cairo (assoc-ref inputs "cairo"))
>                     (gtk+ (assoc-ref inputs "gtk+")))
> @@ -3740,9 +3740,8 @@ basedirlist = ~a,~a~%
>   [rc_options]~%
>  backend = TkAgg~%"
>                             (assoc-ref inputs "tcl")
> -                        (assoc-ref inputs "tk"))))))
> -        (alist-cons-after
> -         'install 'install-doc
> +                           (assoc-ref inputs "tk")))))))
> +         (add-after 'install 'install-doc
>             (lambda* (#:key inputs outputs #:allow-other-keys)
>               (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
>                      (doc (string-append data "/doc/" ,name "-" ,version))
> @@ -3756,6 +3755,9 @@ backend = TkAgg~%"
>                   (substitute* (find-files "." "conf\\.py")
>                     (("latex_paper_size = 'letter'")
>                      "latex_paper_size = 'a4'"))
> +                 (substitute* "users/intro.rst"
> +                   ;; Fix reST markup error (see <https://github.com/sphinx-doc/sphinx/issues/3044>)
> +                   (("[[][*][]]") "[#]"))
>                   (mkdir-p html)
>                   (mkdir-p info)
>                   ;; The doc recommends to run the 'html' target twice.
> @@ -3777,8 +3779,7 @@ backend = TkAgg~%"
>                   (copy-file "build/texinfo/matplotlib.info"
>                              (string-append info "/matplotlib.info"))
>                   (copy-file "build/latex/Matplotlib.pdf"
> -                          (string-append doc "/Matplotlib.pdf")))))
> -        %standard-phases))))
> +                            (string-append doc "/Matplotlib.pdf")))))))))
>      (home-page "http://matplotlib.org")
>      (synopsis "2D plotting library for Python")
>      (description
>
> Should I split this into two commits - one for modify-phases and one
> for the actual change?

Yes, please do! That's what we've done so far, try to 'git grep' for
modify-phases.

> Should I post them to the list? If so, should I mark that it's for
> python-tests somehow?

That's up to you. Typically cosmetic commits like changing to use
modify-phases are OK to just push, assuming it is followed up with a
more "meaty" commit with actual changes. Otherwise it will just cause
pointless rebuilds.

When you do change it to use modify-phases, please also check that
phases end on a #t. It should be added explicitly if the ending
statement has an unspecified return value :-)

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

  reply	other threads:[~2017-01-14 15:29 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-05 16:14 [PATCH v6] gnu: python-sphinx: Update to 1.4.8 Danny Milosavljevic
2017-01-05 16:40 ` Marius Bakke
2017-01-13 12:34   ` bug#25177: " Marius Bakke
2017-01-13 13:07     ` Danny Milosavljevic
2017-01-13 15:24     ` Leo Famulari
2017-01-14 15:35       ` Marius Bakke
2017-01-16  1:32         ` Leo Famulari
2017-01-17  0:06         ` Leo Famulari
2017-01-17  3:14       ` pre-push signature hook error reporting [was Re: [PATCH v6] gnu: python-sphinx: Update to 1.4.8.] Leo Famulari
2017-01-17 11:34         ` Danny Milosavljevic
2017-01-17 12:56           ` Hartmut Goebel
2017-01-17 19:44             ` Leo Famulari
2017-01-17 19:38           ` Leo Famulari
2017-01-17 14:55         ` Hartmut Goebel
2017-01-17 19:39           ` Leo Famulari
2017-01-20 14:05         ` Ludovic Courtès
2017-01-21  1:39           ` Leo Famulari
2017-02-06 15:39             ` pre-push signature hook error reporting Leo Famulari
2017-02-06 16:37               ` Marius Bakke
2017-02-07 13:15                 ` Ludovic Courtès
2017-01-13 22:14     ` bug#25177: [PATCH v6] gnu: python-sphinx: Update to 1.4.8 Danny Milosavljevic
2017-01-14 13:54       ` Danny Milosavljevic
2017-01-14 15:28         ` Marius Bakke [this message]
2017-01-14 21:08         ` Danny Milosavljevic

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=87ziit4q5g.fsf@kirby.i-did-not-set--mail-host-address--so-tickle-me \
    --to=mbakke@fastmail.com \
    --cc=25177@debbugs.gnu.org \
    --cc=dannym@scratchpost.org \
    /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.