From ec05a0b08f0d93341c149a6f3235e4ee5711b2f8 Mon Sep 17 00:00:00 2001 From: Rich Felker Date: Thu, 23 Jun 2011 22:13:47 -0400 Subject: adapt build/install/gcc-wrapper systems for dynamic linking support --- tools/gen-musl-gcc.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'tools/gen-musl-gcc.sh') diff --git a/tools/gen-musl-gcc.sh b/tools/gen-musl-gcc.sh index bf20c1f6..fcd1e4ea 100644 --- a/tools/gen-musl-gcc.sh +++ b/tools/gen-musl-gcc.sh @@ -1,6 +1,6 @@ #!/bin/sh -printf '#!/bin/sh\n\nlibc_prefix="%s"\n' "$1" +printf '#!/bin/sh\n\nlibc_prefix="%s"\narch="%s"\n' "$1" "$2" cat <<"EOF" libc_lib=$libc_prefix/lib @@ -27,5 +27,6 @@ done exec "$0" "$@" ' -std=gnu99 -nostdinc -nostdlib \ -isystem "$libc_inc" -isystem "$gcc_inc" \ - -Wl,-xxxxxx "$@" -L"$libc_lib" -lc -L"$libgcc" -lgcc -Lxxxxxx -Wl,-nostdlib + -Wl,-xxxxxx "$@" -L"$libc_lib" -lc -L"$libgcc" -lgcc -Lxxxxxx \ + -Wl,-dynamic-linker /lib/ld-musl-"$arch".so.1 -Wl,-nostdlib EOF -- cgit v1.2.1