3#if defined(__unix__) || defined(__unix) || defined(unix) || \
4 defined(__APPLE__) && defined(__MACH__)
18#if defined(__unix__) || defined(__unix) || defined(unix) || \
19 defined(__APPLE__) && defined(__MACH__)
20 auto extension_path = filename.c_str();
21 void* handle = dlopen(extension_path, RTLD_LAZY);
23 std::cerr <<
"Cannot open extension: " << dlerror() << std::endl;
30 dlsym(handle,
"get_yaze_extension"));
31 const char* dlsym_error = dlerror();
33 std::cerr <<
"Cannot load symbol 'get_yaze_extension': " << dlsym_error
43 std::cerr <<
"Failed to initialize the extension." << std::endl;
58 extension->initialize(context);
std::vector< yaze_extension * > extensions_
void LoadExtension(const std::string &filename, yaze_editor_context *context)
void RegisterExtension(yaze_extension *extension)
void InitializeExtensions(yaze_editor_context *context)
void ShutdownExtensions()
Editors are the view controllers for the application.
Main namespace for the application.
Extension interface for Yaze.
yaze_initialize_func initialize
Function to initialize the extension.