First, make sure we actually match /c/windows from the beginning, not
if it occurs in the middle of the path.
Second, make sure that directories containing the binaries are
searched first. Do that by using unshift (prepend) instead of push
(append).
Signed-off-by: Thiago Macieira <thiago@macieira.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
The correct order on Windows is:
1. Local directory (relative to the binary)
2. $PATH
3. System dirs
We insert our -L flags between 1 and 2 above.
Signed-off-by: Thiago Macieira <thiago@macieira.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
The environment variable is to be used if the caller knows that the
default objdump can't parse Windows DLL files (COFF-PE). On Fedora,
Debian, and OpenSUSE, the default objdump can, and obviously the
native one on Windows can too.
Signed-off-by: Thiago Macieira <thiago@macieira.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Unix developers, look away... this is how it's done on Windows: the
binary loader searches $PATH for the DLLs, so let's reuse the same
variable. This simplifies the command-line a little.
Signed-off-by: Thiago Macieira <thiago@macieira.org>