From: Dean M. B. <mik...@gm...> - 2011-02-15 17:57:11
|
On Wed, Feb 16, 2011 at 1:38 AM, Gregory Symons <gs...@dr...> wrote: > On Wed, 2011-02-16 at 01:17 +0800, Dean Michael Berris wrote: >> Hi Gregory, >> >> On Tue, Feb 15, 2011 at 11:42 PM, Gregory Symons > [snip] >> > >> > My boost has everything built as shared libraries, so I've tried adding >> > BOOST_TEST_DYN_LINK and BOOST_TEST_MAIN to CXXFLAGS, but that doesn't >> > seem to have an effect. >> > >> > Any ideas? >> > >> >> Actually, currently the unit tests require that Boost.Test be linked >> in statically. >> >> I haven't added in the capability for configuring the testing system >> through CMake to accept these or additional settings. > > That would explain it. I'm not terribly familiar with CMake, and looking > through the FindBoost documentation, I didn't see an easy way to > determine that things should be dynamically linked. After hacking > CMakelists.txt to have the BOOST_TEST_DYN_LINK in the compile flags, I > was able to get everything to build. But I'm pretty sure that's not the > "right" way to do it. > Well, that would one way to do it -- but there's a more generic way which should allow users to define variables on the cmake command-line to give more information to cmake and allow the generated build files to contain the correct directives. That requires some cmake kung fu that I haven't the time to deal with yet. ;) > Once they built, I had several test failures: > > The following tests FAILED: > 14 - cpp-netlib-hello_world (Failed) > 15 - cpp-netlib-http_async_server (Failed) > 16 - cpp-netlib-http_server_async_less_copy (Failed) > 17 - mime-roundtrip (Failed) > > Looking closely at the verbose test output, it looks like they all > failed because the address they were trying to bring up the server on > was still in use. > Yes, which since you've mentioned you're on Ubuntu, is actually expected. I haven't found a solution to this problem yet though, feedback and suggestions would be most appreciated. Short of installing a signal handler on the server code (which would not be easy to make cross-platform), I don't see a way to make this easily done unless I use different ports for each server (or take the port as an argument on the command-line). Pull requests for those would be greatly appreciated. :D Thanks Gregory for reporting! :) -- Dean Michael Berris about.me/deanberris |