Skip to content

Commit 0c084ad

Browse files
committed
add zope and twisted from deakblue (reworked to remove some files and fix compilation)
1 parent 5374569 commit 0c084ad

File tree

3 files changed

+84
-1
lines changed

3 files changed

+84
-1
lines changed

docs/source/recipes.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Available modules
22
=================
33

44
List of available modules: jpeg pil png sdl sqlite3 pygame kivy android
5-
libxml2 libxslt lxml ffmpeg openssl chipmunk
5+
libxml2 libxslt lxml ffmpeg openssl chipmunk zope twisted
66

77
The up-to-date list is available at:
88
https://github.com/kivy/python-for-android/tree/master/recipes

recipes/twisted/recipe.sh

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
#!/bin/bash
2+
3+
VERSION_twisted=11.1
4+
URL_twisted=http://twistedmatrix.com/Releases/Twisted/$VERSION_twisted/Twisted-$VERSION_twisted.0.tar.bz2
5+
DEPS_twisted=(zope)
6+
MD5_twisted=
7+
BUILD_twisted=$BUILD_PATH/twisted/$(get_directory $URL_twisted)
8+
RECIPE_twisted=$RECIPES_PATH/twisted
9+
10+
function prebuild_twisted() {
11+
true
12+
}
13+
14+
function build_twisted() {
15+
16+
if [ -d "$BUILD_PATH/python-install/lib/python2.7/site-packages/twisted" ]; then
17+
return
18+
fi
19+
20+
cd $BUILD_twisted
21+
22+
push_arm
23+
export LDFLAGS="$LDFLAGS -L$LIBS_PATH"
24+
export LDSHARED="$LIBLINK"
25+
26+
# fake try to be able to cythonize generated files
27+
$BUILD_PATH/python-install/bin/python.host setup.py build_ext
28+
try find . -iname '*.pyx' -exec cython {} \;
29+
try $BUILD_PATH/python-install/bin/python.host setup.py build_ext -v
30+
try find build/lib.* -name "*.o" -exec $STRIP {} \;
31+
try $BUILD_PATH/python-install/bin/python.host setup.py install -O2
32+
33+
try rm -rf $BUILD_PATH/python-install/lib/python*/site-packages/twisted/test
34+
try rm -rf $BUILD_PATH/python-install/lib/python*/site-packages/twisted/*/test
35+
36+
unset LDSHARED
37+
38+
pop_arm
39+
}
40+
41+
function postbuild_twisted() {
42+
true
43+
}
44+

recipes/zope/recipe.sh

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
#!/bin/bash
2+
3+
VERSION_zope=3.8.0
4+
URL_zope=http://pypi.python.org/packages/source/z/zope.interface/zope.interface-$VERSION_zope.tar.gz
5+
DEPS_zope=(python)
6+
MD5_zope=8ab837320b4532774c9c89f030d2a389
7+
BUILD_zope=$BUILD_PATH/zope/$(get_directory $URL_zope)
8+
RECIPE_zope=$RECIPES_PATH/zope
9+
10+
function prebuild_zope() {
11+
true
12+
}
13+
14+
function build_zope() {
15+
16+
if [ -d "$BUILD_PATH/python-install/lib/python2.7/site-packages/zope" ]; then
17+
return
18+
fi
19+
20+
cd $BUILD_zope
21+
22+
push_arm
23+
24+
export LDFLAGS="$LDFLAGS -L$LIBS_PATH"
25+
export LDSHARED="$LIBLINK"
26+
27+
try $BUILD_PATH/python-install/bin/python.host setup.py install -O2
28+
try rm -rf $BUILD_PATH/python-install/lib/python*/site-packages/zope/interface/tests
29+
try rm -rf $BUILD_PATH/python-install/lib/python*/site-packages/zope/interface/*.txt
30+
31+
unset LDSHARED
32+
33+
pop_arm
34+
}
35+
36+
function postbuild_zope() {
37+
true
38+
}
39+

0 commit comments

Comments
 (0)