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

    <tr>
        <th>Summary</th>
        <td>
            Asan causes symbol conflict for clang --target=x86_64-windows-msvc
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            clang
      </td>
    </tr>

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

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

<pre>
    ```
clang++ -o construct_fstream_from_syscall.exe construct_fstream_from_syscall.cc -Ofast -std=c++26 -I../../include --target=x86_64-windows-msvc --sysroot=D:\toolchains\windows-msvc-sysroot -fuse-ld=lld -fsanitize=address -D_DLL=1 -Xlinker /force:multipleres
lld-link: error: duplicate symbol: calloc
>>> defined at /home/cqwrteur/toolchains_build/llvm-project/compiler-rt/lib/asan/asan_malloc_win.cpp:113
>>> clang_rt.asan-x86_64.lib(asan_malloc_win.cpp.obj)
>>> defined at api-ms-win-crt-heap-l1-1-0.dll
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyEU09vrDYQ_zTmYhmBDWQ5cNiEIlWK1GtvyNjD4nTA1GN2s_30FbsbpX15epEs_o5n_PunidxpAWhY-czKNtFbnHxoYjCBXACbDN5eG1Zlj5W1LDsa1MuJyWcmn7nw3PiFYthM7EeKAfTcj8HPPV3JaMQU3uG7EmO4-GPUFLmgaJlqzb27rLj4PU2Z7G4XtxjcLHAhog4niEy174eqrwpxcYv1FxIznQ0Xgq4UvN__t0wdWfkSvUczabcQK1_-W_xRysW4EQjchyNaLkbSi4vuH2Cq1dYGIOKi7dvXV6banIs_0S1_QeBMdqMPBpg6zhtGtyIEoDtPiFbsZUwdOYTgw_5gtxWd0RE4XefB4_5tJ8Gb-yamfrsvbmF0C1iu4z5l8jMw2Zm_LyHCFpjsPkH1w-bQMtkhnmexBv8GJu7Ffl4dQhBhf0M3MNlp0svj1s-3uf3FLalZV6aOea5-PMVN7D7EdN8h7nynt1aHn_RI_fDGZP0LKHp1YqZdMWFCFBPoVWAucpGlFvGLwf7H3YNz4-dZL5aP2iFYfnFx4vDuIjfeAs85k4eNgIszj54TAHfL2RsdnV8-z_Zh6cQ2ytaq1gk0-VNe5-XhqciSqYFSDhVUhSoLY-rDQVZyLKU2RtlsLA5l4hqZySKrpMqrrCyytM6GQZW10qbONIzAigxm7TDdZUl9OCWOaIOmrgqlEtQDIN2CJ-UDsdwzGJqbjMN2IlZk6CjSZ4foIkJzJL1wozcCethoj9iIzkQ--nAX7ZucJFvAZopxpT0jsmOyO7k4bUNq_Pzw0ldL3RAQk90dxLmR_wYAAP__UKthfQ">