<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - clang-clshouldn't emit Wmsvc-not-found if -fuse-ld=lld is passed"
   href="https://bugs.llvm.org/show_bug.cgi?id=38016">38016</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>clang-clshouldn't emit Wmsvc-not-found if -fuse-ld=lld is passed
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>unspecified
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Driver
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedclangbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>nicolasweber@gmx.de
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>I'm using this cross-compiling script:

$ cat clang-cl.sh
#!/bin/bash
TC=$HOME/src/chrome/src/third_party/depot_tools/win_toolchain
MS=$TC/vs_files/5454e45bf3764c03d3fc1024b3bf5bc41e3ab62c
SDK=$MS/win_sdk/Include/10.0.17134.0
VC=$MS/VC/Tools/MSVC/14.14.26428/include
SDK_LIB=$MS/win_sdk/Lib/10.0.17134.0
VC_LIB=$MS/VC/Tools/MSVC/14.14.26428/lib
bin/clang-cl -imsvc$SDK/ucrt -imsvc$SDK/um -imsvc$SDK/shared -imsvc$VC "$@"
/link /libpath:$SDK_LIB/ucrt/x86 /libpath:$SDK_LIB/um/x86 /libpath:$VC_LIB/x86


Building an empty binary:
$ cat empty.c
int main() {}
$ ./clang-cl.sh -fuse-ld=lld empty.c 
clang-7.0: warning: unable to find a Visual Studio installation; try running
Clang from a developer command prompt [-Wmsvc-not-found]


It works, but I get -Wmsvc-not-found (which with /WX is an error).

The warning is silly for two reasons:

1. It's emitted by MSVCToolChain::buildLinker() but we don't use that linker
with -fuse-lld

2. The warning text only makes sense on Windows hosts.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>