all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#57960] [PATCH core-updates] gnu: libxkbcommon: Switch to gexp; adjust style.
@ 2022-09-20 19:23 Felix Lechner via Guix-patches via
  2022-09-21  9:03 ` Liliana Marie Prikler
  0 siblings, 1 reply; 7+ messages in thread
From: Felix Lechner via Guix-patches via @ 2022-09-20 19:23 UTC (permalink / raw)
  To: 57960

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

Hi,

This modernizes the package declaration for libxkbcommon by using
G-expressions. Also, input folders are found via their expected
relative paths (i.e. the modern way) instead of the input label. The
latter was an issue when the official xkeyboard-config was replaced
with a customized package holding additional keyboard layouts.

Ultimately reaches 3435 packages and thus belongs into core-updates.

Kind regards
Felix Lechner

[-- Attachment #2: 0001-gnu-libxkbcommon-Switch-to-gexp-adjust-style.patch --]
[-- Type: text/x-patch, Size: 3403 bytes --]

From 81ffbadce5c31f447fce7970908a51d483753b14 Mon Sep 17 00:00:00 2001
From: Felix Lechner <felix.lechner@lease-up.com>
Date: Tue, 20 Sep 2022 09:47:35 -0700
Subject: [PATCH] gnu: libxkbcommon: Switch to gexp; adjust style.

* gnu/packages/xdisorg.scm (libxkbcommon): Switch to gexp; adjust
style throughout.
[arguments]: Avoid hardcoding inputs; locate inputs via relative
paths, i.e. the modern way.
---
 gnu/packages/xdisorg.scm | 47 ++++++++++++++++++++--------------------
 1 file changed, 24 insertions(+), 23 deletions(-)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index 02e04ccf88..aeacdf8743 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -488,33 +488,34 @@ (define-public libxkbcommon
     (name "libxkbcommon")
     (version "1.3.0")
     (source (origin
-             (method url-fetch)
-             (uri (string-append "https://xkbcommon.org/download/libxkbcommon-"
-                                 version ".tar.xz"))
-             (sha256
-              (base32
-               "0ysynzzgzd9jdrh1321r4bgw8wd5zljrlyn5y1a31g39xacf02bv"))))
+              (method url-fetch)
+              (uri (string-append
+                    "https://xkbcommon.org/download/libxkbcommon-" version
+                    ".tar.xz"))
+              (sha256
+               (base32
+                "0ysynzzgzd9jdrh1321r4bgw8wd5zljrlyn5y1a31g39xacf02bv"))))
     (build-system meson-build-system)
-    (inputs
-     (list libx11
-           libxcb
-           libxml2
-           wayland
-           wayland-protocols
-           xkeyboard-config))
-    (native-inputs
-     (list bison doxygen pkg-config python))
+    (inputs (list libx11
+                  libxcb
+                  libxml2
+                  wayland
+                  wayland-protocols
+                  xkeyboard-config))
+    (native-inputs (list bison doxygen pkg-config python))
     (arguments
-     `(#:configure-flags
-       (list (string-append "-Dxkb-config-root="
-                            (assoc-ref %build-inputs "xkeyboard-config")
-                            "/share/X11/xkb")
-             (string-append "-Dx-locale-root="
-                            (assoc-ref %build-inputs "libx11")
-                            "/share/X11/locale"))))
+     (list #:configure-flags #~(list (string-append "-Dxkb-config-root="
+                                                    (search-input-directory
+                                                     %build-inputs
+                                                     "share/X11/xkb"))
+                                     (string-append "-Dx-locale-root="
+                                                    (search-input-directory
+                                                     %build-inputs
+                                                     "share/X11/locale")))))
     (home-page "https://xkbcommon.org/")
     (synopsis "Library to handle keyboard descriptions")
