<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/61531>61531</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Please help on cross-compiling c files into xx.bc
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
mxtsuper
</td>
</tr>
</table>
<pre>
Hello
Can I crossly compile c files into xx.bc file with LLVM from windows to linux, and run it with lli xx.bc ?
I try the commands, but it can not work ?
clang --target=x86_64-linux-gnu --sysroot=D:\mingw\x86_64-linux-gnu -fuse-ld=lld -stdlib=libc++ main.c -S -emit-llvm
Please give me some hints, thanks.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxskk-L2zwQxj-NfBlkbCl27IMPm-Q178IWCoVei2xNbHX1J0jjTfLti-2FFtqLhDQzzzwz_FRKZvKIHatOrLpkaqE5xM49KC03jNkQ9LP7H60NrLiw4mU_z8rDK4wxpGSfMAZ3MxZhhKuxmMB4CvB45MP-AXdDM7y9ff8C1xgc3I3X4Z6AAljjlwcTZ1BeQ1w8GNqzrTWfCuy_np3OrO3_7P8KFJ9AM669nfI6rSLDQqvAqDz4QHAP8R2Y7GGvgdEqPwHnpOKExOTl0dQ_6gPfTPDJL8B5eqYYwhq8MPnCqrMzfrqz6vx37nVJyK1m8mKtBp5IWzOsLzOMTJyYOIFTxucj8G_A0Rni1n643cxXiyohTOYDwSGk4BBm42mbg2bl31MOme6kbmWrMuzK-tiKtq3bJpu7RhfjtSwrHLQejvJaa6VR1PI41oe6OqjMdKIQspCiKJqiKZv8IIqy0ULIWqqhbBU7FOiUsflqKQ9xykxKC3Z1Wckys2pAmzYkhPB4hy3IhFgJid1aw4dlSuxQWJMo_VYhQxa7z-lmtDcIfueE75QYP_2Dk2yJtpuJbmnduuiZ6CdD8zLkY3BM9Nvi9ovfYviJIzHRb64SE_3m-lcAAAD__8aV5ZA">