> From: Jonathan Wakely <jwakely....@gmail.com> > Date: Wed, 16 Jul 2025 16:12:01 +0100 > Cc: qifan.z...@xpeedic.com, gcc@gcc.gnu.org > > On Wed, 16 Jul 2025 at 15:59, Eli Zaretskii <e...@gnu.org> wrote: > > > > > Please stop giving bad advice and direct people to read the > > > appropriate documentation. > > > > Why the animosity? I'm trying to help the OP understand the situation > > about which they asked. > > Well they didn't ask about distributing the DLLs :-)
They did, indirectly: programs compiled by MinGW GCC are linked against libgcc and libstdc++ import libraries, and thus have run-time dependency on these DLLs. Unless the Windows loader can find them on the end-user's machine, it will refuse to run the program. So if they intend to distribute their programs, they will have to distribute these DLLs with it (or ask the end users to install the DLLs by themselves, which would mean the program is not self-contained). > > > > > Since linking to these libraries statically is not recommended, > > > > > especially if the program is a C++ program, the above means in > > > > > practice that the two libraries, if a program is linked to them > > > > > dynamically, impose GPL. > > > > > > This is absolutely wrong. > > > > Not AFAIK, see above. > > The libraries themselves are licensed under the GPL, not the program > that links to them. Agreed about the libraries. As to the effect on the program, IANAL, so I don't know.