2016-05-05 19 views
0

私はノートブックでうまく動作する自分のコードにpysendfileモジュールを使用しようとしています。しかし、私はbuildozer android debugを使ってアンドロイドのために同じを構築しようとすると、それは次のエラーをスローします。私はbuildozer.specファイルにrequirements=pysendfileを含んでいます。BuildozerとPy4aはkivyを使用してpendendfileを構築できません

Failed building wheel for pysendfile 
Running setup.py clean for pysendfile 
Failed to build pysendfile 
Installing collected packages: pysendfile 
Running setup.py install for pysendfile: started 
Running setup.py install for pysendfile: finished with status 'error' 
Complete output from command /home/heman/kivy/mobile/.buildozer/venv/bin/python2.7 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-EFXqLT/pysendfile/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-GvNKlz-record/install-record.txt --single-version-externally-managed --compile --install-headers /home/heman/kivy/mobile/.buildozer/venv/include/site/python2.7/pysendfile --home=/tmp/tmputyngD: 
running install 
running build 
running build_ext 
building 'sendfile' extension 
creating build 
creating build/temp.linux-x86_64-2.7 
/bin/false -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/include/python2.7 -c sendfilemodule.c -o build/temp.linux-x86_64-2.7/sendfilemodule.o 
error: command '/bin/false' failed with exit status 1 

---------------------------------------- 
Command "/home/heman/kivy/mobile/.buildozer/venv/bin/python2.7 -u -c" 
import setuptools, tokenize;__file__='/tmp/pip-build EFXqLT/pysendfile/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-GvNKlz-record/install-record.txt --single-version-externally-managed --compile --install-headers /home/heman/kivy/mobile/.buildozer/venv/include/site/python2.7/pysendfile --home=/tmp/tmputyngD" failed with error code 1 in /tmp/pip-build-EFXqLT/pysendfile/ 
Command failed: pip install --target=/home/heman/kivy/mobile/.buildozer/applibs pysendfile 

Buildozer failed to execute the last command 
The error might be hidden in the log above this error 
Please read the full log, and search for it before 
raising an issue with buildozer itself. 
In case of a bug report, please add a full log with log_level = 2 

EDITは:これは私のレシピ

from pythonforandroid.toolchain import PythonRecipe 


class PysendfileRecipe(PythonRecipe): 
    name='pysendfile' 
    version = '2.0.1' 

    url = 'https://pypi.python.org/packages/source/p/pysendfile/pysendfile-{version}.tar.gz' 
    depends = ['python2'] 
    site_packages_name = 'sendfile' 

recipe = PysendfileRecipe() 

答えて

0

pysendfileのビルドプロセスが明らかにいくつかのコンパイルを必要とするので、これが起こるが、それはのpython-ため、アンドロイドには、コンパイルのレシピを持っていないです。 python-for-androidはピップでインストールしようとしますが、環境がアンドロイドをターゲットに設定されていないために失敗します(代わりに、問題をキャッチするように設定されています)。

解決策は、python-for-androidにレシピを追加してコンパイルを実行することです。このhereに関する情報があります。

+0

私はpysendfileのレシピを作成し、/ python-for-android/pythonforandroid/recipes/pysendfileに保存しました。端末はまだpysendfileにレシピがないと言っています。何か間違っているのですか? –

+0

あなたはそれをbuildozerが使用しているpython-for-androidフォルダに置きましたか? – inclement

+0

私はここに/ home/heman/python-for-android/pythonforandroid/recipes/pysendfileを配置しました。どのフォルダについて話していますか? –

関連する問題