onefang pushed a commit to branch master.

http://git.enlightenment.org/admin/devs.git/commit/?id=0c490b06246243416fe883b0eef4f4fbf97adc68

commit 0c490b06246243416fe883b0eef4f4fbf97adc68
Author: David Walter Seikel <won_f...@yahoo.com.au>
Date:   Sat Nov 9 15:42:40 2013 +1000

    build_efl: Various half successful attempts to fix up python building.
    
    Mostly by using a custom cython install, coz the Ubuntu TLS one was 
classified as too old by the python bindings developers.
---
 developers/onefang/build_efl.lua | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

diff --git a/developers/onefang/build_efl.lua b/developers/onefang/build_efl.lua
index dab210e..08b8cc0 100755
--- a/developers/onefang/build_efl.lua
+++ b/developers/onefang/build_efl.lua
@@ -35,7 +35,7 @@ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 
 -- TODO - Might need more environment stuff for cmake EFL find functions?
--- TODO - Python builds still not working.
+-- TODO - Python builds still not working.  Some mysterious issue with the 
custom cython and sudo install.
 
 
 -- Read environment variables as if they were global variables.
@@ -45,19 +45,20 @@ setmetatable(getfenv(), {__index = f})
 
 -- TODO - Should get these out of a config lua script, but keep these as 
defaults.
 local installPath      = '/opt/e17'
+local cythonPath       = PWD .. '/cython'
 local threads          = 5
 local envVars          =
 {
-    'PATH="' .. installPath .. '/bin:$PATH"',
+    'PATH="' .. installPath .. '/bin:' .. cythonPath .. '/bin:$PATH"',
     'LD_LIBRARY_PATH="' .. installPath .. '/lib:$LD_LIBRARY_PATH"',
     'PKG_CONFIG_PATH="' .. installPath .. '/lib/pkgconfig:$PKG_CONFIG_PATH"',
     'CC="ccache gcc"',
     'CFLAGS="-g -W -Wall -Wextra -Wshadow"', 
 --    'CFLAGS="-O2 -march=native -ffast-math -g3 -W -Wall -Wextra -Wshadow"',
-    'CPPFLAGS="$CPPFLAGS -I' .. installPath .. '/include"',
+    'CPPFLAGS="$CPPFLAGS -I' .. installPath .. '/include -I`python -c \"import 
distutils.sysconfig; print 
distutils.sysconfig.get_python_inc(prefix=\'/usr\')\" 2>/dev/null`"',
     'LDFLAGS="$LDFLAGS -L' .. installPath .. '/lib"',
 --    'CMAKE_MODULE_PATH="../cmake/Modules/legacy:$CMAKE_MODULE_PATH"'
-       'PYTHONPATH="`python -c \"import distutils.sysconfig; print 
distutils.sysconfig.get_python_lib(prefix=\'' .. installPath ..'\')\" 
2>/dev/null`:$PYTHONPATH"',
+       'PYTHONPATH="`python -c \"import distutils.sysconfig; print 
distutils.sysconfig.get_python_lib(prefix=\'' .. installPath ..'\')\" 
2>/dev/null`:' .. cythonPath .. ':$PYTHONPATH"',
     'PYTHONINCLUDE="`python -c \"import distutils.sysconfig; print 
distutils.sysconfig.get_python_inc(prefix=\'' .. installPath ..'\')\" 
2>/dev/null`:$PYTHONINCLUDE"',
 }
 
@@ -71,7 +72,7 @@ local eflExtra =
     'egraph', 'ekbd', 'elev8', 'elocation', 'email', 'epdf', 'eupnp', 'efx', 
'esskyuehl', 'etam', 'etrophy',
     'ffi-efl',
     --[['python-evas', 'python-ecore', 'python-e_dbus', 'python-edje', 
'python-ethumb', 'python-emotion', 'python-elementary' Legacy bindings.]]
-    --[['python-efl' Ubuntu cython is too old.]]
+    'python-efl' --[[ Ubuntu cython is too old.]]
 }
 local binBasic = {'exchange', 'enlightenment', 'exalt', 'emprint', 'geneet'}
 local eModulesExtra = {}
@@ -153,8 +154,8 @@ local function build(i, package)
                if good then good = runBuildCommand(i, package, path, 'cd build 
&& make PREFIX=' .. installPath .. ' -j' .. threads) end
                if good then good = runBuildCommand(i, package, path, 'cd build 
&& sudo make PREFIX=' .. installPath .. ' install') end
            elseif fileExists(path .. '/setup.py') then
-               if good then good = runBuildCommand(i, package, path, 'python 
setup.py build build_ext --include-dirs=$PYTHONINCLUDE') end
-               if good then good = runBuildCommand(i, package, path, 'sudo 
python setup.py install --prefix=' .. installPath .. ' install_headers 
--install-dir=$PYTHONINCLUDE') end
+               if good then good = runBuildCommand(i, package, path, 'python 
setup.py build build_ext --include-dirs=$PYTHONINCLUDE') end
+               if good then good = runBuildCommand(i, package, path, 'sudo -E 
python setup.py install --prefix=' .. installPath .. ' install_headers 
--install-dir=$PYTHONINCLUDE') end
                good = false
            elseif fileExists(path .. '/Makefile') then         -- Keep this 
last, as others might generate this, so we want to detect those others first.
                if good then good = runBuildCommand(i, package, path, 'make 
PREFIX=' .. installPath .. ' -j' .. threads) end

-- 


Reply via email to