On 10/26/2018 3:57 AM, degski via Boost wrote:
On Thu, 25 Oct 2018 at 18:42, Edward Diener via Boost
wrote: With that said using clang on Windows works reasonably well for me without having to use clang-cl, but whether targeting gcc or vc++ clang on Windows has remained problematical in the linking phase for nearly every clang release. I am now trying clang 7.0 to see if it is better.
If you want to use Clang, targeting gcc [which I guess means that you are using MinGW], you should build Clang [clang++] with[in] MinGW and use it there.
There is no need to try and do that. Earlier releases for Windows were built targeting gcc, not vc++. It was only with later releases that the default build of clang for Windows targeted vc++. But whatever the default build of clang for Windows targeted you could always use the compile/link -target switch to change it at runtime.
What we [or I at least] am talking about is using Clang as a native windows compiler [a drop-in for cl.exe], please don't keep on mixing up those very different things [name mangling keeps getting in the way of mixing "gcc-targets" with "vc-targets"].
Aside from the use of different jam files for clang and clang-cl, and the fact that clang-cl allows vc++ like options, clang-cl and clang targeting vc++ work exactly the same.
If you wouldn't mix things up, there would not be any linking issues, as out-of-the-box clang-cl will use link.exe [the vc-linker]. Using lld with clang [beit ++, -cl or just plain clang] works perfectly fine as well.
I have experienced some linking issues when running Boost tests for various libraries for nearly every release of clang. John Maddock also brought this up in a past thread. If you had a solution for the linking issues that worked I did not see it.
Other than the above gcc-targeting I don't see what [for you] comes in the way of proper correct working linking [it works for the rest of us]. I doubt clang-7.0 brings any relief in solving your problem, because the changes in clang are not at that [basic] level, it also always worked fine with clang-6, clang-5, clang-4, clang-3.9 and clang-3.8 [in respect of the latter two, the number of ICE's were rather prohibitive for anything over "Hello world.", though].
Again this is your experience but not mine.
degski