46 #include <Xyce_config.h>
60 #include <N_DEV_RegisterExternalDevices.h>
63 #ifdef Xyce_NONFREE_MODELS
64 #include <N_DEV_RegisterNonFreeDevices.h>
67 #ifdef Xyce_RAD_MODELS
68 #include <N_DEV_RegisterSandiaDevices.h>
77 static bool initialized =
false;
86 registerExternalDevices();
88 #ifdef Xyce_RAD_MODELS
89 registerSandiaDevices();
92 #ifdef Xyce_NONFREE_MODELS
93 registerNonFreeDevices();
98 void registerDL(
const char *so_path,
const char *function_key = 0);
108 void registerDL(
const char *so_path,
const char *function_key) {
110 void *dl = dlopen(so_path, RTLD_NOW);
112 const char *
error = dlerror();
113 Report::UserError0() <<
"Failed to load plugin " <<
error;
117 std::string s = std::strlen(function_key) ? function_key :
"dl_register";
128 if (std::strlen(function_key)) {
129 Report::UserError0() <<
"Executing dynamic library " << so_path <<
" function " << s <<
"()";
134 #endif // HAVE_DLFCN_H
Pure virtual class to augment a linear system.
void registerOpenDevices()
void error(const std::string &msg)
void registerADMSDevices()
void registerNeuronDevices()
void registerPlugin(const char *so_path)
void registerDL(const char *so_path, const char *function_key=0)
void registerTCADDevices()