Subject: Re: [bug#40362] [PATCH] gnu: cross-base: Add mingw-w64 specific binutils patches.

From: Mathieu Othacehe <[email-masked]>
Date: Thu, 02 Apr 2020 11:45:08 +0200

Hey,

> I named it this way to make it clear that PACKAGE-WITH-PATCH overrides the
> patches, whereas PACKAGE-WITH-EXTRA-PATCHES appends the patches (just like
> PACKAGE-WITH-EXTRA-CONFIGURE-VARIABLE)... In fact, I'm not sure that Ludovic
> originally intended PACKAGE-WITH-PATCH to override rather than append?

Well I'm also unsure, but yes it makes sense to name it this way then!

> See the updated patch below, is this the right solution?

In general, its preferred to send one of the procedure call to the next
line and let Emacs indent everything. Like this:

--8<---------------cut here---------------start------------->8---
    (cross (cond ((string-prefix? "xtensa-" target)
                  (package-with-patch binutils
                                      (search-patch
                                       "ath9k-htc-firmware-binutils.patch")))
                 ((target-mingw? target)
                  (package-with-extra-patches
                   binutils
                   (search-patches
                    "binutils-mingw-w64-specify-timestamp.patch"
                    "binutils-mingw-w64-reproducible-import-libraries.patch")))
                 (else binutils))
           target)))
--8<---------------cut here---------------end--------------->8---

This patch will trigger a rebuild of all cross-compiled packages, so it
would be better to send it to core-updates maybe? And as core-updates
has been frozen a few days ago, you may need to wait for
core-updates-next to open.

Thanks,

Mathieu