【问题标题】:Compile errors when setting up Plone development environment设置 Plone 开发环境时编译错误
【发布时间】:2019-01-17 15:42:54
【问题描述】:

我正在尝试按照此处的演练为我的 Plone 5.1 服务器生成一个新主题:

https://training.plone.org/5/theming/theme-package.html

我正在使用运行 clang-1000.11.45.5(XCode 附带的那个)和 Python 3.6.4(通过 Anaconda 安装)的 MacOS 10.13.6。由于 mr.bob 生成的构建脚本似乎不包含所有依赖项,特别是 plone.recipe.zope2instance==4.2.22,因此我遇到了一些麻烦。当我尝试手动安装该依赖项时,出现以下编译错误:

src/Persistence/_Persistence.c:178:5: error: non-void function 'init_Persistence' should return a value [-Wreturn-type]
    return;
    ^
17 warnings and 7 errors generated.
error: command 'clang' failed with exit status 1

我尝试升级到最新版本的 mr.bob 和模板,然后使用 plonecli 创建并启动构建,但我得到了相同的编译错误。

该模块中有很多类似的内容。我该如何解决这个问题,以便我可以完成安装该依赖项并完成我的构建?

【问题讨论】:

  • 请考虑在我们的论坛community.plone.org 中向 Plone 提问,我们中的更多人会看到它们!

标签: themes plone plone-5.x


【解决方案1】:

尝试使用 Python 2.7,Zope 和 Plone 支持更好。

【讨论】:

  • Plone 需要 Python 2.7,直到并包括 Plone 5.1.x。
  • 我以为它可以工作,但是当我运行 buildout 时,我收到了错误 ContextualVersionConflict: (Zope2 2.13.28 (/anaconda3/envs/python2.7/lib/python2.7/site-packages), Requirement.parse('Zope2>=4.0a5'), set(['Products.ZCatalog', 'Products.BTreeFolder2', 'Products.StandardCacheManagers']))
【解决方案2】:

Plone 使用 Python 2.7.x 直到版本 5.1。 在 Plone 5.2 中,您可以选择在 Python 3 下运行 Plone,但是您必须使用 WSGI-Server 而不是 ZServer。现在只需将 Plone 5.1 与 Python 2.7 一起使用,因为 Plone 5.2 仍未最终发布。

【讨论】:

    猜你喜欢
    • 2020-04-29
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-09-23
    • 1970-01-01
    相关资源
    最近更新 更多