
Boris Gubenko escribió:
In theory, a check for these macros should be accompanied by the check of the value of _XOPEN_SOURCE feature test macro because different releases of X/Open Specs define these _POSIX_* feature test macros differently. Using _POSIX_SHARED_MEMORY_OBJECTS as an example, I'd suggest the following check:
#if defined(_POSIX_SHARED_MEMORY_OBJECTS) # if !((_XOPEN_SOURCE >= 600) && (_POSIX_SHARED_MEMORY_OBJECTS - 0 <= 0)) # define BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS # endif #endif
Ok. Thanks for the info.
VMS supports shared memory objects but it does not define _POSIX_SHARED_MEMORY_OBJECTS macro, so you can define BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS on VMS as the following (70200000 is the first version of libc on VMS having shm_*() functions):
#if defined(__vms) # if __CRTL_VER >= 70200000 # define BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS # endif #endif
Ok. Thanks again! Ion