首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >由于python模块丢失,快照快照失败

由于python模块丢失,快照快照失败
EN

Ask Ubuntu用户
提问于 2016-05-30 00:33:40
回答 1查看 2K关注 0票数 6

我试图通过重新包装统一调整工具来学习一些简单的桌面包装。我发现这些文档不太出色,但到目前为止,我有一个snapcraft.yaml文件,如下所示:

代码语言:javascript
复制
name: unity-tweak-tool
version: 1
summary: configuration tool for the Unity desktop environment
description: |
 Unity Tweak Tool is a settings manager for the Unity desktop.
 It provides users with a fast, simple and easy-to-use interface 
 with which to access many useful and little known features and settings 
 of the desktop environment that one may want to configure.

apps:
  unity-tweak-tool:
    command: $SNAP/usr/bin/unity-tweak-tool
    plugs: [unity7]
parts:
  unity-tweak-tool:
    plugin: python3
    source: git://github.com/Seth-Johnson/unity-tweak-tool.git
    source-type: git
    build-packages:
        - python3-distutils-extra
        - python3-all
        - python3-dbus
        - python-dev
    stage-packages:
        - gir1.2-glib-2.0
        - gir1.2-gtk-3.0
        - python3-xdg
        - python3-cairo
        - unity-webapps-service  

但是,当我运行snapcraft snap时,setup.py总是会失败,因为缺少几个python模块:

代码语言:javascript
复制
  Running setup.py install for unity-tweak-tool ... error
    Complete output from command /home/sethj/projects/snappy-testing/parts/unity-tweak-tool/install/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-s6dwhgys-build/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-xxv1mi7p-record/install-record.txt --single-version-externally-managed --compile --home=/tmp/tmp2y5izah7:
    ERROR: Python module values not found
    ERROR: Python module apport not found
    ERROR: Python module apport.hookutils not found
    WARNING: syntax errors in notes/wizardry.py: Missing parentheses in call to 'print' (wizardry.py, line 9)
    ERROR: Python module dbus not found
    ERROR: Python module dbus.service not found
    ERROR: Python module dbus.mainloop.glib not found

(全输出这里)

我承认我不能百分之百确定我这样做是正确的,但据我所知,它应该是构建在building下面列出的软件包,它满足了统一调整工具的构建要求。

我哪里出问题了?

EN

回答 1

Ask Ubuntu用户

回答已采纳

发布于 2016-05-30 13:23:14

对于python,您可能希望其中的一些build-packagesstage-packages。python将PYTHONPATH设置为简单易用,这就是它缺少这些包的原因(您可以将它们安装在主机系统上)。

顺便说一句,如果上游有一个适当的install_requiressetup.py中,那么这些依赖关系就会自动为您处理。

票数 6
EN
页面原文内容由Ask Ubuntu提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://askubuntu.com/questions/779267

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档