Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error: could not create '/usr/local/lib/python2.7/site-packages/PIL': Permission denied #215

Closed
devwithzachary opened this issue Mar 14, 2014 · 1 comment

Comments

@devwithzachary
Copy link

Still working on zope2 compiling with python for android.

So I get the below error:

Entering in ARM enviromnent
Compiler found at /home/zachary/android-ndk-r8c/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin//arm-linux-androideabi-gcc
running install
running build
running build_py
running build_ext
--------------------------------------------------------------------
PIL 1.1.7 SETUP SUMMARY
--------------------------------------------------------------------
version       1.1.7
platform      linux3 2.7.2 (default, Mar 10 2014, 15:44:33)
              [GCC 4.8.1]
--------------------------------------------------------------------
*** TKINTER support not available
--- JPEG support available
--- ZLIB (PNG/ZIP) support available
*** FREETYPE2 support not available
*** LITTLECMS support not available
--------------------------------------------------------------------
To add a missing option, make sure you have the required
library, and set the corresponding ROOT variable in the
setup.py script.

To check the build, run the selftest.py script.
running build_scripts
running install_lib
creating /usr/local/lib/python2.7/site-packages/PIL
error: could not create '/usr/local/lib/python2.7/site-packages/PIL': Permission denied

When I run:

./distribute.sh -m "openssl pil zope2 kivy"

To get this point (and thus replicate the bug/issue) I had to do the following:

  • Use a 32bit Build environment in this case Ubutu 13.10
  • Use this recipe to build Zope2:
#!/bin/bash

VERSION_zope2=${VERSION_zope2:-2.13}
URL_zope2=http://github.com/zopefoundation/Zope/archive/$VERSION_zope2.zip
BUILD_zope2=$BUILD_PATH/zope2/$(get_directory $URL_zope2)
RECIPE_zope2=$RECIPES_PATH/zope2

function prebuild_zope2() {
    true
}

function build_zope2() {
    cd $BUILD_zope2

    push_arm

    export LDFLAGS="$LDFLAGS -L$LIBS_PATH"
    export LDSHARED="$LIBLINK"

    HOSTPYTHON=/home/zac/Documents/Projects/Apps/python-for-android/build/hostpython/Python-2.7.2/hostpython
    try $HOSTPYTHON bootstrap.py
    try bin/buildout

    unset LDSHARED
    pop_arm
}

function postbuild_zope2() {
    true
}
  • Fix a bug with Zope2 and _SSL by doing:
python-for-android/build/hostpython/Python-2.7.2/Lib ln -s ../build/lib.linux-x86_64-2.7 plat-linux3

And then everything should build to the point above

@FeralBytes
Copy link
Contributor

Did you do as the output suggests
"To add a missing option, make sure you have the required
library, and set the corresponding ROOT variable in the
setup.py script."
Was the ROOT variable set?
Also did you ever get any further at creating a recipe for zope2?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants