- c - 在位数组中找到第一个零
- linux - Unix 显示有关匹配两种模式之一的文件的信息
- 正则表达式替换多个文件
- linux - 隐藏来自 xtrace 的命令
这对我来说没有意义。如何使用 setup.py 安装 Cython,然后还使用 setup.py 编译库代理?
import sys, imp, os, glob
from setuptools import setup
from Cython.Build import cythonize # this isn't installed yet
setup(
name='mylib',
version='1.0',
package_dir={'mylib': 'mylib', 'mylib.tests': 'tests'},
packages=['mylib', 'mylib.tests'],
ext_modules = cythonize("mylib_proxy.pyx"), #how can we call cythonize here?
install_requires=['cython'],
test_suite='tests',
)
后来:python setup.py 构建
Traceback (most recent call last):
File "setup.py", line 3, in <module>
from Cython.Build import cythonize
ImportError: No module named Cython.Build
这是因为还没有安装cython。
奇怪的是很多项目都是这样写的。快速的 github 搜索揭示了同样多的内容:https://github.com/search?utf8=%E2%9C%93&q=install_requires+cython&type=Code
最佳答案
据我了解,这里是PEP 518进来 - 另见 some clarifications作者之一。
这个想法是您向 Python 项目/包中添加另一个文件:pyproject.toml
。它应该包含有关构建环境依赖性的信息(除其他外,长期)。 pip
(或任何其他包管理器)可以查看此文件并在运行 setup.py(或任何其他构建脚本)之前安装所需的构建环境。因此,pyproject.toml
可能如下所示:
[build-system]
requires = ["setuptools", "wheel", "Cython"]
这是一个相当新的发展,截至目前(2019 年 1 月),它还没有被 Python 社区最终确定/批准,尽管(有限)support was added to pip 2017 年 5 月/10.0 版。
关于python - 在涉及 Cython 的 setup.py 中,如果 install_requires,那么如何从库中导入一些东西?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44554882/
我需要编辑或替换 About Setup 中的文本Inno Setup 的对话框文本。 这是一张图片: 在互联网上查看我得到了这个代码: [Files] Source: CallbackCtrl.dl
我最近发现一些旧的 PC 游戏可以在我的 Windows 10 64 位计算机上玩。我查看了各种在线资源以使游戏正常运行。现在我有兴趣为使游戏正常运行所采取的所有各种步骤创建一个自定义安装程序。我成功
是否可以获得用于 Inno Setup 安装程序的 Inno Setup 版本号? 我找不到记录的开关来返回其版本号(例如 5.5.6),而且似乎没有暴露给 Inno Setup 脚本的预定义版本常量
如何更改 setup-*.bin(Inno Setup 内部压缩存档文件)的名称、扩展名和位置 默认存档位置:{src} 我要的位置:{src}\Data(Data是一个文件夹。) 最佳答案 有很多方
这是用于 Inno Setup 的 [Setup] 部分中的 LicenseFile 属性的标准 RTF 文档: 是否可以向此页面添加打印按钮以触发打印许可协议(protocol)? 我看到了一个类似
我有一个 Inno Setup 脚本可以将我的应用程序变成一个 exe。 当我使用 Inno Setup 版本 6 编译代码时,输出文件大小为 110MB(如 Windows Explorer 大
编译了 Inno Setup 脚本 (IS v5.4.2),但是当运行生成的 Setup.exe 时,出现了一个错误对话框,内容如下: 内部错误:ExtractTemporaryFile:找不到文件“
Inno Setup - 我想创建一个类似于屏幕截图的安装程序。 安装程序应在左侧突出显示当前步骤。 如何实现? 最佳答案 @Bill_Stewart 是正确的,普通的 Inno Setup 不提供如
图像作为安装程序背景。如何使用 inno 5.5.9 做到这一点? 最佳答案 我认为这在 Inno Setup 中是不可能的。也许是一些 Inno Setup 克隆。 问题是Inno Setup中的所
这个问题在这里已经有了答案: Inno Setup - Signing fails with "Sign Tool failed with exit code 0x1" (2 个答案) 关闭 3 年
如何获取有关安装程序中包含的文件的信息(最后修改时间戳、文件大小)?通过使用文件的路径,很容易引用磁盘上的文件。但是当文件没有路径时,如何在安装程序中引用它呢? 当安装程序初始化时,我想检查磁盘上是否
Inno Setup 中的单词补全是如何工作的? 如果我在代码中的任何标识符或单词的中间或末尾按 Alt+Right,则没有任何反应。 我找不到任何要安装的扩展,也找不到该主题的 Internet 答
从这里开始:Inno Setup Placing image/control on custom page . 这是做我需要的: CustomPage := CreateCustomPage(wpLi
我的安装程序在组件页面中有一个可视错误。在您开始向下滚动页面之前看起来还不错,但开始看起来一团糟。 我认为问题出在代码中的某个地方,但仅在绝对干净的脚本上重新创建了组件部分,问题仍然存在。尝试更改缩放
如何在 Inno Setup 编译器中为我们的设置提供背景全屏图像。 喜欢下面这张图。 最佳答案 不要那样做。这违反了 Windows 设计指南。 无论如何,如果必须,请使用 WindowVisibl
如何在代码中使用 [Setup] 部分的值? 我怀疑我没有正确使用该工具;也许我应该以完全不同的方式来做这件事。 [Setup] MyValue=some value [code] function
如何自定义 Inno Setup 安装程序的欢迎页面? 我想创建一个类似于 Skype 安装程序的安装程序,只有 3 个页面: 带有一些选项的自定义欢迎页面 进度页 使用“运行程序”选项完成页面 但是
我已经为我想更新的程序创建了文件。 我希望在安装之前,检查程序是否也在标准目录中,如果不是,则正确的目录可以选择程序所在的位置。 我试过这个: [Files] Source: "C:\Data"; D
我想在您选择安装位置的页面之后创建一个自定义向导页面。 我已经在 InitializeWizard 中看到了如何创建自定义页面并将它们添加到向导中。程序。 我的问题是,当我创建自定义页面时,安装位置选
我已经安装了我的程序。但是如果我尝试再次安装它,它会安装并且程序被替换。 我看到这个问题 Inno Setup - How to display notifying message while ins
我是一名优秀的程序员,十分优秀!