The Grimoire of Nonsense

個人的なメモを残すブログ

.exeが依存するDLLを調べる

.exeが実行する時に暗黙的リンクされているDLLが見つからないと実行出来ない*1
暗黙的リンクされている.exeのDLLを列挙する時はやっぱりdumpbin先生に/dependentsオプションを指定して食わせてみる。
あとは不足DLLを用意するなりする。

dumpbin /dependents (調べたいexeファイル)


以下実行例

Microsoft (R) COFF/PE Dumper Version 12.00.31101.0
Copyright (C) Microsoft Corporation.  All rights reserved.


Dump of file test.exe

File Type: EXECUTABLE IMAGE

  Image has the following dependencies:

    USER32.dll
    MSVCR120.dll
    KERNEL32.dll

  Summary

        1000 .data
        1000 .pdata
        1000 .rdata
        1000 .reloc
        1000 .text

*1:なんとか.dllが見つからないため――的な文言が表示される