Too many library variants
When I built Boost 1.33.0 for MinGW, I just specified the toolset. As a result I got 28! variants on the set of Boost libraries.
From the various file names, I can figure out most of the variants: d = debug mt = multi-threaded s = static but there are other variants which aren't as obvious.
For example, what's the distinction among boost-<libname>-mgw-1_33.dll boost-<libname>-mgw-1_33.lib boost-<libname>-mgw.lib The two .lib files have the same sizes and timestamps, so they appear to be the same file with and without the Boost version in the name. Is the idea that if you use the library WITHOUT the version number suffix, then you can upgrade to a new version without having to modify your make file? OK, what's the distinction between the .dll and .lib? I understand that they linker needs one set of information about library function names and entry points while the actual function bodies are needed at run time. However, I thought all of that information is in the .dll file. On the other hand, the .dll version is so much bigger than the .lib that there must be more than an entry point table involved. Then there are the libboost-* variations... I understand that in the Unix world, the -L linker option specifies the library directory while the -l<name> option tells the Unix linker to look for the lib<name>.a file. OK, but how does that work with MinGW's ld.exe linker on Windows. Some of the libraries are available only in the static version, but the only static libraries are the libboost-* variants. There is a statement somewhere in the Boost library documention that the selection of libraries should be automatic in Windows because of pragma's in the libraries. However, I haven't been able to find where MinGW supports that pragma. Merrill
Merrill Cornish wrote:
When I built Boost 1.33.0 for MinGW, I just specified the toolset. As a result I got 28! variants on the set of Boost libraries.
From the various file names, I can figure out most of the variants:
d = debug mt = multi-threaded s = static but there are other variants which aren't as obvious.
It's all explained in http://www.boost.org/more/getting_started.html#Results.
For example, what's the distinction among
boost-<libname>-mgw-1_33.dll boost-<libname>-mgw-1_33.lib boost-<libname>-mgw.lib
The two .lib files have the same sizes and timestamps, so they appear to be the same file with and without the Boost version in the name.
Yes.
Is the idea that if you use the library WITHOUT the version number suffix, then you can upgrade to a new version without having to modify your make file?
Yes. Assuming all you need to do is recompile. We don't assume binary compatibility between version.
OK, what's the distinction between the .dll and .lib? I understand that they linker needs one set of information about library function names and entry points while the actual function bodies are needed at run time. However, I thought all of that information is in the .dll file.
Sometimes. It's possible to not provide that information. The .lib is a convenience most people provide.
On the other hand, the .dll version is so much bigger than the .lib that there must be more than an entry point table involved.
Yea, that would be the code itself, plus debug symbols, etc.
Then there are the libboost-* variations...
As in the docs i point out above, those are static link (vs. dynamic link) versions.
I understand that in the Unix world, the -L linker option specifies the library directory while the -l<name> option tells the Unix linker to look for the lib<name>.a file.
It actually looks for lib<name>.so then lib<name>.a, assuming your system supports dynamic linking.
OK, but how does that work with MinGW's ld.exe linker on Windows.
Same, except it searches for <name>.lib, <name>.dll, and lib<name>.lib (and some other variations on that that I don't remember right now).
Some of the libraries are available only in the static version, but the only static libraries are the libboost-* variants.
That's what it means to have only static versions.
There is a statement somewhere in the Boost library documention that the selection of libraries should be automatic in Windows because of pragma's in the libraries. However, I haven't been able to find where MinGW supports that pragma.
I don't think MinGW (aka GCC) has the pragma, and most likely that functionality is not supported in this case. -- -- Grafik - Don't Assume Anything -- Redshift Software, Inc. - http://redshift-software.com -- rrivera/acm.org - grafik/redshift-software.com -- 102708583/icq - grafikrobot/aim - Grafik/jabber.org
Rene Rivera
Merrill Cornish wrote:
When I built Boost 1.33.0 for MinGW, I just specified the toolset. As a result I got 28! variants on the set of Boost libraries.
From the various file names, I can figure out most of the variants:
d = debug mt = multi-threaded s = static but there are other variants which aren't as obvious.
It's all explained in http://www.boost.org/more/getting_started.html#Results.
Rene, I get the impression that 28 variants is a lot more than most people want, at least at first. Maybe we shouldn't build all of them by default, and just supply enough to "get started?" -- Dave Abrahams Boost Consulting www.boost-consulting.com
On Mon, 14 Nov 2005 20:17:00 -0500, David Abrahams wrote
Rene Rivera
writes: Merrill Cornish wrote:
When I built Boost 1.33.0 for MinGW, I just specified the toolset. As a result I got 28! variants on the set of Boost libraries.
From the various file names, I can figure out most of the variants:
d = debug mt = multi-threaded s = static but there are other variants which aren't as obvious.
It's all explained in http://www.boost.org/more/getting_started.html#Results.
Rene, I get the impression that 28 variants is a lot more than most people want, at least at first. Maybe we shouldn't build all of them by default, and just supply enough to "get started?"
I think at one point Doug suggested that a single variant is the most common case, and I agree. Or at least rewrite the getting started so the one selected variant case is trivial to understand. Just looking at this getting_started page...it really needs a more tutorial like...filled with examples style. For example, the type of question I'm asking as a developer when reading getting started is: "how do I get the thing to build multithreaded dlls with vc7.1 installed in c:\dev\boost_libs". There's nothing even close to that on the getting started page. Oh well, sorry to digress -- and no I'm not volunteering ;-) Jeff
Taking this to the devel list... Jeff Garland wrote:
On Mon, 14 Nov 2005 20:17:00 -0500, David Abrahams wrote
Rene Rivera
writes: Merrill Cornish wrote:
When I built Boost 1.33.0 for MinGW, I just specified the toolset. As a result I got 28! variants on the set of Boost libraries.
From the various file names, I can figure out most of the variants:
d = debug mt = multi-threaded s = static but there are other variants which aren't as obvious.
It's all explained in http://www.boost.org/more/getting_started.html#Results.
Rene, I get the impression that 28 variants is a lot more than most people want, at least at first. Maybe we shouldn't build all of them by default, and just supply enough to "get started?"
I think at one point Doug suggested that a single variant is the most common case, and I agree.
OK, but which ever variant one picks, dynamic, static, etc., will mean that some subset of the libraries will not get built as not all libraries support building in any variant. What was the variant that Doug suggested? By the way it's only 16 variants that get built. The rest are the result of not having the version tag so those are just either copies or symlinks. -- -- Grafik - Don't Assume Anything -- Redshift Software, Inc. - http://redshift-software.com -- rrivera/acm.org - grafik/redshift-software.com -- 102708583/icq - grafikrobot/aim - Grafik/jabber.org
participants (4)
-
David Abrahams
-
Jeff Garland
-
Merrill Cornish
-
Rene Rivera