Boost logo

Boost Testing :

From: Beman Dawes (bdawes_at_[hidden])
Date: 2005-12-07 18:06:23

"Rene Rivera" <grafik.list_at_[hidden]> wrote in message
> Beman Dawes wrote:
>> "Martin Slater" <mslater_at_[hidden]> wrote in message
>>>Eric Niebler wrote:
>>>>For the [mslater] mingw tests, xpressive is failing due to what looks to
>>>>be a configuration problem. See
>>>>undefined reference to `WinMain_at_16'
>>>>FWIW, xpressive's tests pass for the Bronek mingw toolset.
>> The g++ command line is missing -L"c:/cygwin/lib/mingw", or whatever your
>> appropriate path is.
>> The obvious workaround is to add an environmental variable:
>> set MINGW_STDLIB_DIRECTORY=c:\cygwin\lib\mingw
>> That almost works, but also adds a spurious -L"" to the g++ command line.
>> If
>> you remove the -L"" by hand, the g++ command then works OK.
>> We need help from a Boost.Build expert:
>> * Why does MINGW_STDLIB_DIRECTORY have to be set by hand?
> It's one of the standard MinGW config options for the toolset. But it
> would be preferable to set MINGW_ROOT_DIRECTORY, which will the cause
> the various GCC_*_DIRECTORY vars.

That doesn't work. The apparent mingw root directory cygwin installs just
contains three symbolic links. (1) Windows doesn't understand cygwin
symbolic links, and (2) they go to non-existant locations anyhow.

I guess I could fix them, and then run under bash, but that is pretty
extreme. MINGW_STDLIB_DIRECTORY works, except for the extra -L""

>> Is the problem
>> that cygwin installs the mingw libraries in lib\mingw rather than lib?
> Don't know... Is the real installed toolset MinGW, or is it CYGWIN?


Here is the command line that fails, after I've set MINGW_STDLIB_DIRECTORY:

  "-Wl,--enable-auto-image-base" -g -Wl,--allow-multiple-definition -mno-cygwin
  -L"c:/cygwin/lib/mingw" -L""

The only thing wrong is the -L"". If I remove that, and run by hand, the
link succeeds. Then the test also runs and passes.



Boost-testing list run by mbergal at