From 193f70d8877034c8b9df5538f538198e7fdc4a09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Batlle=20i=20Rossell?= Date: Sun, 13 Dec 2009 16:18:53 +0000 Subject: [PATCH] Updating the ld-wrapper about linking of direct .so files. The previous regexp looking for such ld arguments did not work well with "--soname=xxx.so". Now I added the condition that the argument should not start with a hyphen, for it to be possibly considered a .so file to link with. svn path=/nixpkgs/branches/stdenv-updates/; revision=18919 --- pkgs/build-support/gcc-wrapper/ld-wrapper.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/build-support/gcc-wrapper/ld-wrapper.sh b/pkgs/build-support/gcc-wrapper/ld-wrapper.sh index 52aa57bc1ea..bf3c2620f29 100644 --- a/pkgs/build-support/gcc-wrapper/ld-wrapper.sh +++ b/pkgs/build-support/gcc-wrapper/ld-wrapper.sh @@ -81,7 +81,7 @@ if test "$NIX_DONT_SET_RPATH" != "1"; then elif test "$p" = "-L"; then addToLibPath ${p2} n=$((n + 1)) - elif $(echo "$p" | grep -q '\.so\($\|\.\)'); then + elif $(echo "$p" | grep -q '^[^-].*\.so\($\|\.\)'); then path="$(dirname "$p")"; addToLibPath "${path}" fi @@ -116,7 +116,7 @@ if test "$NIX_DONT_SET_RPATH" != "1"; then # I haven't seen `-l foo', but you never know... addToRPath $i break - elif $(echo "$p" | grep -q '\.so\($\|\.\)'); then + elif $(echo "$p" | grep -q '^[^-].*\.so\($\|\.\)'); then path="$(dirname "$p")"; if test "$path" == "$i"; then addToRPath $i