<div dir="ltr">+thakis<br><br><div class="gmail_quote"><div dir="ltr">On Tue, Oct 24, 2017 at 2:49 PM Shoaib Meenai <<a href="mailto:smeenai@fb.com">smeenai@fb.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi all (CC llvm-rc contributors),<br>
<br>
I've been attempting to cross-compile LLVM for Windows using clang-cl. LLVM's<br>
build system embeds resource files for MSVC builds, so I was hoping to use<br>
llvm-rc for that portion.<br>
<br>
cmake invokes the resource compiler with arguments joined to their options<br>
(e.g. `/D_WIN32`, `/fofoo.res`, etc.), which rc.exe supports, but llvm-rc<br>
expects arguments to be separate. It's simple enough to change that, of<br>
course; just change `Separate` to `JoinedOrSeparate` in the options tabledef.<br>
Unfortunately, that then causes problems with Unix-style absolute paths; for<br>
example, on macOS, `/Users/...` would be interpreted as a macro undefine<br>
rather than a path.<br>
<br>
clang-cl has similar issues, and supports such paths by treating anything<br>
after a `--` as a path. (clang-cl has it slightly easier since at least its<br>
options are case-sensitive, but it's still the same underlying issue). I'd<br>
like to make a similar change in llvm-rc (i.e., arguments can be both joined<br>
or separate, and you use `--` to resolve ambiguities between options and<br>
paths), but I wanted to run it by everyone before putting up that patch, in<br>
case it breaks people's use cases. (I doubt there are a whole lot of llvm-rc<br>
use cases right now, given that it was only introduced in the 6.0 cycle, but<br>
still.)<br>
<br>
Thanks,<br>
Shoaib<br>
<br>
</blockquote></div></div>