-    (description "Xkbcommon is a library to handle keyboard descriptions,
+    (description
+     "Xkbcommon is a library to handle keyboard descriptions,
 including loading them from disk, parsing them and handling their
 state.  It is mainly meant for client toolkits, window systems, and other
 system applications; currently that includes Wayland, kmscon, GTK+, Qt,

base-commit: 28918b4ff8d2c297d1f1fb84eebdca9fc2dc9303
-- 
2.37.3


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

* [bug#57960] [PATCH core-updates] gnu: libxkbcommon: Switch to gexp; adjust style.
  2022-09-20 19:23 [bug#57960] [PATCH core-updates] gnu: libxkbcommon: Switch to gexp; adjust style Felix Lechner via Guix-patches via
@ 2022-09-21  9:03 ` Liliana Marie Prikler
  2022-09-21 10:16   ` Felix Lechner via Guix-patches via
  0 siblings, 1 reply; 7+ messages in thread
From: Liliana Marie Prikler @ 2022-09-21  9:03 UTC (permalink / raw)
  To: Felix Lechner, 57960

Am Dienstag, dem 20.09.2022 um 12:23 -0700 schrieb Felix Lechner:

> +              (method url-fetch)
> +              (uri (string-append
> +                    "https://xkbcommon.org/download/libxkbcommon-"
> version
> +                    ".tar.xz"))


> -    (inputs
> -     (list libx11
> -           libxcb
> -           libxml2
> -           wayland
> -           wayland-protocols
> -           xkeyboard-config))
> -    (native-inputs
> -     (list bison doxygen pkg-config python))
> +    (inputs (list libx11
> +                  libxcb
> +                  libxml2
> +                  wayland
> +                  wayland-protocols
> +                  xkeyboard-config))
> +    (native-inputs (list bison doxygen pkg-config python))
Try to avoid mixing cosmetic and non-cosmetic changes.

> +     (list #:configure-flags #~(list (string-append "-Dxkb-config-
> root="
> +                                                    (search-input-
> directory
> +                                                     %build-inputs
> +                                                    
> "share/X11/xkb"))
> +                                     (string-append "-Dx-locale-
> root="
> +                                                    (search-input-
> directory
> +                                                     %build-inputs
> +                                                     
> "share/X11/locale")))))
I am very sure the formatter isn't doing the best job here.

> -    (description "Xkbcommon is a library to handle keyboard
> descriptions,
> +    (description
> +     "Xkbcommon is a library to handle keyboard descriptions,
This change is unnecessary.

Cheers




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

* [bug#57960] [PATCH core-updates] gnu: libxkbcommon: Switch to gexp; adjust style.
  2022-09-21  9:03 ` Liliana Marie Prikler
@ 2022-09-21 10:16   ` Felix Lechner via Guix-patches via
  2022-09-21 11:28     ` Liliana Marie Prikler
  2022-10-02 20:43     ` Ludovic Courtès
  0 siblings, 2 replies; 7+ messages in thread
From: Felix Lechner via Guix-patches via @ 2022-09-21 10:16 UTC (permalink / raw)
  To: 57960; +Cc: Liliana Marie Prikler

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

Hi,

On Wed, Sep 21, 2022 at 2:03 AM Liliana Marie Prikler
<liliana.prikler@ist.tugraz.at> wrote:
>
> Try to avoid mixing cosmetic and non-cosmetic changes.

Thanks for the suggestion! I did last time [1] but the core-updates
maintainer seemed to prefer otherwise. [2]

In addition, I was not sure whether to use the formatter from the
'master' branch or from 'core-updates', or whether it made a
difference.

A patch without 'guix style' is attached to this message.

As a side note, my position is that 'guix style' should be applied to
the code base whenever the formatter is changed, and not when
functional changes are being submitted by individual contributors.

[1] https://debbugs.gnu.org/cgi/bugreport.cgi?bug=57872#5
[2] https://debbugs.gnu.org/cgi/bugreport.cgi?bug=57872#10

> the formatter isn't doing the best job here.

Do I have a choice? I believe there is a requirement to run 'guix
style' when submitting patches. [3]

[3] https://guix.gnu.org/en/manual/devel/en/html_node/Submitting-Patches.html

> This change is unnecessary.

I respectfully agree. The formatter made that change, too.

Kind regards
Felix Lechner

[-- Attachment #2: 0001-gnu-libxkbcommon-Switch-to-gexp-avoid-hardcoding-inp.patch --]
[-- Type: application/x-patch, Size: 1775 bytes --]

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

* [bug#57960] [PATCH core-updates] gnu: libxkbcommon: Switch to gexp; adjust style.
  2022-09-21 10:16   ` Felix Lechner via Guix-patches via
@ 2022-09-21 11:28     ` Liliana Marie Prikler
  2022-10-02 20:43     ` Ludovic Courtès
  1 sibling, 0 replies; 7+ messages in thread
From: Liliana Marie Prikler @ 2022-09-21 11:28 UTC (permalink / raw)
  To: Felix Lechner, 57960

Am Mittwoch, dem 21.09.2022 um 03:16 -0700 schrieb Felix Lechner:
> Hi,
> 
> On Wed, Sep 21, 2022 at 2:03 AM Liliana Marie Prikler
> <liliana.prikler@ist.tugraz.at> wrote:
> > 
> > Try to avoid mixing cosmetic and non-cosmetic changes.
> 
> Thanks for the suggestion! I did last time [1] but the core-updates
> maintainer seemed to prefer otherwise. [2]
I don't think this was a preference; rather a workaround for some issue
arising in the git workflow (which can happen).

> In addition, I was not sure whether to use the formatter from the
> 'master' branch or from 'core-updates', or whether it made a
> difference.
The answer is "don't change surrounding code", which holds regardless
of the formatter you choose.  I do believe the one on master would be
updated more often, though.

> As a side note, my position is that 'guix style' should be applied to
> the code base whenever the formatter is changed, and not when
> functional changes are being submitted by individual contributors.
I disagree on the basis that the styler is very much not perfect yet
and still causes more issues than not on almost every patch I've so far
reviewed.  There's unfortunately a long way to go before we can mandate
code style. 

> > the formatter isn't doing the best job here.
> 
> Do I have a choice? I believe there is a requirement to run 'guix
> style' when submitting patches. [3]
> 
> [3]
> https://guix.gnu.org/en/manual/devel/en/html_node/Submitting-Patches.html
Most reviewers, myself included, would rather prefer you simply mark
the region/package with Emacs and hit TAB.  However, not all packagers
prefer writing their code in Emacs, hence we tell them to use this
tool, which captures the letter, but sadly not the essence, of the
Scheme coding style.

Cheers
> 




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

* [bug#57960] [PATCH core-updates] gnu: libxkbcommon: Switch to gexp; adjust style.
  2022-09-21 10:16   ` Felix Lechner via Guix-patches via
  2022-09-21 11:28     ` Liliana Marie Prikler
@ 2022-10-02 20:43     ` Ludovic Courtès
  2022-10-03  6:11       ` Liliana Marie Prikler
  1 sibling, 1 reply; 7+ messages in thread
From: Ludovic Courtès @ 2022-10-02 20:43 UTC (permalink / raw)
  To: Felix Lechner; +Cc: 57960, Liliana Marie Prikler

Hi Felix,

Felix Lechner <felix.lechner@lease-up.com> skribis:

> From f07e9206be342f3e9769fe3dc14124b14444f139 Mon Sep 17 00:00:00 2001
> From: Felix Lechner <felix.lechner@lease-up.com>
> Date: Tue, 20 Sep 2022 09:47:35 -0700
> Subject: [PATCH] gnu: libxkbcommon: Switch to gexp; avoid hardcoding inputs.
>
> * gnu/packages/xdisorg.scm (libxkbcommon): Switch to gexp.
> [arguments]: Avoid hardcoding inputs and locate them via relative
> paths instead.

Applied, thanks!

As a rule of thumb I agree that formatting changes should not be lumped
together with other changes as that can hinder review.

Regardless, I think a patch like this one should not be blocked for
weeks for such tiny issues.  Insisting on a rigorous process and
conventions is important when it helps us all work together, but it’s a
problem when it hinders cooperation.  As reviewers, we must strike for a
balance that’s reasonable for everyone involved.

Ludo’.




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

* [bug#57960] [PATCH core-updates] gnu: libxkbcommon: Switch to gexp; adjust style.
  2022-10-02 20:43     ` Ludovic Courtès
@ 2022-10-03  6:11       ` Liliana Marie Prikler
  2022-10-03 10:02         ` Ludovic Courtès
  0 siblings, 1 reply; 7+ messages in thread
From: Liliana Marie Prikler @ 2022-10-03  6:11 UTC (permalink / raw)
  To: Ludovic Courtès, Felix Lechner; +Cc: 57960

Am Sonntag, dem 02.10.2022 um 22:43 +0200 schrieb Ludovic Courtès:
> Regardless, I think a patch like this one should not be blocked for
> weeks for such tiny issues.
Note, that this patch wasn't blocked for this issue, but because I
failed to notice the attachment in which it was already addressed. 
Sometimes, I miss those.

Cheers




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

* [bug#57960] [PATCH core-updates] gnu: libxkbcommon: Switch to gexp; adjust style.
  2022-10-03  6:11       ` Liliana Marie Prikler
@ 2022-10-03 10:02         ` Ludovic Courtès
  0 siblings, 0 replies; 7+ messages in thread
From: Ludovic Courtès @ 2022-10-03 10:02 UTC (permalink / raw)
  To: Liliana Marie Prikler; +Cc: 57960, Felix Lechner

Hi Liliana,

Liliana Marie Prikler <liliana.prikler@ist.tugraz.at> skribis:

> Am Sonntag, dem 02.10.2022 um 22:43 +0200 schrieb Ludovic Courtès:
>> Regardless, I think a patch like this one should not be blocked for
>> weeks for such tiny issues.
> Note, that this patch wasn't blocked for this issue, but because I
> failed to notice the attachment in which it was already addressed. 
> Sometimes, I miss those.

I see, apologies for misrepresenting the situation then.

Thanks,
Ludo’.




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

end of thread, other threads:[~2022-10-03 10:08 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-20 19:23 [bug#57960] [PATCH core-updates] gnu: libxkbcommon: Switch to gexp; adjust style Felix Lechner via Guix-patches via
2022-09-21  9:03 ` Liliana Marie Prikler
2022-09-21 10:16   ` Felix Lechner via Guix-patches via
2022-09-21 11:28     ` Liliana Marie Prikler
2022-10-02 20:43     ` Ludovic Courtès
2022-10-03  6:11       ` Liliana Marie Prikler
2022-10-03 10:02         ` Ludovic Courtès

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.