This is an archive of the discontinued LLVM Phabricator instance.

Fixed sys::findProgramByName (Windows) to accept files with point in name
ClosedPublic

Authored by grimar on Oct 7 2015, 2:46 PM.

Details

Summary

Problem was in SearchPathW function that does not attach an extension if file already has one.
That does not work for executables like ld.lld2 for example which requre to has .exe extension but SearchPath thinks that its "lld2".
So for such cases I added the extension manually and ignore the extension argument.

Not sure who should review it.

Diff Detail

Repository
rL LLVM

Event Timeline

grimar updated this revision to Diff 36799.Oct 7 2015, 2:46 PM
grimar retitled this revision from to Fixed sys::findProgramByName (Windows) to accept files with point in name.
grimar updated this object.
grimar added a reviewer: rnk.
grimar added subscribers: llvm-commits, grimar.
rnk edited edge metadata.Oct 7 2015, 5:11 PM

I think we can get away with always manually appending the extension ourselves. We don't need any conditional control flow.

grimar updated this revision to Diff 36841.Oct 8 2015, 3:31 AM
grimar edited edge metadata.

Removed branch (review comment addressed).

rnk accepted this revision.Oct 8 2015, 8:53 AM
rnk edited edge metadata.

lgtm

Thanks!

This revision is now accepted and ready to land.Oct 8 2015, 8:53 AM
This revision was automatically updated to reflect the committed changes.