|
From: Greg C. <chi...@mi...> - 2001-05-18 22:15:33
|
Jeremy Bettis wrote: > > Ok, I might be missing the point here, but wouldn't it be more MingW-like to > just make gcc compatible with the Microsoft C++ runtime dll's? Then it > wouldn't matter what the libstdc++ license is. http://www.mingw.org says At the basic level, MinGW is a set of include files and import libraries that allow a console-mode program to use Microsoft's standard C runtime library MSVCRT.DLL (available on all NT systems, and on all stock Win9x after the original Windows 95 release (for which it can be installed separately)). C was well standardized when win95 came out. Add some headers (the standard tells how, and there's a lot of public documentation of ms extensions) and you can use their C rtl dll. But here we're talking about C++, which was standardized after win95 came out. I don't think anyone claims to have implemented the entire C++ standard yet; ms certainly hasn't, and they might not make their dll freely available. At any rate, C++ is more complex than C, notably in that the standard library is implemented partly in code that pretty much has got to be in a linkable library (like the definition of std::cout) and partly in templates that have to be in headers (until someone implements the standard 'export' keyword). The part of the implementation that, for now at least, is necessarily in headers has to work the same way as the dll: each needs an intimate knowledge of the other. It would be hard to write those headers, without relying on their source. The standard leaves a lot of discretion to implementors: for instance, strings might be copy on write, or they might not. We'd have to figure out and follow all their implementation decisions in order to write headers that complement their rtl. And I suppose we'd need to know their name-mangling scheme in order to link to their dll; that might not be public. While C can put almost 100% of its standard library implementation in a linkable library, almost 100% of a C++ standard library can be implemented in headers. I'd rather have those headers be free software in the gnu sense. If you want headers that are free without any [L]GPL restrictions, take a look at sgi.com and stlport.org . |