summaryrefslogtreecommitdiff
path: root/extra/scripts/get-needed-libgcc-objects.sh
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2001-05-17 20:12:16 +0000
committerEric Andersen <andersen@codepoet.org>2001-05-17 20:12:16 +0000
commitd13d4ad946a8e6e6b209e0fe6fee5d93bd38e3e2 (patch)
tree131222540e9f72ed73b8b1b00ba228902fbf0c47 /extra/scripts/get-needed-libgcc-objects.sh
parent58903a0726aa2e7e2b8141772233752bffb6f0ec (diff)
Fix up some problems noted by August Hoerandl <ahoerandl@gmx.at>
when cross compiling with shared lib support, there were spots where the native 'ld' was mistakenly being called.
Diffstat (limited to 'extra/scripts/get-needed-libgcc-objects.sh')
-rwxr-xr-xextra/scripts/get-needed-libgcc-objects.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/extra/scripts/get-needed-libgcc-objects.sh b/extra/scripts/get-needed-libgcc-objects.sh
index 4bbbb328b..7217ee6ac 100755
--- a/extra/scripts/get-needed-libgcc-objects.sh
+++ b/extra/scripts/get-needed-libgcc-objects.sh
@@ -17,7 +17,7 @@ LIBGCC=`$CC -print-libgcc-file-name`
echo Finding missing symbols in libc.a ...
echo " partial linking..."
rm -f libc.ldr
-ld -r -o libc.ldr ../crt0.o --whole-archive ../libc.a
+$LD -r -o libc.ldr ../crt0.o --whole-archive ../libc.a
if nm --undefined-only libc.ldr | grep -v "^main$" > sym.need ; then
rm -f obj.need
@@ -44,7 +44,7 @@ echo Extracting referenced libgcc.a objects ...
rm -f obj.need.0
touch obj.need.0
while [ -s obj.need ] && ! cmp -s obj.need obj.need.0 ; do
- (cd tmp-gcc ; cat ../obj.need | xargs ld -r -o ../libgcc.ldr)
+ (cd tmp-gcc ; cat ../obj.need | xargs $LD -r -o ../libgcc.ldr)
cp obj.need obj.need.0
if nm --undefined-only libgcc.ldr > sym.need ; then
for SYM in `cat sym.need | sed -e 's/ U //g'` ; do
@@ -72,4 +72,4 @@ if [ -s sym.need ] ; then
else
echo Done
fi
-exit 0 \ No newline at end of file
+exit 0