guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Patch] address@hidden


From: Andy Wingo
Subject: Re: [Patch] address@hidden
Date: Thu, 02 Jun 2016 09:54:30 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Hi,

How goes the patching?

FWIW for Go 1.5 and 1.6, if I remove this test in the linker then I can
build without the LD_LIBRARY_PATH hacks and the tests work for me:

On Sun 29 May 2016 19:49, Andy Wingo <address@hidden> writes:

>       if Linkshared {
>               seenDirs := make(map[string]bool)
>               seenLibs := make(map[string]bool)
>               addshlib := func(path string) {
>                       dir, base := filepath.Split(path)
>                       if !seenDirs[dir] {
>                               argv = append(argv, "-L"+dir)
>                               if !rpath.set {
>                                       argv = append(argv, "-Wl,-rpath="+dir)
>                               }

This one.  I do a substitute* of !rpath.set to "true" :)

I am not sure whether this is the right fix -- I guess it seems that the
intention of this code in the linker is that whatever calls the linker,
if it passes the "-r" argument (yes, "-r" not "-rpath" because this is
the Go internal linker that has different kinds of arguments; grrr; and
yet, when linking a shared library it still shells out to the system
ld), then it means that the caller is omniscient and knows the entire
rpath to set.  Otherwise the linker is doing magic by adding its own
rpath incantations.  But, that seems to me to be a bad design.  I can't
see why passing -r should turn off the "automatic" rpath stuff where Go
adds -rpaths appropriate the -l libraries that it is linking, unless in
some really strange deployment scenarios.

Anyway.  I think it is a sufficiently innocuous of a fix that it will
allow us to merge Go.  Let us call this yak shaved and get Go in.  WDYT?

Andy



reply via email to

[Prev in Thread] Current Thread [Next in Thread]