Bug: http://b/110800681 Lld, unlike the MinGW binutils linker, requires import libraries while linking. Create one for the prebuilt AdbWinApi.dll. AdbWinApi.def is a list of Adb* functions in prebuilt/usb/AdbWinApi.dll. AdbWinApi.lib, which is the one passed to lld when linking, is created as follows: // First symlink llvm-ar to llvm-dlltool in Clang prebuilts. $ prebuilts/clang/host/linux-x86/clang-r353983b/bin/llvm-dlltool \ -D AdbWinApi.dll -k -m i386 \ --input-def development/host/windows/prebuilt/usb/AdbWinApi.def \ --output-lib development/host/windows/prebuilt/usb/AdbWinApi.lib Import library for AdbWinUsbApi.dll doesn't seem necessary since it's not directly part of any link command. Test: The following commands pass (but throw exception without this change): $ adb.exe devices $ fastboot.exe devices Change-Id: I10481d43b59adc5464f60bcff7d49ed206c12a5b
5.5 KiB
5.5 KiB