unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#27848] guix: build-system: gnu: Avoid warnings from "libtool finish"
@ 2017-07-27 14:40 Dave Love
  2017-07-31 15:28 ` Ludovic Courtès
  0 siblings, 1 reply; 4+ messages in thread
From: Dave Love @ 2017-07-27 14:40 UTC (permalink / raw)
  To: 27848

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

The "ldconfig not found" warnings confused me, and caused a bug report
previously.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-guix-build-system-gnu-Avoid-warnings-from-libtool-fi.patch --]
[-- Type: text/x-diff, Size: 1476 bytes --]

From d6f42badc39679dd36ea8f582140a7d63316d101 Mon Sep 17 00:00:00 2001
From: Dave Love <fx@gnu.org>
Date: Thu, 27 Jul 2017 15:35:53 +0100
Subject: [PATCH] guix: build-system: gnu: Avoid warnings from "libtool
 finish".

* guix/build/gnu-build-system.scm (configure): Avoid warnings from
libtool invoking ldconfig.
---
 guix/build/gnu-build-system.scm | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/guix/build/gnu-build-system.scm b/guix/build/gnu-build-system.scm
index 1786e2e3c..508699497 100644
--- a/guix/build/gnu-build-system.scm
+++ b/guix/build/gnu-build-system.scm
@@ -271,9 +271,15 @@ makefiles."
     ;; Call `configure' with a relative path.  Otherwise, GCC's build system
     ;; (for instance) records absolute source file names, which typically
     ;; contain the hash part of the `.drv' file, leading to a reference leak.
-    (zero? (apply system* bash
-                  (string-append srcdir "/configure")
-                  flags))))
+    (and (zero? (apply system* bash
+                       (string-append srcdir "/configure")
+                       flags))
+         ;; Avoid warnings about from "libtool finish" about not finding
+         ;; ldconfig.
+         (if (file-exists? "libtool")
+             (begin (substitute* "libtool" (("ldconfig") ":"))
+                    #t)
+             #t))))
 
 (define* (build #:key (make-flags '()) (parallel-build? #t)
                 #:allow-other-keys)
-- 
2.11.0


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

* [bug#27848] guix: build-system: gnu: Avoid warnings from "libtool finish"
  2017-07-27 14:40 [bug#27848] guix: build-system: gnu: Avoid warnings from "libtool finish" Dave Love
@ 2017-07-31 15:28 ` Ludovic Courtès
  2017-07-31 18:17   ` Dave Love
  0 siblings, 1 reply; 4+ messages in thread
From: Ludovic Courtès @ 2017-07-31 15:28 UTC (permalink / raw)
  To: Dave Love; +Cc: 27848

Dave Love <fx@gnu.org> skribis:

> --- a/guix/build/gnu-build-system.scm
> +++ b/guix/build/gnu-build-system.scm
> @@ -271,9 +271,15 @@ makefiles."
>      ;; Call `configure' with a relative path.  Otherwise, GCC's build system
>      ;; (for instance) records absolute source file names, which typically
>      ;; contain the hash part of the `.drv' file, leading to a reference leak.
> -    (zero? (apply system* bash
> -                  (string-append srcdir "/configure")
> -                  flags))))
> +    (and (zero? (apply system* bash
> +                       (string-append srcdir "/configure")
> +                       flags))
> +         ;; Avoid warnings about from "libtool finish" about not finding
> +         ;; ldconfig.
> +         (if (file-exists? "libtool")
> +             (begin (substitute* "libtool" (("ldconfig") ":"))
> +                    #t)
> +             #t))))
>  

I’m not too keen on this approach, in large part because I’ve got used
to the “ldconfig not found” messages, but also because a simple change
like this can create more problems than what it solves: packages where
the “libtool” script lives in a different directory, packages where
“libtool” is a different thing, packages where it’s read-only or where
it’s a directory, etc.

Since this is a rebuild-the-world change, we have to make sure it’s
really worth it.

WDYT?

Thanks,
Ludo’.

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

* [bug#27848] guix: build-system: gnu: Avoid warnings from "libtool finish"
  2017-07-31 15:28 ` Ludovic Courtès
@ 2017-07-31 18:17   ` Dave Love
  2017-07-31 19:26     ` Ludovic Courtès
  0 siblings, 1 reply; 4+ messages in thread
From: Dave Love @ 2017-07-31 18:17 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 27848

Ludovic Courtès <ludo@gnu.org> writes:

> I’m not too keen on this approach, in large part because I’ve got used
> to the “ldconfig not found” messages,

It's OK if you know, but I assume it's common for newbies to see it and
waste time, as at least two of us did.

> but also because a simple change
> like this can create more problems than what it solves: packages where
> the “libtool” script lives in a different directory, packages where
> “libtool” is a different thing, packages where it’s read-only or where
> it’s a directory, etc.

OK, but I thought the common case of it at top level was worth fixing.
I guess you could check it's really a libtool script before editing it.

However, is there a good reason not to provide a dummy ldconfig which
does nothing, or prints a message about not doing anything?

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

* [bug#27848] guix: build-system: gnu: Avoid warnings from "libtool finish"
  2017-07-31 18:17   ` Dave Love
@ 2017-07-31 19:26     ` Ludovic Courtès
  0 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2017-07-31 19:26 UTC (permalink / raw)
  To: Dave Love; +Cc: 27848

Dave Love <fx@gnu.org> skribis:

> Ludovic Courtès <ludo@gnu.org> writes:
>
>> I’m not too keen on this approach, in large part because I’ve got used
>> to the “ldconfig not found” messages,
>
> It's OK if you know, but I assume it's common for newbies to see it and
> waste time, as at least two of us did.

Yeah, I see.

>> but also because a simple change
>> like this can create more problems than what it solves: packages where
>> the “libtool” script lives in a different directory, packages where
>> “libtool” is a different thing, packages where it’s read-only or where
>> it’s a directory, etc.
>
> OK, but I thought the common case of it at top level was worth fixing.
> I guess you could check it's really a libtool script before editing it.
>
> However, is there a good reason not to provide a dummy ldconfig which
> does nothing, or prints a message about not doing anything?

I’d think it’s safer to just not provide it at all.

Ludo’.

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

end of thread, other threads:[~2017-07-31 19:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-07-27 14:40 [bug#27848] guix: build-system: gnu: Avoid warnings from "libtool finish" Dave Love
2017-07-31 15:28 ` Ludovic Courtès
2017-07-31 18:17   ` Dave Love
2017-07-31 19:26     ` Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).