Subject: ‘gcc’ doesn't compile with LD_LIBRARY_PATH="$HOME/.guix-profile/lib"

From: Mathieu Lirzin <[email-masked]>
Date: Thu, 08 Feb 2018 18:20:59 +0100

Hello,

I have been facing a weird issue where some shitty build tool I was
using has tried to run ‘cmake’ after setting LD_LIBRARY_PATH.  The
result was a non terminating call to ‘collect2’.

Here is a way to reproduce the issue:

  $ guix environment --pure --ad-hoc gcc-toolchain
  $ echo "int main() { return 0; }" > foo.c
  $ LD_LIBRARY_PATH="$HOME/.guix-profile/lib" gcc foo.c

When adding ‘binutils’ to the environment, the problem dissapears since
‘ld-wrapper’ is not used anymore.

Thanks.

-- 
Mathieu Lirzin
GPG: F2A3 8D7E EB2B 6640 5761  070D 0ADE E100 9460 4D37