<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/54868>54868</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            Make clang's --sysroot argument equivalent to clang-cl's /winsysroot argument on Windows targets
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          GreatGodvin
      </td>
    </tr>
</table>

<pre>
    Right now clang's `--sysroot` argument doesnt do anything on Windows targets. I am cross compiling Windows applications from Linux (using Windows headers and libraries downloaded using [xwin](https://github.com/Jake-Shadle/xwin)) and having to use a bunch of  `-I` and `-L` flags isn't ideal. clang-cl's `/winsysroot` argument helps to reduce the number of arguments that should be passed while cross compiling but using clang-cl isn't ideal on non Windows systems partly because of its Windows-style arguments. It would be nice if clang's `--sysroot` argument became equivalent to the `/winsysroot` argument of clang-cl when target is set to Windows.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyNU8tu2zAQ_BrpsrAg03ZsHXRoUTRIkV7aQ88rci2ypUiVjyj--64UO3GQIChAgFxxODP7UOfVqf1hep3A-QmkRdcXYh-huKlXq3iKwfvEZ8DQ54FcAuUpLhugOyVtXA_ewS_jlJ8iJMZRihXcAQ4gg48RpB9GY2fgBYXjaI3EZLyLcAx-gHvj8iMU4pDjNVATKgr8wCmwpgsYDEXWnpz1fKPgCV7sPj9OxhW7L8ygUxpjsflUiK-8epN07ir2wME3_EOrnxqVJY6WJ6LhtfBrfJi5kmdSAoQuO6nBH2Gpxd1SBIbNwf0cHC32EUxkjn0Cowht9VTAlbSXGrIMq7xXR012jLNaIJUlQdIELg8dhVnzAmOExgRR-2wVdAQjxsh5T9pYelPfLqdzRS4-XvubO-WuusW-Eg2RSUOyJ6aXOOfO-oaVz6hVTCfWenbEvU0wXfw4w97N8X8mZ6YfCOhvNg9o5y-c_Zz2h3Xyx5dkJk3uPGKcGERaKM4-q1K1G9VsGiyTSZba79ztK1_Ppl64X1t53btrQ1du3ox6mYNtP5g5ax8u22oM_jfJxKGJMVPkw257uDmUupVb2kopSSpBzXZ92O9kp_brZodiT-tOlhY7srHlUS-EcDTBQsFnnvrStKIWot6uxboWN_WuOnR7QTU2a-zqBsWm2NY0oLHV7KPyoS9Du1jqch_50prInX2-5CEzvSNa5Jgfc9I-tLeBMN16xT9Kuci3i_1_TvF4bg">