19#if defined(__unix__) || defined(__unix) || defined(unix) || \
20 defined(__APPLE__) && defined(__MACH__)
21 auto extension_path = filename.c_str();
22 void* handle = dlopen(extension_path, RTLD_LAZY);
24 std::cerr <<
"Cannot open extension: " << dlerror() << std::endl;
31 dlsym(handle,
"get_yaze_extension"));
32 const char* dlsym_error = dlerror();
34 std::cerr <<
"Cannot load symbol 'get_yaze_extension': " << dlsym_error
44 std::cerr <<
"Failed to initialize the extension." << std::endl;
Extension editor context.