This repository was archived by the owner on Oct 24, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -59,12 +59,11 @@ namespace Sass {
5959 // load one specific plugin
6060 bool Plugins::load_plugin (const std::string& path)
6161 {
62-
62+ # ifdef ENABLE_LOAD_PLUGINS
6363 typedef const char * (*__plugin_version__)(void );
6464 typedef Sass_Function_List (*__plugin_load_fns__)(void );
6565 typedef Sass_Importer_List (*__plugin_load_imps__)(void );
6666
67- #ifndef _WASM
6867 if (LOAD_LIB (plugin, path))
6968 {
7069 // try to load initial function to query libsass version suppor
@@ -111,7 +110,7 @@ namespace Sass {
111110 if (const char * dlopen_error = dlerror ()) std::cerr << dlopen_error << std::endl;
112111 }
113112#else
114- std::cerr << " loading plugin unsupported <" << path << " >" << std::endl;
113+ std::cerr << " plugins loading is unsupported <" << path << " >" << std::endl;
115114#endif
116115
117116 return false ;
Original file line number Diff line number Diff line change 66#include " utf8_string.hpp"
77#include " sass/functions.h"
88
9+ #ifdef ENABLE_LOAD_PLUGINS
910#ifdef _WIN32
1011
1112 #define LOAD_LIB (var, path ) HMODULE var = LoadLibraryW(UTF_8::convert_to_utf16(path).c_str())
2425 #define CLOSE_LIB (var ) dlclose(var)
2526
2627#endif
28+ #endif
2729
2830namespace Sass {
2931
Original file line number Diff line number Diff line change 3838# endif
3939#endif
4040
41+ // enable loading of plugins for non-wasm
42+ #ifndef _WASM
43+ # define ENABLE_LOAD_PLUGINS
44+ #endif
45+
4146// path separation char
4247#ifndef PATH_SEP
4348# ifdef _WIN32
You can’t perform that action at this time.
0 commit comments