diff mbox series

[bug#49010,core-updates] gnu: custom-gcc: Update regex for removing executables.

Message ID 20210613210125.24907-1-iskarian@mgsn.dev
State Accepted
Headers show
Series [bug#49010,core-updates] gnu: custom-gcc: Update regex for removing executables. | expand

Checks

Context Check Description
cbaines/applying patch fail View Laminar job
cbaines/issue success View issue

Commit Message

Sarah Morgensen June 13, 2021, 9:01 p.m. UTC
Do not match "gccgo". Match "gcov-dump" and "gcov-tool", as well as
"lto-dump" (which was introduced in GCC 10).

* gnu/packages/gcc.scm (custom-gcc)[arguments]: Update regex used for
matching broken or conflicting executables.
---
 gnu/packages/gcc.scm | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

Comments

Ludovic Courtès July 5, 2021, 11:12 a.m. UTC | #1
Hi,

Sarah Morgensen <iskarian@mgsn.dev> skribis:

> Do not match "gccgo". Match "gcov-dump" and "gcov-tool", as well as
> "lto-dump" (which was introduced in GCC 10).
>
> * gnu/packages/gcc.scm (custom-gcc)[arguments]: Update regex used for
> matching broken or conflicting executables.

Applied to ‘core-updates’.

Thanks, and sorry for the delay!

Ludo’.
diff mbox series

Patch

diff --git a/gnu/packages/gcc.scm b/gnu/packages/gcc.scm
index 5d114dca87..621b4a1200 100644
--- a/gnu/packages/gcc.scm
+++ b/gnu/packages/gcc.scm
@@ -716,9 +716,10 @@  as the 'native-search-paths' field."
         `(modify-phases ,phases
            (add-after 'install 'remove-broken-or-conflicting-files
              (lambda* (#:key outputs #:allow-other-keys)
-               (for-each delete-file
-                         (find-files (string-append (assoc-ref outputs "out") "/bin")
-                                     ".*(c\\+\\+|cpp|g\\+\\+|gcov|gcc|gcc-.*)"))))))))))
+               (for-each
+                delete-file
+                (find-files (string-append (assoc-ref outputs "out") "/bin")
+                            ".*(c\\+\\+|cpp|g\\+\\+|gcov|gcc|lto)(-.*)?$"))))))))))
 
 (define %generic-search-paths
   ;; This is the language-neutral search path for GCC.  Entries in $CPATH are