all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#68573] [PATCH gnome-team] gnu: sdbus-c++: Fix generated sdbus-c++.pc.
@ 2024-01-18 21:14 Vivien Kraus via Guix-patches via
  2024-01-20  7:35 ` Liliana Marie Prikler
  0 siblings, 1 reply; 5+ messages in thread
From: Vivien Kraus via Guix-patches via @ 2024-01-18 21:14 UTC (permalink / raw)
  To: 68573; +Cc: liliana.prikler, maxim.cournoyer, rg, vivien

* gnu/packages/glib.scm (sdbus-c++) [#:phases 'fix-libelogind-requirement]:
New phase.

Change-Id: Id29369178f164fc60e6882aa664556924cf4bfa7
---
 gnu/packages/glib.scm | 19 ++++++++++++++-----
 1 file changed, 14 insertions(+), 5 deletions(-)

diff --git a/gnu/packages/glib.scm b/gnu/packages/glib.scm
index 7b8cc3286d..d84b848b62 100644
--- a/gnu/packages/glib.scm
+++ b/gnu/packages/glib.scm
@@ -1289,11 +1289,20 @@ (define-public sdbus-c++
                                 ;; Do not install tests.
                                 "-DTESTS_INSTALL_PATH=/tmp"
                                 "-DCMAKE_VERBOSE_MAKEFILE=ON")
-      #:phases #~(modify-phases %standard-phases
-                   (add-after 'unpack 'do-not-install-tests
-                     (lambda _
-                       (substitute* "tests/CMakeLists.txt"
-                         (("/etc/dbus-1/system.d") "/tmp")))))))
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'unpack 'do-not-install-tests
+            (lambda _
+              (substitute* "tests/CMakeLists.txt"
+                (("/etc/dbus-1/system.d") "/tmp"))))
+          (add-before 'install 'fix-libelogind-requirement
+            (lambda _
+              ;; sdbus-c++.pc requires 'elogind', but it should
+              ;; require 'libelogind'. Fixed after 1.4.0 with
+              ;; fb9e4ae37152648a67814458d3ff673b1d3ca089
+              (substitute* "pkgconfig/sdbus-c++.pc"
+                (("Requires: elogind")
+                 "Requires: libelogind")))))))
     (native-inputs (list googletest pkg-config))
     (inputs (list expat))
     (propagated-inputs (list elogind)) ;required by sdbus-c++.pc

base-commit: 17c2e26068c5c36eb8ee1ec39a8695ef66f75c55
-- 
2.41.0




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

* [bug#68573] [PATCH gnome-team v2] gnu: sdbus-c++: Fix generated sdbus-c++.pc.
  2024-01-20  7:35 ` Liliana Marie Prikler
