【问题标题】:Yocto recipe pyinstallerYocto 食谱 pyinstaller
【发布时间】:2021-10-23 03:22:03
【问题描述】:

我正在尝试构建 pyinstaller 配方,我在这里使用了 pipoe,但是当我告诉它继承 pypi setuptools 时出现此错误。有人可以帮忙吗? 谢谢。

错误:/home/yasmine/yocto/poky/meta-pyinst/recipes-pyinstaller/pyinstaller/python-altgraph_0.17.bb:16 处的 ParseError:无法继承文件类/setuptools.bbclass

【问题讨论】:

    标签: pyinstaller yocto pypi


    【解决方案1】:

    首先,使用 pipoe 自动创建 python 配方是一个好习惯。

    查看我的回复here,了解如何使用它。

    我用它来创建pyinstaller 配方,它检测到pyinstaller 在运行时依赖于RDEPENDS

    • python3-altgraph
    • python3-pyinstaller-hooks-contrib

    所以,这里是食谱:

    python3-pyinstaller_4.5.1.bb

    SUMMARY = "PyInstaller bundles a Python application and all its dependencies into a single package."
    HOMEPAGE = "http://www.pyinstaller.org/"
    AUTHOR = "Hartmut Goebel, Giovanni Bajo, David Vierra, David Cortesi, Martin Zibricky <>"
    LICENSE = "CLOSED"
    
    SRC_URI = "https://files.pythonhosted.org/packages/a9/d9/9fdfb0ac2354d059e466d562689dbe53a23c4062019da2057f0eaed635e0/pyinstaller-4.5.1.tar.gz"
    SRC_URI[md5sum] = "cd1fab890e538ed62ac9121e043632e3"
    SRC_URI[sha256sum] = "30733baaf8971902286a0ddf77e5499ac5f7bf8e7c39163e83d4f8c696ef265e"
    
    S = "${WORKDIR}/pyinstaller-4.5.1"
    
    RDEPENDS_${PN} = "python3-setuptools python3-altgraph python3-pyinstaller-hooks-contrib"
    
    DEPENDS += "python3-wheel python3-wheel-native"
    
    inherit setuptools3
    

    python3-pyinstaller-hooks-contrib_2021.2.bb

    SUMMARY = "Community maintained hooks for PyInstaller"
    HOMEPAGE = "https://github.com/pyinstaller/pyinstaller-hooks-contrib"
    AUTHOR = " <>"
    LICENSE = "CLOSED"
    LIC_FILES_CHKSUM = "file://LICENSE;md5=822bee463f4e00ac4478593130e95ccb"
    
    SRC_URI = "https://files.pythonhosted.org/packages/eb/fa/fe062e44776ab8edb4ac62daca1a02bb744ebdd556ec7a75c19c717e80b4/pyinstaller-hooks-contrib-2021.2.tar.gz"
    SRC_URI[md5sum] = "322f5534dd0df2d3fbb8fd55ec7cddbf"
    SRC_URI[sha256sum] = "7f5d0689b30da3092149fc536a835a94045ac8c9f0e6dfb23ac171890f5ea8f2"
    
    S = "${WORKDIR}/pyinstaller-hooks-contrib-2021.2"
    
    RDEPENDS_${PN} = ""
    
    inherit setuptools3
    

    python3-altgraph_0.17.bb

    SUMMARY = "Python graph (network) package"
    HOMEPAGE = "https://altgraph.readthedocs.io"
    AUTHOR = "Ronald Oussoren <ronaldoussoren@mac.com>"
    LICENSE = "MIT"
    LIC_FILES_CHKSUM = "file://LICENSE;md5=3590eb8d695bdcea3ba57e74adf8a4ed"
    
    SRC_URI = "https://files.pythonhosted.org/packages/22/5a/ac50b52581bbf0d8f6fd50ad77d20faac19a2263b43c60e7f3af8d1ec880/altgraph-0.17.tar.gz"
    SRC_URI[md5sum] = "9450020282270749db205038b8c90b55"
    SRC_URI[sha256sum] = "1f05a47122542f97028caf78775a095fbe6a2699b5089de8477eb583167d69aa"
    
    S = "${WORKDIR}/altgraph-0.17"
    
    RDEPENDS_${PN} = ""
    
    inherit setuptools3
    

    如果你有自定义层,你可以创建:

    meta-custom/recipes-python/pyinstaller
    

    并将所有三个食谱都放入其中。

    现在,只需将 python3-pyinstaller 添加到 IMAGE_INSTALL 即可:

    IMAGE_INSTALL_append = " python3-pyinstaller"
    

    【讨论】:

      猜你喜欢
      • 2021-05-18
      • 2021-04-16
      • 2019-12-05
      • 2018-07-17
      • 1970-01-01
      • 2020-11-23
      • 1970-01-01
      • 1970-01-01
      • 2020-01-12
      相关资源
      最近更新 更多