Hi,
We are using boost-build as a build environment around customizations to a COTS product. We extend the product using C/C++; the vendor supplies header files and libraries with the product. The vendor libraries are named the same on windows and unix, except for the platform conventions. For example, on windows we may link against libfoo.lib, while on unix we link against libfoo.so.
The problem is that the linker behaves differently with respect to passed library names between windows and unix. For example, if I define libfoo like so:
lib libfoo : : <name>foo <search>$(VEND_ROOT)/lib ;
Then the link works on unix, as the linker gets passed -lfoo, and it assumes that there is a lib prefix. This does not work on windows, because there is no prefix assumption. The linker gets passed foo.lib, which fails because the name is really libfoo.lib.
If I leave the name property off, then the link works on windows but fails on unix, because -llibfoo tells the linker to look for liblibfoo.so, which is, of course, wrong.
Any suggestions on the best way to handle this? I have ~300 vendor libs to deal with....
Thanks,
Jim Gallagher