- android - 多次调用 OnPrimaryClipChangedListener
- android - 无法更新 RecyclerView 中的 TextView 字段
- android.database.CursorIndexOutOfBoundsException : Index 0 requested, 光标大小为 0
- android - 使用 AppCompat 时,我们是否需要明确指定其 UI 组件(Spinner、EditText)颜色
我在一些服务器上安装的 Python (2.6) 编译时没有我现在需要的 curses 支持,尽管服务器安装了 libncurses5,Python 没有为它编译绑定(bind),所以当我“导入 curses”时,我得到:
"ImportError: No module named _curses"
我的/lib/目录有以下文件和符号链接(symbolic link):
lrwxrwxrwx 1 root root 17 2010-02-13 05:50 /lib/libncurses.so.5 -> libncurses.so.5.7
-rw-r--r-- 1 root root 251K 2008-12-14 22:31 /lib/libncurses.so.5.7
lrwxrwxrwx 1 root root 18 2010-02-13 05:50 /lib/libncursesw.so.5 -> libncursesw.so.5.7
-rw-r--r-- 1 root root 299K 2008-12-14 22:31 /lib/libncursesw.so.5.7
和/lib64/有:
lrwxrwxrwx 1 root root 20 2010-08-13 12:26 /lib64/libncurses.so -> /lib/libncurses.so.5
lrwxrwxrwx 1 root root 17 2010-02-13 05:50 /lib64/libncurses.so.5 -> libncurses.so.5.7
-rw-r--r-- 1 root root 251K 2008-12-14 22:31 /lib64/libncurses.so.5.7
lrwxrwxrwx 1 root root 18 2010-02-13 05:50 /lib64/libncursesw.so.5 -> libncursesw.so.5.7
-rw-r--r-- 1 root root 299K 2008-12-14 22:31 /lib64/libncursesw.so.5.7
/usr/lib64 和/usr/lib 都有:
lrwxrwxrwx 1 root root 20 2010-08-13 12:20 /usr/lib64/libncurses.so -> /lib/libncurses.so.5
当我再次尝试“制作”python 时,我在最后收到以下警告:
Failed to find the necessary bits to build these modules:
_curses_panel _tkinter bsddb185
bz2 dl gdbm
imageop readline sunaudiodev
To find the necessary bits, look in setup.py in detect_modules() for the module's name.
Failed to build these modules:
_curses
要重新编译支持 curses 的 Python,我需要做什么?我在这里缺少什么?
谢谢!
最佳答案
是的,没错。安装 libncurses5-dev
并在 python
安装上运行 'make'
和 'make install'
成功了。在我的自定义 python 安装上尝试安装和启动 bpython
时,我首先遇到了 _curses
错误。
关于Python 无法在 Debian Lenny 上编译 _curses 模块,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3478041/
我有以下代码为我的 roguelike 游戏渲染显示。它包括渲染 map 。 def render_all(self): for y in range(self.height):
我正在尝试使用 Python 编写一个脚本,只要您按下空格键,它就会将所有键入的字符转换为“a”。例如,我输入“python”,然后输入空格,然后“python”将转换为“aaaaaa”。 impor
这是我的代码,我不知道为什么在终端上运行这个程序时出现错误。这是我的Python代码Python 3.5,我是curses模块的新手,无法处理这个错误,谢谢提前 import urllib.reque
我在一些服务器上安装的 Python (2.6) 编译时没有我现在需要的 curses 支持,尽管服务器安装了 libncurses5,Python 没有为它编译绑定(bind),所以当我“导入 cu
我正在尝试运行这个: from blessings import Terminal t = Terminal() print (t.bold('Hi there!')) print (t.bold_r
在 CentOS 7 上从源代码编译 Python 3.4.3 时,README 指示运行 ./configure make make test sudo make install 第二步,make
代码是: from curses import * from curses.panel import * def main(stdscr): start_color() curs_se
我正在尝试使用 TensorFlow CLI 调试器来识别在网络训练期间导致 NaN 的操作,但是当我尝试运行代码时出现错误: _curses.error: cbreak() 返回错误 我正在通过 S
背景 Windows 7 x 64Python 2.7 Django 1.4带 Redis bundle 的 celery 在尝试运行 manage.py celeryev 时,我在终端中收到以下错误
我是 python 和 ubuntu 的新手。我正在尝试在 ubuntu 12.10 上安装 python 2.6.5。我已经有 python 2.7.3 并且正在尝试并排安装 2.6.5 现有的 p
我是一名优秀的程序员,十分优秀!