LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1079|回复: 2

[求助]kdevelop 开发ncurses程序问题!

[复制链接]
发表于 2009-2-6 12:14:04 | 显示全部楼层 |阅读模式
在下,刚开始学习linux编程,想用kdevelop编译ncurses例程
但是链接库时出错
/usr/bin/gmake -f CMakeFiles/hello_world.dir/build.make CMakeFiles/hello_world.dir/build
Entering directory /home/johnseanfenton/clanguge/lx/hello_world
linking C executable hello_world (C executable hello_world)
/usr/bin/cmake -E cmake_link_script CMakeFiles/hello_world.dir/link.txt --verbose=1
linking hello_world (gcc)
CMakeFiles/hello_world.dir/main.o: In function `main':
main.c.text+0x12): undefined reference to `initscr'
main.c.text+0x1e): undefined reference to `printw'
main.c.text+0x23): undefined reference to `stdscr'
main.c.text+0x2b): undefined reference to `wrefresh'
main.c.text+0x3d): undefined reference to `endwin'
collect2: ld returned 1 exit status
gmake[2]: *** [hello_world] Error 1
gmake[2]: Target `CMakeFiles/hello_world.dir/build' not remade because of errors.
Leaving directory /home/johnseanfenton/clanguge/lx/hello_world
Entering directory /home/johnseanfenton/clanguge/lx/hello_world
gmake[1]: *** [CMakeFiles/hello_world.dir/all] Error 2
gmake[1]: Target `all' not remade because of errors.
Leaving directory /home/johnseanfenton/clanguge/lx/hello_world
Entering directory /home/johnseanfenton/clanguge/lx/hello_world
gmake: *** [all] Error 2
gmake: Target `default_target' not remade because of errors.
*** Exited with status: 2 ***
哪位大侠来指点一下?谢谢!
发表于 2009-2-6 13:54:04 | 显示全部楼层
用 cmake 的话,你得搜索一下 ncurse 库,然后增加相关内容,例如:

http://www.cmake.org/cmake/help/ ... l#module:FindCurses
回复 支持 反对

使用道具 举报

 楼主| 发表于 2009-2-7 16:45:10 | 显示全部楼层
有图形界面的设置么?
大侠能说的详细一点么?
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表