summaryrefslogtreecommitdiff
path: root/plugins/elf
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/elf')
-rw-r--r--plugins/elf/Makefile.am32
-rw-r--r--plugins/elf/core.c7
-rw-r--r--plugins/elf/loading.h2
-rw-r--r--plugins/elf/python/Makefile.am25
-rw-r--r--plugins/elf/python/format.c12
-rw-r--r--plugins/elf/strings.h2
-rw-r--r--plugins/elf/symbols.h2
7 files changed, 38 insertions, 44 deletions
diff --git a/plugins/elf/Makefile.am b/plugins/elf/Makefile.am
index 880ae78..677cf93 100644
--- a/plugins/elf/Makefile.am
+++ b/plugins/elf/Makefile.am
@@ -37,23 +37,25 @@ PYTHON3_SUBDIRS = python
endif
-libelf_la_SOURCES = \
- core.h core.c \
- elf-int.h elf-int.c \
- elf_def.h \
- elf_def_arm.h \
- format.h format.c \
- dynamic.h dynamic.c \
- helper_arm.h helper_arm.c \
- loading.h loading.c \
- program.h program.c \
- section.h section.c \
- strings.h strings.c \
+libelf_la_SOURCES = \
+ core.h core.c \
+ elf-int.h elf-int.c \
+ elf_def.h \
+ elf_def_arm.h \
+ format.h format.c \
+ dynamic.h dynamic.c \
+ helper_arm.h helper_arm.c \
+ loading.h loading.c \
+ program.h program.c \
+ section.h section.c \
+ strings.h strings.c \
symbols.h symbols.c
-libelf_la_LIBADD = \
+libelf_la_LIBADD = \
$(PYTHON3_LIBADD)
+libelf_la_CFLAGS = $(TOOLKIT_CFLAGS) $(LIBXML_CFLAGS) -I$(top_srcdir)/src
+
libelf_la_LDFLAGS = \
-avoid-version \
-L$(top_srcdir)/src/.libs -lchrysacore \
@@ -65,8 +67,4 @@ devdir = $(includedir)/chrysalide/$(subdir)
dev_HEADERS = $(libelf_la_SOURCES:%c=)
-AM_CPPFLAGS = $(LIBGTK_CFLAGS) $(LIBXML_CFLAGS) -I$(top_srcdir)/src
-
-AM_CFLAGS = $(DEBUG_CFLAGS) $(WARNING_FLAGS) $(COMPLIANCE_FLAGS)
-
SUBDIRS = $(PYTHON3_SUBDIRS)
diff --git a/plugins/elf/core.c b/plugins/elf/core.c
index 1e98aba..bd829af 100644
--- a/plugins/elf/core.c
+++ b/plugins/elf/core.c
@@ -24,18 +24,17 @@
#include "core.h"
-#include <config.h>
#include <core/global.h>
#include <plugins/self.h>
#include "format.h"
-#ifdef HAVE_PYTHON3_BINDINGS
+#ifdef INCLUDE_PYTHON3_BINDINGS
# include "python/module.h"
#endif
-#ifdef HAVE_PYTHON3_BINDINGS
+#ifdef INCLUDE_PYTHON3_BINDINGS
# define PG_REQ RL("PyChrysalide")
#else
# define PG_REQ NO_REQ
@@ -65,7 +64,7 @@ G_MODULE_EXPORT bool chrysalide_plugin_init(GPluginModule *plugin)
{
bool result; /* Bilan à retourner */
-#ifdef HAVE_PYTHON3_BINDINGS
+#ifdef INCLUDE_PYTHON3_BINDINGS
result = add_format_elf_module_to_python_module();
#else
result = true;
diff --git a/plugins/elf/loading.h b/plugins/elf/loading.h
index e3016d4..270bb0b 100644
--- a/plugins/elf/loading.h
+++ b/plugins/elf/loading.h
@@ -26,7 +26,7 @@
#include <format/symiter.h>
-#include <gtkext/gtkstatusstack.h>
+#include <glibext/notifier.h>
#include "format.h"
diff --git a/plugins/elf/python/Makefile.am b/plugins/elf/python/Makefile.am
index 29b7d98..1d4f671 100644
--- a/plugins/elf/python/Makefile.am
+++ b/plugins/elf/python/Makefile.am
@@ -1,25 +1,20 @@
noinst_LTLIBRARIES = libelfpython.la
-libelfpython_la_SOURCES = \
- constants.h constants.c \
- dynamic.h dynamic.c \
- elf_def.h elf_def.c \
- format.h format.c \
- module.h module.c \
- program.h program.c \
- section.h section.c \
+libelfpython_la_SOURCES = \
+ constants.h constants.c \
+ dynamic.h dynamic.c \
+ elf_def.h elf_def.c \
+ format.h format.c \
+ module.h module.c \
+ program.h program.c \
+ section.h section.c \
translate.h translate.c
-libelfpython_la_LDFLAGS =
+libelfpython_la_CFLAGS = $(TOOLKIT_CFLAGS) $(LIBXML_CFLAGS) $(LIBPYTHON_CFLAGS) $(LIBPYGOBJECT_CFLAGS) \
+ -I$(top_srcdir)/src -DNO_IMPORT_PYGOBJECT
devdir = $(includedir)/chrysalide/$(subdir)
dev_HEADERS = $(libelfpython_la_SOURCES:%c=)
-
-
-AM_CPPFLAGS = $(LIBGTK_CFLAGS) $(LIBXML_CFLAGS) $(LIBPYTHON_CFLAGS) $(LIBPYGOBJECT_CFLAGS) \
- -I$(top_srcdir)/src -DNO_IMPORT_PYGOBJECT
-
-AM_CFLAGS = $(DEBUG_CFLAGS) $(WARNING_FLAGS) $(COMPLIANCE_FLAGS)
diff --git a/plugins/elf/python/format.c b/plugins/elf/python/format.c
index e0195c4..95eaa9a 100644
--- a/plugins/elf/python/format.c
+++ b/plugins/elf/python/format.c
@@ -244,18 +244,20 @@ PyTypeObject *get_python_elf_format_type(void)
bool register_python_elf_format(PyObject *module)
{
- PyTypeObject *py_elf_format_type; /* Type Python 'ElfFormat' */
+ PyTypeObject *type; /* Type Python 'ElfFormat' */
PyObject *dict; /* Dictionnaire du module */
- py_elf_format_type = get_python_elf_format_type();
+ type = get_python_elf_format_type();
dict = PyModule_GetDict(module);
- if (!register_class_for_pygobject(dict, G_TYPE_ELF_FORMAT,
- py_elf_format_type, get_python_executable_format_type()))
+ if (!ensure_python_executable_format_is_registered())
return false;
- if (!define_python_elf_format_constants(py_elf_format_type))
+ if (!register_class_for_pygobject(dict, G_TYPE_ELF_FORMAT, type))
+ return false;
+
+ if (!define_python_elf_format_constants(type))
return false;
return true;
diff --git a/plugins/elf/strings.h b/plugins/elf/strings.h
index 902c2f8..3a07b96 100644
--- a/plugins/elf/strings.h
+++ b/plugins/elf/strings.h
@@ -29,7 +29,7 @@
#include <glibext/delayed.h>
-#include <gtkext/gtkstatusstack.h>
+#include <glibext/notifier.h>
diff --git a/plugins/elf/symbols.h b/plugins/elf/symbols.h
index f4a6eec..c736d56 100644
--- a/plugins/elf/symbols.h
+++ b/plugins/elf/symbols.h
@@ -29,7 +29,7 @@
#include <glibext/delayed.h>
-#include <gtkext/gtkstatusstack.h>
+#include <glibext/notifier.h>