[E-devel] [PATCH] Python EFL patches.

2010-09-28 Thread Eduardo Felipe
Folks,

here are a couple of patches that fix cross compiling Python EFL on my
environment.

Cheers,

Eduardo.
From f1bcdd2490c20858aa65b830a2e12e17bf32f415 Mon Sep 17 00:00:00 2001
From: Eduardo Felipe Castegnaro 
Date: Tue, 28 Sep 2010 15:59:55 -0300
Subject: [PATCH 1/2] Add dbus-python requisite to python-e_dbus.

DBus-python is a non-standard module of dbus, and can be located at
a different directory than dbus. This was an implicit requisite.
It's explicit now with this patch.
---
 BINDINGS/python/python-e_dbus/README   |1 +
 BINDINGS/python/python-e_dbus/configure.ac |2 +-
 2 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/BINDINGS/python/python-e_dbus/README 
b/BINDINGS/python/python-e_dbus/README
index 6266fa0..1ff547d 100644
--- a/BINDINGS/python/python-e_dbus/README
+++ b/BINDINGS/python/python-e_dbus/README
@@ -4,6 +4,7 @@ REQUIREMENTS
 
 
  * E_Dbus >= 1.0.0
+ * D-Bus Python >= 0.80
  * Ecore >= 1.0.0(indirect, E_DBus dependency)
  * D-Bus >= 0.62 (indirect, E_DBus dependency)
  * Python >= 2.4
diff --git a/BINDINGS/python/python-e_dbus/configure.ac 
b/BINDINGS/python/python-e_dbus/configure.ac
index 4b11803..c93c994 100644
--- a/BINDINGS/python/python-e_dbus/configure.ac
+++ b/BINDINGS/python/python-e_dbus/configure.ac
@@ -62,7 +62,7 @@ else
 fi
 AC_SUBST(pkgconfig_requires_private)
 
-pkgconfig_edbus_requires_libs="edbus >= 1.0.0"
+pkgconfig_edbus_requires_libs="dbus-python >= 0.83, edbus >= 1.0.0"
 AC_SUBST(pkgconfig_edbus_requires_libs)
 PKG_CHECK_MODULES([EDBUS], [$pkgconfig_edbus_requires_libs])
 
-- 
1.7.3

From 24f06e21abea9a6258e3b77f490ff91eb3ec56ca Mon Sep 17 00:00:00 2001
From: Eduardo Felipe Castegnaro 
Date: Tue, 28 Sep 2010 17:52:26 -0300
Subject: [PATCH 2/2] Add PYTHON_INCLUDES env variable for cross-compiling

When cross-compiling Cython's generated code, host and target can have
distinct python versions, located on separated directories. This
patch adds the capability of defining an environment variable containing
the location of the target's headers.
Introspection using AM_CHECK_PYTHON_HEADERS is not possible as it
cannot run the target's python (since it's another architecture).
---
 BINDINGS/python/python-e_dbus/README   |4 
 BINDINGS/python/python-e_dbus/m4/python.m4 |4 
 BINDINGS/python/python-ecore/README|4 
 BINDINGS/python/python-ecore/m4/python.m4  |4 
 BINDINGS/python/python-edje/README |4 
 BINDINGS/python/python-edje/m4/python.m4   |4 
 BINDINGS/python/python-elementary/README   |4 
 BINDINGS/python/python-elementary/m4/python.m4 |4 
 BINDINGS/python/python-emotion/README  |4 
 BINDINGS/python/python-emotion/m4/python.m4|4 
 BINDINGS/python/python-ethumb/README   |4 
 BINDINGS/python/python-ethumb/m4/python.m4 |4 
 BINDINGS/python/python-evas/README |4 
 BINDINGS/python/python-evas/m4/python.m4   |4 
 14 files changed, 56 insertions(+), 0 deletions(-)

diff --git a/BINDINGS/python/python-e_dbus/README 
b/BINDINGS/python/python-e_dbus/README
index 1ff547d..26ad615 100644
--- a/BINDINGS/python/python-e_dbus/README
+++ b/BINDINGS/python/python-e_dbus/README
@@ -34,3 +34,7 @@ variable to ./configure.
 The discovery of dependencies is done with pkg-config, thus all your
 packages must be properly accessible with such tool. Ensure your
 PKG_CONFIG_PATH and PKG_CONFIG_LIBDIR (cross-compiles) are configured!
+
+When cross-compiling, if your target's Python headers differ from your
+host's headers, specify PYTHON_INCLUDES variable containing the
+directory of the correct version of Python.h!
diff --git a/BINDINGS/python/python-e_dbus/m4/python.m4 
b/BINDINGS/python/python-e_dbus/m4/python.m4
index 3dd1aa6..02acac8 100644
--- a/BINDINGS/python/python-e_dbus/m4/python.m4
+++ b/BINDINGS/python/python-e_dbus/m4/python.m4
@@ -43,6 +43,9 @@ dnl function also defines PYTHON_INCLUDES
 AC_DEFUN([AM_CHECK_PYTHON_HEADERS],
 [AC_REQUIRE([AM_PATH_PYTHON])
 AC_MSG_CHECKING(for headers required to compile python extensions)
+if test -x "$PYTHON_INCLUDES"; then
+PYTHON_INCLUDES="-I$PYTHON_INCLUDES"
+else
 dnl deduce PYTHON_INCLUDES
 py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
 py_exec_prefix=`$PYTHON -c "import sys; print sys.exec_prefix"`
@@ -54,6 +57,7 @@ if test "$py_prefix" != "$py_exec_prefix"; then
   PYTHON_INCLUDES="$PYTHON_INCLUDES 
-I${py_exec_prefix}/include/python${PYTHON_VERSION}"
 fi
 fi
+fi
 AC_SUBST(PYTHON_INCLUDES)
 dnl check if the headers exist:
 save_CPPFLAGS="$CPPFLAGS"
diff --git a/BINDINGS/python/python-ecore/README 
b/BINDINGS/python/python-ecore/README
index b83925e..e641ef8 100644
--- a/BINDINGS/python/python-ecore/README
+++ b/BINDINGS/python/python-ecore/README
@@ -34,3 +34,7 @@ variable to ./configure.
 The discovery of dependencies is done with pkg-config, thus all your
 packages must be properly acces

Re: [E-devel] [PATCH] Python EFL patches.

2010-09-28 Thread Gustavo Sverzut Barbieri
On Tue, Sep 28, 2010 at 7:03 PM, Eduardo Felipe
 wrote:
> Folks,
>
> here are a couple of patches that fix cross compiling Python EFL on my
> environment.

all in, thanks!


-- 
Gustavo Sverzut Barbieri
http://profusion.mobi embedded systems
--
MSN: barbi...@gmail.com
Skype: gsbarbieri
Mobile: +55 (19) 9225-2202

--
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel