[clang] [clang][mingw] Don't emit `-lssp_nonshared -lssp` (PR #219932)

Martin Storsjö via cfe-commits cfe-commits at lists.llvm.org
Tue Nov 24 01:24:17 PST 2026


mstorsjo wrote:

This would indeed be convenient, as it avoids having to create dummy empty libraries with these names, as in https://github.com/mstorsjo/llvm-mingw/blob/20261117/build-mingw-w64.sh#L162-L167.

On the other hand, this breaks building with versions of mingw-w64 older than v11 (at least for the cases when building with `-fstack-protector-strong`). v11 was released in 2023. This isn't super recently, but it's also not really ancient by any means.

One could argue that one shouldn't use top-of-tree Clang if expecting to use an older SDK, but we do want to allow some amount flexibility. In https://github.com/llvm/llvm-project/pull/234640#issuecomment-6503485580 we had a case where people were using latest llvm-project together with an mingw-w64 v7 (which was released in 2019). This did hit an issue with the latest libcxx though.

Occasionally, on the mingw-w64 side, we've done things that require a fairly new LLVM as well - e.g. https://github.com/mingw-w64/mingw-w64/commit/bafccb49a0a6b4676f748bb415aabe27212d12d7 required LLVM 19, which was just released around a month before that. This one did cause problems for VideoLAN when they tried to upgrade their buildbot CI images, where they weren't able to upgrade just the mingw-w64 part far enough without also changing the version of LLVM at the same time.

So each time there's a narrowing of the support window of toolchain<->SDK, someone is bound to hit it at some point.

So overall I'm in favour of the change, but I'm unsure if it's too soon or not. What do @cjacek, @lazka, @mati865, @lhmouse think? Personally I think it would be good to wait another year or two.

https://github.com/llvm/llvm-project/pull/219932


More information about the cfe-commits mailing list