damn, my script did not parse the author :-( Patch by: Eduardo Felipe Castegnaro eduardofelipe87,gmail.com
On Tue, Sep 28, 2010 at 8:17 PM, Enlightenment SVN <no-re...@enlightenment.org> wrote: > Log: > 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). > > > Author: barbieri > Date: 2010-09-28 16:17:55 -0700 (Tue, 28 Sep 2010) > New Revision: 52870 > > Modified: > trunk/BINDINGS/python/python-e_dbus/README > trunk/BINDINGS/python/python-e_dbus/m4/python.m4 > trunk/BINDINGS/python/python-ecore/README > trunk/BINDINGS/python/python-ecore/m4/python.m4 > trunk/BINDINGS/python/python-edje/README > trunk/BINDINGS/python/python-edje/m4/python.m4 > trunk/BINDINGS/python/python-elementary/README > trunk/BINDINGS/python/python-elementary/m4/python.m4 > trunk/BINDINGS/python/python-emotion/README > trunk/BINDINGS/python/python-emotion/m4/python.m4 > trunk/BINDINGS/python/python-ethumb/README > trunk/BINDINGS/python/python-ethumb/m4/python.m4 > trunk/BINDINGS/python/python-evas/README > trunk/BINDINGS/python/python-evas/m4/python.m4 > > Modified: trunk/BINDINGS/python/python-e_dbus/README > =================================================================== > --- trunk/BINDINGS/python/python-e_dbus/README 2010-09-28 23:17:03 UTC (rev > 52869) > +++ trunk/BINDINGS/python/python-e_dbus/README 2010-09-28 23:17:55 UTC (rev > 52870) > @@ -34,3 +34,7 @@ > 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! > > Modified: trunk/BINDINGS/python/python-e_dbus/m4/python.m4 > =================================================================== > --- trunk/BINDINGS/python/python-e_dbus/m4/python.m4 2010-09-28 23:17:03 > UTC (rev 52869) > +++ trunk/BINDINGS/python/python-e_dbus/m4/python.m4 2010-09-28 23:17:55 > UTC (rev 52870) > @@ -43,6 +43,9 @@ > 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 @@ > 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" > > Modified: trunk/BINDINGS/python/python-ecore/README > =================================================================== > --- trunk/BINDINGS/python/python-ecore/README 2010-09-28 23:17:03 UTC (rev > 52869) > +++ trunk/BINDINGS/python/python-ecore/README 2010-09-28 23:17:55 UTC (rev > 52870) > @@ -34,3 +34,7 @@ > 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! > > Modified: trunk/BINDINGS/python/python-ecore/m4/python.m4 > =================================================================== > --- trunk/BINDINGS/python/python-ecore/m4/python.m4 2010-09-28 23:17:03 > UTC (rev 52869) > +++ trunk/BINDINGS/python/python-ecore/m4/python.m4 2010-09-28 23:17:55 > UTC (rev 52870) > @@ -43,6 +43,9 @@ > 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 @@ > 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" > > Modified: trunk/BINDINGS/python/python-edje/README > =================================================================== > --- trunk/BINDINGS/python/python-edje/README 2010-09-28 23:17:03 UTC (rev > 52869) > +++ trunk/BINDINGS/python/python-edje/README 2010-09-28 23:17:55 UTC (rev > 52870) > @@ -37,3 +37,7 @@ > 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! > > Modified: trunk/BINDINGS/python/python-edje/m4/python.m4 > =================================================================== > --- trunk/BINDINGS/python/python-edje/m4/python.m4 2010-09-28 23:17:03 > UTC (rev 52869) > +++ trunk/BINDINGS/python/python-edje/m4/python.m4 2010-09-28 23:17:55 > UTC (rev 52870) > @@ -43,6 +43,9 @@ > 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 @@ > 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" > > Modified: trunk/BINDINGS/python/python-elementary/README > =================================================================== > --- trunk/BINDINGS/python/python-elementary/README 2010-09-28 23:17:03 > UTC (rev 52869) > +++ trunk/BINDINGS/python/python-elementary/README 2010-09-28 23:17:55 > UTC (rev 52870) > @@ -35,3 +35,7 @@ > 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! > > Modified: trunk/BINDINGS/python/python-elementary/m4/python.m4 > =================================================================== > --- trunk/BINDINGS/python/python-elementary/m4/python.m4 2010-09-28 > 23:17:03 UTC (rev 52869) > +++ trunk/BINDINGS/python/python-elementary/m4/python.m4 2010-09-28 > 23:17:55 UTC (rev 52870) > @@ -43,6 +43,9 @@ > 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 @@ > 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" > > Modified: trunk/BINDINGS/python/python-emotion/README > =================================================================== > --- trunk/BINDINGS/python/python-emotion/README 2010-09-28 23:17:03 UTC (rev > 52869) > +++ trunk/BINDINGS/python/python-emotion/README 2010-09-28 23:17:55 UTC (rev > 52870) > @@ -36,3 +36,7 @@ > 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! > > Modified: trunk/BINDINGS/python/python-emotion/m4/python.m4 > =================================================================== > --- trunk/BINDINGS/python/python-emotion/m4/python.m4 2010-09-28 23:17:03 > UTC (rev 52869) > +++ trunk/BINDINGS/python/python-emotion/m4/python.m4 2010-09-28 23:17:55 > UTC (rev 52870) > @@ -43,6 +43,9 @@ > 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 @@ > 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" > > Modified: trunk/BINDINGS/python/python-ethumb/README > =================================================================== > --- trunk/BINDINGS/python/python-ethumb/README 2010-09-28 23:17:03 UTC (rev > 52869) > +++ trunk/BINDINGS/python/python-ethumb/README 2010-09-28 23:17:55 UTC (rev > 52870) > @@ -36,3 +36,7 @@ > 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! > > Modified: trunk/BINDINGS/python/python-ethumb/m4/python.m4 > =================================================================== > --- trunk/BINDINGS/python/python-ethumb/m4/python.m4 2010-09-28 23:17:03 > UTC (rev 52869) > +++ trunk/BINDINGS/python/python-ethumb/m4/python.m4 2010-09-28 23:17:55 > UTC (rev 52870) > @@ -43,6 +43,9 @@ > 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 @@ > 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" > > Modified: trunk/BINDINGS/python/python-evas/README > =================================================================== > --- trunk/BINDINGS/python/python-evas/README 2010-09-28 23:17:03 UTC (rev > 52869) > +++ trunk/BINDINGS/python/python-evas/README 2010-09-28 23:17:55 UTC (rev > 52870) > @@ -32,3 +32,7 @@ > 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! > > Modified: trunk/BINDINGS/python/python-evas/m4/python.m4 > =================================================================== > --- trunk/BINDINGS/python/python-evas/m4/python.m4 2010-09-28 23:17:03 > UTC (rev 52869) > +++ trunk/BINDINGS/python/python-evas/m4/python.m4 2010-09-28 23:17:55 > UTC (rev 52870) > @@ -43,6 +43,9 @@ > 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 @@ > 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" > > > ------------------------------------------------------------------------------ > 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-svn mailing list > enlightenment-...@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/enlightenment-svn > -- 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