I am using boost::interprocess
to implement an IPC mechanism based on shared memory. I want this to be cross platform (including windows), and the build system is autotools. On some platforms boost::interprocess requires that you link with the library librt
which implements some threading functions, but not on windows, or apple platforms (I think). See the following link:
Now, in autotools I can do things conditionally depending on the host being windows, but it would be better to test if the required functions are available using AC_SEARCH_LIBS. The AC_SEARCH_LIBS macro first checks if the functions are available with no libraries, then using a provided list of libraries in sequence.
To do the test, I need to know what functions to search for.
To be even more specific I need to use the following headers in my program:
#include <boost/interprocess/managed_shared_memory.hpp>
#include <boost/interprocess/sync/interprocess_mutex.hpp>
#include <boost/interprocess/sync/interprocess_condition.hpp>
#include <boost/interprocess/allocators/allocator.hpp>
#include <boost/interprocess/containers/vector.hpp>
So what functions in librt
are required by these headers, or what is the easiest way to find this out?