Skip to content

Commit

Permalink
WIP: support -l:
Browse files Browse the repository at this point in the history
Needs to be extended not to try alternate extensions (i.e. to take the
basename literally)
  • Loading branch information
dra27 committed Sep 22, 2022
1 parent f624a8a commit 6b5da46
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion reloc.ml
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,9 @@ let find_file =
let fns =
if String.length fn > 2 && String.sub fn 0 2 = "-l" then
let base = String.sub fn 2 (String.length fn - 2) in
if !toolchain = `MSVC || !toolchain = `MSVC64 then
if String.length base > 0 && base.[0] = ':' then
[String.sub base 1 (String.length base - 1)]
else if !toolchain = `MSVC || !toolchain = `MSVC64 then
["lib" ^ base; base]
else
["lib" ^ base]
Expand Down

0 comments on commit 6b5da46

Please sign in to comment.