Skip to content

Commit 42d2eb7

Browse files
committed
wrappers: Remove the dlltool wrapper
Since LLVM 13, llvm-dlltool can imply the target architecture from a triple prefix on the tool name, so there's no more need for a wrapper. The *-dlltool tools are now symlinks to the main llvm-dlltool executable. In the Windows distribution, the *-dlltool.exe used to be copies of dlltool-wrapper.exe (which is small; 15 KB). Now they will instead be copies of llvm-dlltool.exe. Luckily, thanks to building with -DLLVM_LINK_LLVM_DYLIB=ON by default, llvm-dlltool.exe is only a mere 65 KB, while it used to be much larger, e.g. around 11 MB in older releases.
1 parent 671c408 commit 42d2eb7

File tree

2 files changed

+2
-71
lines changed

2 files changed

+2
-71
lines changed

install-wrappers.sh

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,6 @@ if [ -n "$HOST" ]; then
6969
done
7070
fi
7171
$CC wrappers/clang-target-wrapper.c -o "$PREFIX/bin/clang-target-wrapper$EXEEXT" -O2 -Wl,-s $WRAPPER_FLAGS
72-
$CC wrappers/dlltool-wrapper.c -o "$PREFIX/bin/dlltool-wrapper$EXEEXT" -O2 -Wl,-s $WRAPPER_FLAGS
7372
$CC wrappers/llvm-wrapper.c -o "$PREFIX/bin/llvm-wrapper$EXEEXT" -O2 -Wl,-s $WRAPPER_FLAGS
7473
if [ -n "$EXEEXT" ]; then
7574
# For Windows, we should prefer the executable wrapper, which also works
@@ -93,10 +92,10 @@ for arch in $ARCHS; do
9392
fi
9493
ln -sf $link_target$EXEEXT $arch-w64-$target_os-$exec$EXEEXT || true
9594
done
96-
# windres can't use llvm-wrapper, as that loses the original
95+
# windres and dlltool can't use llvm-wrapper, as that loses the original
9796
# target arch prefix.
9897
ln -sf llvm-windres$EXEEXT $arch-w64-$target_os-windres$EXEEXT
99-
ln -sf dlltool-wrapper$EXEEXT $arch-w64-$target_os-dlltool$EXEEXT
98+
ln -sf llvm-dlltool$EXEEXT $arch-w64-$target_os-dlltool$EXEEXT
10099
for exec in ld objdump; do
101100
ln -sf $exec-wrapper.sh $arch-w64-$target_os-$exec
102101
done

wrappers/dlltool-wrapper.c

Lines changed: 0 additions & 68 deletions
This file was deleted.

0 commit comments

Comments
 (0)