@ 2024-01-18 21:14   ` Vivien Kraus via Guix-patches via
  2024-01-20 18:30     ` Maxim Cournoyer
  2024-01-25 15:33     ` bug#68573: " Liliana Marie Prikler
  0 siblings, 2 replies; 5+ messages in thread
From: Vivien Kraus via Guix-patches via @ 2024-01-18 21:14 UTC (permalink / raw)
  To: liliana.prikler, 68573; +Cc: rg, maxim.cournoyer

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2604 bytes --]

* gnu/packages/glib.scm (sdbus-c++) [#:phases]: Add 'fix-elogind-requirement.

Change-Id: Id29369178f164fc60e6882aa664556924cf4bfa7
---
Hello!

Le samedi 20 janvier 2024 à 08:35 +0100, Liliana Marie Prikler a écrit :
> +              ;; sdbus-c++.pc requires 'elogind', but it should
> +              ;; require 'libelogind'. Fixed after 1.4.0 with
> +              ;; fb9e4ae37152648a67814458d3ff673b1d3ca089
> +              (substitute* "pkgconfig/sdbus-c++.pc"
> +                (("Requires: elogind")
> +                 "Requires: libelogind")))))))
> Instead of patching the generated file, you could try patching the .in file
> from which it is generated or the CMakeLists.

As far as I understand, the CMakeLists do not have a variable that contain
"libelogind", and we can’t change the LIBSYSTEMD variable content because it
is used in other places (notably to find headers, where “libelogind” would not
work).

So we have to ignore the CMakeLists entirely and bypass the .in substitution.

 gnu/packages/glib.scm | 19 ++++++++++++++-----
 1 file changed, 14 insertions(+), 5 deletions(-)

diff --git a/gnu/packages/glib.scm b/gnu/packages/glib.scm
index 7b8cc3286d..eee5251d03 100644
--- a/gnu/packages/glib.scm
+++ b/gnu/packages/glib.scm
@@ -1289,11 +1289,20 @@ (define-public sdbus-c++
                                 ;; Do not install tests.
                                 "-DTESTS_INSTALL_PATH=/tmp"
                                 "-DCMAKE_VERBOSE_MAKEFILE=ON")
-      #:phases #~(modify-phases %standard-phases
-                   (add-after 'unpack 'do-not-install-tests
-                     (lambda _
-                       (substitute* "tests/CMakeLists.txt"
-                         (("/etc/dbus-1/system.d") "/tmp")))))))
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'unpack 'do-not-install-tests
+            (lambda _
+              (substitute* "tests/CMakeLists.txt"
+                (("/etc/dbus-1/system.d") "/tmp"))))
+          (add-after 'unpack 'fix-elogind-requirement
+            (lambda _
+              ;; sdbus-c++.pc requires 'elogind', but it should
+              ;; require 'libelogind'. Fixed after 1.4.0 with
+              ;; fb9e4ae37152648a67814458d3ff673b1d3ca089
+              (substitute* "pkgconfig/sdbus-c++.pc.in"
+                (("@LIBSYSTEMD@")
+                 "libelogind")))))))
     (native-inputs (list googletest pkg-config))
     (inputs (list expat))
     (propagated-inputs (list elogind)) ;required by sdbus-c++.pc

base-commit: 49897f2dde7f469c83c496fad2699d3a05f72701
-- 
2.41.0




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

* [bug#68573] [PATCH gnome-team] gnu: sdbus-c++: Fix generated sdbus-c++.pc.
  2024-01-18 21:14 [bug#68573] [PATCH gnome-team] gnu: sdbus-c++: Fix generated sdbus-c++.pc Vivien Kraus via Guix-patches via
@ 2024-01-20  7:35 ` Liliana Marie Prikler
  2024-01-18 21:14   ` [bug#68573] [PATCH gnome-team v2] " Vivien Kraus via Guix-patches via
  0 siblings, 1 reply; 5+ messages in thread
From: Liliana Marie Prikler @ 2024-01-20  7:35 UTC (permalink / raw)
  To: Vivien Kraus, 68573; +Cc: rg, maxim.cournoyer

Am Donnerstag, dem 18.01.2024 um 22:14 +0100 schrieb Vivien Kraus:
> * gnu/packages/glib.scm (sdbus-c++) [#:phases 'fix-libelogind-
> requirement]:
> New phase.
Rather use [#:phases]: Add ‘fix-libelogind-requirement’ (or rename the
phase to ‘fix-elogind-requirement’ and use that).

> 
> Change-Id: Id29369178f164fc60e6882aa664556924cf4bfa7
> ---
>  gnu/packages/glib.scm | 19 ++++++++++++++-----
>  1 file changed, 14 insertions(+), 5 deletions(-)
> 
> diff --git a/gnu/packages/glib.scm b/gnu/packages/glib.scm
> index 7b8cc3286d..d84b848b62 100644
> --- a/gnu/packages/glib.scm
> +++ b/gnu/packages/glib.scm
> @@ -1289,11 +1289,20 @@ (define-public sdbus-c++
>                                  ;; Do not install tests.
>                                  "-DTESTS_INSTALL_PATH=/tmp"
>                                  "-DCMAKE_VERBOSE_MAKEFILE=ON")
> -      #:phases #~(modify-phases %standard-phases
> -                   (add-after 'unpack 'do-not-install-tests
> -                     (lambda _
> -                       (substitute* "tests/CMakeLists.txt"
> -                         (("/etc/dbus-1/system.d") "/tmp")))))))
> +      #:phases
> +      #~(modify-phases %standard-phases
> +          (add-after 'unpack 'do-not-install-tests
> +            (lambda _
> +              (substitute* "tests/CMakeLists.txt"
> +                (("/etc/dbus-1/system.d") "/tmp"))))
> +          (add-before 'install 'fix-libelogind-requirement
> +            (lambda _
> +              ;; sdbus-c++.pc requires 'elogind', but it should
> +              ;; require 'libelogind'. Fixed after 1.4.0 with
> +              ;; fb9e4ae37152648a67814458d3ff673b1d3ca089
> +              (substitute* "pkgconfig/sdbus-c++.pc"
> +                (("Requires: elogind")
> +                 "Requires: libelogind")))))))
Instead of patching the generated file, you could try patching the .in
file from which it is generated or the CMakeLists.

Cheers

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

* [bug#68573] [PATCH gnome-team v2] gnu: sdbus-c++: Fix generated sdbus-c++.pc.
  2024-01-18 21:14   ` [bug#68573] [PATCH gnome-team v2] " Vivien Kraus via Guix-patches via
@ 2024-01-20 18:30     ` Maxim Cournoyer
  2024-01-25 15:33     ` bug#68573: " Liliana Marie Prikler
  1 sibling, 0 replies; 5+ messages in thread
From: Maxim Cournoyer @ 2024-01-20 18:30 UTC (permalink / raw)
  To: Vivien Kraus; +Cc: rg, liliana.prikler, 68573

Hi,

Vivien Kraus <vivien@planete-kraus.eu> writes:

> * gnu/packages/glib.scm (sdbus-c++) [#:phases]: Add 'fix-elogind-requirement.
>
> Change-Id: Id29369178f164fc60e6882aa664556924cf4bfa7

Thanks for the explanation, it makes sense.

Reviewed-by: Maxim Cournoyer <maxim.cournoyer@gmail>

-- 
Thanks,
Maxim




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

* bug#68573: [PATCH gnome-team v2] gnu: sdbus-c++: Fix generated sdbus-c++.pc.
  2024-01-18 21:14   ` [bug#68573] [PATCH gnome-team v2] " Vivien Kraus via Guix-patches via
  2024-01-20 18:30     ` Maxim Cournoyer
@ 2024-01-25 15:33     ` Liliana Marie Prikler
  1 sibling, 0 replies; 5+ messages in thread
From: Liliana Marie Prikler @ 2024-01-25 15:33 UTC (permalink / raw)
  To: Vivien Kraus, 68573-done; +Cc: rg, maxim.cournoyer

Am Donnerstag, dem 18.01.2024 um 22:14 +0100 schrieb Vivien Kraus:
> * gnu/packages/glib.scm (sdbus-c++) [#:phases]: Add 'fix-elogind-
> requirement.
> 
> Change-Id: Id29369178f164fc60e6882aa664556924cf4bfa7
Pushed.  Thanks




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

end of thread, other threads:[~2024-01-25 15:34 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-18 21:14 [bug#68573] [PATCH gnome-team] gnu: sdbus-c++: Fix generated sdbus-c++.pc Vivien Kraus via Guix-patches via
2024-01-20  7:35 ` Liliana Marie Prikler
2024-01-18 21:14   ` [bug#68573] [PATCH gnome-team v2] " Vivien Kraus via Guix-patches via
2024-01-20 18:30     ` Maxim Cournoyer
2024-01-25 15:33     ` bug#68573: " Liliana Marie Prikler

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.