all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#41033] [PATCH] gnu: libusb-0.1: fix build failure on newer gcc
@ 2020-05-02 22:47 Christopher Howard
  2020-05-03 10:58 ` Jakub Kądziołka
  0 siblings, 1 reply; 4+ messages in thread
From: Christopher Howard @ 2020-05-02 22:47 UTC (permalink / raw)
  To: 41033

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

I need libusb-0.1 to build some older software, but libusb-0.1 build
fails due to a warning from the current GCC version. (Evidently libusb-
0.1 is set to die on any warning.) The attached patch silences the
warning.

-- 
Christopher Howard
p: +1 (907) 374-0257
w: https://librehacker.com
social: https://gnusocial.club/librehacker
gpg: ADDEAADE5D607C8D (keys.gnupg.net)

[-- Attachment #2: 0001-gnu-libusb-0.1-fix-build-failure-on-newer-gcc.patch --]
[-- Type: text/x-patch, Size: 1383 bytes --]

From 351bb7004f9bbe8d50bbc7a2e2a1cb3900551e27 Mon Sep 17 00:00:00 2001
From: Christopher Howard <christopher@librehacker.com>
Date: Sat, 2 May 2020 14:41:00 -0800
Subject: [PATCH] gnu: libusb-0.1: fix build failure on newer gcc

Package build fails on truncation warning from current gcc. Silences
this warning.
---
 gnu/packages/libusb.scm | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/libusb.scm b/gnu/packages/libusb.scm
index 01c138cb4e..3bb2dcd186 100644
--- a/gnu/packages/libusb.scm
+++ b/gnu/packages/libusb.scm
@@ -8,6 +8,7 @@
 ;;; Copyright © 2017 Jonathan Brielmaier <jonathan.brielmaier@web.de>
 ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
 ;;; Copyright © 2018 Vagrant Cascadian <vagrant@debian.org>
+;;; Copyright © 2020 Christopher Howard <christopher@librehacker.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -113,7 +114,8 @@ version of libusb to run with newer libusb.")
       (sha256
        (base32
         "0i4bacxkyr7xyqxbmb00ypkrv4swkgm0mghbzjsnw6blvvczgxip"))
-      (patches (search-patches "libusb-0.1-disable-tests.patch"))))))
+      (patches (search-patches "libusb-0.1-disable-tests.patch"))))
+    (arguments `(#:configure-flags (list "CFLAGS=-Wno-format-truncation")))))
 
 (define-public libusb4java
   ;; There is no public release so we take the latest version from git.
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#41033] [PATCH] gnu: libusb-0.1: fix build failure on newer gcc
  2020-05-02 22:47 [bug#41033] [PATCH] gnu: libusb-0.1: fix build failure on newer gcc Christopher Howard
@ 2020-05-03 10:58 ` Jakub Kądziołka
  2020-05-03 16:13   ` Christopher Howard
  0 siblings, 1 reply; 4+ messages in thread
From: Jakub Kądziołka @ 2020-05-03 10:58 UTC (permalink / raw)
  To: Christopher Howard; +Cc: 41033

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

On Sat, May 02, 2020 at 02:47:56PM -0800, Christopher Howard wrote:
> I need libusb-0.1 to build some older software, but libusb-0.1 build
> fails due to a warning from the current GCC version. (Evidently libusb-
> 0.1 is set to die on any warning.) The attached patch silences the
> warning.

Thanks for your patch! I'm wondering though, whether it wouldn't be more
resilient to add a -Wno-error flag instead. After all, the compiler is
going to get upgraded sooner or later, which will introduce new
warnings, and libusb 0.1 isn't getting any upgrades...

A quick grep suggests that this wouldn't be the first package to disable
Werror. Makes sense, since this mode is mostly useful to developers, and
not packagers.

What do you think?

Kind regards,
Jakub Kądziołka

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

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#41033] [PATCH] gnu: libusb-0.1: fix build failure on newer gcc
  2020-05-03 10:58 ` Jakub Kądziołka
@ 2020-05-03 16:13   ` Christopher Howard
  2020-05-03 20:56     ` bug#41033: " Jakub Kądziołka
  0 siblings, 1 reply; 4+ messages in thread
From: Christopher Howard @ 2020-05-03 16:13 UTC (permalink / raw)
  To: Jakub Kądziołka; +Cc: 41033

Sounds good to me. Can you make the edit to the patch?

-- 
Christopher Howard
p: +1 (907) 374-0257
w: https://librehacker.com
social: https://gnusocial.club/librehacker
gpg: ADDEAADE5D607C8D (keys.gnupg.net)

On Sun, 2020-05-03 at 12:58 +0200, Jakub Kądziołka wrote:
> On Sat, May 02, 2020 at 02:47:56PM -0800, Christopher Howard wrote:
> > I need libusb-0.1 to build some older software, but libusb-0.1
> > build
> > fails due to a warning from the current GCC version. (Evidently
> > libusb-
> > 0.1 is set to die on any warning.) The attached patch silences the
> > warning.
> 
> Thanks for your patch! I'm wondering though, whether it wouldn't be
> more
> resilient to add a -Wno-error flag instead. After all, the compiler
> is
> going to get upgraded sooner or later, which will introduce new
> warnings, and libusb 0.1 isn't getting any upgrades...
> 
> A quick grep suggests that this wouldn't be the first package to
> disable
> Werror. Makes sense, since this mode is mostly useful to developers,
> and
> not packagers.
> 
> What do you think?
> 
> Kind regards,
> Jakub Kądziołka





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#41033: [PATCH] gnu: libusb-0.1: fix build failure on newer gcc
  2020-05-03 16:13   ` Christopher Howard
@ 2020-05-03 20:56     ` Jakub Kądziołka
  0 siblings, 0 replies; 4+ messages in thread
From: Jakub Kądziołka @ 2020-05-03 20:56 UTC (permalink / raw)
  To: Christopher Howard; +Cc: 41033-done

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

On Sun, May 03, 2020 at 08:13:32AM -0800, Christopher Howard wrote:
> Sounds good to me. Can you make the edit to the patch?

Sure! I pushed the modified patch:

commit 96e399ee30251a0767a45b2bde3f052b25c62714 (HEAD -> master, upstream/master)
Author: Christopher Howard <christopher@librehacker.com>
Date:   Sat May 2 14:41:00 2020 -0800

    gnu: libusb-0.1: fix build failure on newer gcc

    * gnu/packages/libusb.scm (libusb-0.1): Disable -Werror.

    Signed-off-by: Jakub Kądziołka <kuba@kadziolka.net>

Cheers!

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

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-05-03 20:57 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-02 22:47 [bug#41033] [PATCH] gnu: libusb-0.1: fix build failure on newer gcc Christopher Howard
2020-05-03 10:58 ` Jakub Kądziołka
2020-05-03 16:13   ` Christopher Howard
2020-05-03 20:56     ` bug#41033: " Jakub Kądziołka

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.