diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2017-10-01 17:32:12 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2017-10-01 17:32:12 (GMT) |
commit | 208abfe4182c0dafc230e0377b3efcc6c24be0f9 (patch) | |
tree | 4e084364b0a211ee36a5e8e55b70367f01d720d5 /plugins/pychrysa/pychrysa.c | |
parent | 593aee561015251dfd042dc5e00388f63232c45f (diff) |
Defined the ELF support as plugin.
Diffstat (limited to 'plugins/pychrysa/pychrysa.c')
-rw-r--r-- | plugins/pychrysa/pychrysa.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/plugins/pychrysa/pychrysa.c b/plugins/pychrysa/pychrysa.c index 4d32ee1..7c082d6 100644 --- a/plugins/pychrysa/pychrysa.c +++ b/plugins/pychrysa/pychrysa.c @@ -59,6 +59,10 @@ DEFINE_CHRYSALIDE_ACTIVE_PLUGIN("PyChrysalide", "Provides bindings to Python", "0.1.0", PGA_PLUGIN_INIT); +/* Note la nature du chargement */ +static bool _standalone = true; + + /* Fournit la révision du programme global. */ static PyObject *py_chrysalide_revision(PyObject *, PyObject *); @@ -395,6 +399,9 @@ PyMODINIT_FUNC PyInit_pychrysalide(void) return NULL; } + if (_standalone) + init_all_plugins(); + return result; } @@ -533,6 +540,8 @@ G_MODULE_EXPORT bool chrysalide_plugin_init(GPluginModule *plugin) /* Chargement du module pour Python */ + _standalone = false; + ret = PyImport_AppendInittab("pychrysalide", &PyInit_pychrysalide); if (ret == -1) |