#include typedef boost::interprocess::managed_shared_memory segment_t; int main() { segment_t segment(boost::interprocess::open_or_create,"some_segment_name",1048576); segment.find("some_variable_name"); }