LinuxSir.cn,穿越时空的Linuxsir!

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

编译内核时出现错误,大家看看这是什么错误~

[复制链接]
发表于 2006-7-16 22:00:37 | 显示全部楼层 |阅读模式
# make menuconfig
  HOSTCC  scripts/basic/fixdep
  HOSTCC  scripts/basic/split-include
  HOSTCC  scripts/basic/docproc
  HOSTCC  scripts/kconfig/conf.o
  HOSTCC  scripts/kconfig/kxgettext.o
  HOSTCC  scripts/kconfig/mconf.o
  SHIPPED scripts/kconfig/zconf.tab.c
  SHIPPED scripts/kconfig/lex.zconf.c
  SHIPPED scripts/kconfig/zconf.hash.c
  HOSTCC  scripts/kconfig/zconf.tab.o
  HOSTLD  scripts/kconfig/mconf
  HOSTCC  scripts/kconfig/lxdialog/checklist.o
In file included from scripts/kconfig/lxdialog/checklist.c:24:
scripts/kconfig/lxdialog/dialog.h:31:20: error: curses.h: No such file or directory
In file included from scripts/kconfig/lxdialog/checklist.c:24:
scripts/kconfig/lxdialog/dialog.h:128: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘use_colors’
scripts/kconfig/lxdialog/dialog.h:129: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘use_shadow’
scripts/kconfig/lxdialog/dialog.h:131: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘attributes’
scripts/kconfig/lxdialog/dialog.h:143: error: expected ‘)’ before ‘*’ token
scripts/kconfig/lxdialog/dialog.h:146: error: expected ‘)’ before ‘*’ token
scripts/kconfig/lxdialog/dialog.h:147: error: expected ‘)’ before ‘*’ token
scripts/kconfig/lxdialog/dialog.h:148: error: expected ‘)’ before ‘*’ token
scripts/kconfig/lxdialog/dialog.h:149: error: expected ‘)’ before ‘*’ token
scripts/kconfig/lxdialog/dialog.h:151: error: expected ‘)’ before ‘*’ token
scripts/kconfig/lxdialog/checklist.c:31: error: expected ‘)’ before ‘*’ token
scripts/kconfig/lxdialog/checklist.c:59: error: expected ‘)’ before ‘*’ token
scripts/kconfig/lxdialog/checklist.c:95: error: expected ‘)’ before ‘*’ token
scripts/kconfig/lxdialog/checklist.c: In function ‘dialog_checklist’:
scripts/kconfig/lxdialog/checklist.c:117: error: ‘WINDOW’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:117: error: (Each undeclared identifier is reported only once
scripts/kconfig/lxdialog/checklist.c:117: error: for each function it appears in.)
scripts/kconfig/lxdialog/checklist.c:117: error: ‘dialog’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:117: error: ‘list’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:117: warning: left-hand operand of comma expression has no effect
scripts/kconfig/lxdialog/checklist.c:117: warning: statement with no effect
scripts/kconfig/lxdialog/checklist.c:121: warning: implicit declaration of function ‘endwin’
scripts/kconfig/lxdialog/checklist.c:122: warning: implicit declaration of function ‘fprintf’
scripts/kconfig/lxdialog/checklist.c:122: warning: incompatible implicit declaration of built-in function ‘fprintf’
scripts/kconfig/lxdialog/checklist.c:122: error: ‘stderr’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:140: error: ‘COLS’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:141: error: ‘LINES’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:143: warning: implicit declaration of function ‘draw_shadow’
scripts/kconfig/lxdialog/checklist.c:143: error: ‘stdscr’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:145: warning: implicit declaration of function ‘newwin’
scripts/kconfig/lxdialog/checklist.c:146: warning: implicit declaration of function ‘keypad’
scripts/kconfig/lxdialog/checklist.c:146: error: ‘TRUE’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:148: warning: implicit declaration of function ‘draw_box’
scripts/kconfig/lxdialog/checklist.c:148: error: ‘attributes’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:149: warning: implicit declaration of function ‘wattrset’
scripts/kconfig/lxdialog/checklist.c:150: warning: implicit declaration of function ‘mvwaddch’
scripts/kconfig/lxdialog/checklist.c:152: warning: implicit declaration of function ‘waddch’
scripts/kconfig/lxdialog/checklist.c:156: warning: implicit declaration of function ‘print_title’
scripts/kconfig/lxdialog/checklist.c:159: warning: implicit declaration of function ‘print_autowrap’
scripts/kconfig/lxdialog/checklist.c:166: warning: implicit declaration of function ‘subwin’
scripts/kconfig/lxdialog/checklist.c:190: warning: implicit declaration of function ‘print_item’
scripts/kconfig/lxdialog/checklist.c:194: warning: implicit declaration of function ‘print_arrows’
scripts/kconfig/lxdialog/checklist.c:197: warning: implicit declaration of function ‘print_buttons’
scripts/kconfig/lxdialog/checklist.c:199: warning: implicit declaration of function ‘wnoutrefresh’
scripts/kconfig/lxdialog/checklist.c:201: warning: implicit declaration of function ‘doupdate’
scripts/kconfig/lxdialog/checklist.c:204: warning: implicit declaration of function ‘wgetch’
scripts/kconfig/lxdialog/checklist.c:211: error: ‘KEY_UP’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:211: error: ‘KEY_DOWN’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:221: error: ‘FALSE’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:222: warning: implicit declaration of function ‘scrollok’
scripts/kconfig/lxdialog/checklist.c:223: warning: implicit declaration of function ‘wscrl’
scripts/kconfig/lxdialog/checklist.c:232: warning: implicit declaration of function ‘wrefresh’
scripts/kconfig/lxdialog/checklist.c:282: warning: incompatible implicit declaration of built-in function ‘fprintf’
scripts/kconfig/lxdialog/checklist.c:283: warning: implicit declaration of function ‘delwin’
scripts/kconfig/lxdialog/checklist.c:287: error: ‘KEY_LEFT’ undeclared (first use in this function)
scripts/kconfig/lxdialog/checklist.c:288: error: ‘KEY_RIGHT’ undeclared (first use in this function)
make[2]: *** [scripts/kconfig/lxdialog/checklist.o] Error 1
make[1]: *** [menuconfig] Error 2
make: *** [menuconfig] Error 2
发表于 2006-7-16 22:26:48 | 显示全部楼层
晕,我也遇到了,就是没人知道怎么回事,大概是缺少编程工具,问题是具体是什么不知道,把安装里的编程都选上就没问题
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-7-16 22:41:53 | 显示全部楼层
Post by contentuser
晕,我也遇到了,就是没人知道怎么回事,大概是缺少编程工具,问题是具体是什么不知道,把安装里的编程都选上就没问题


啊,我看看:)
回复 支持 反对

使用道具 举报

发表于 2006-7-16 23:35:21 | 显示全部楼层
缺少这个包ncurses-devel。
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-7-17 09:58:57 | 显示全部楼层
Post by wxk
缺少这个包ncurses-devel。

我也刚找到这个包,正准备说一下。晚了一步:)

现在出现这样的错误,会是什么原因?

[root@localhost 2.6.17-1.2157_FC5-i686]# make
  CHK     include/linux/version.h
  SPLIT   include/linux/autoconf.h -> include/config/*
  HOSTCC  scripts/genksyms/genksyms.o
  HOSTCC  scripts/genksyms/lex.o
  HOSTCC  scripts/genksyms/parse.o
  HOSTLD  scripts/genksyms/genksyms
  CC      scripts/mod/empty.o
  MKELF   scripts/mod/elfconfig.h
  HOSTCC  scripts/mod/file2alias.o
  HOSTCC  scripts/mod/modpost.o
  HOSTCC  scripts/mod/sumversion.o
  HOSTLD  scripts/mod/modpost
make[1]: *** No rule to make target `init/main.o', needed by `init/built-in.o'.  Stop.
make: *** [init] Error 2
回复 支持 反对

使用道具 举报

发表于 2006-7-18 00:14:42 | 显示全部楼层
看来是configure没有正确配置好。我想你的kernel源代码有问题。
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-7-19 14:46:25 | 显示全部楼层
Post by wxk
看来是configure没有正确配置好。我想你的kernel源代码有问题。


代码是fedora5自己带的呀,应该没有问题吧?
回复 支持 反对

使用道具 举报

发表于 2006-7-19 19:19:01 | 显示全部楼层
那可未必,Fedora从来没有向谁保证过自己的源代码。最好还是再下一个最新的Kenerl源代码吧。否则,即使能找到问题的所在也不值得。
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-7-20 19:42:31 | 显示全部楼层
Post by wxk
那可未必,Fedora从来没有向谁保证过自己的源代码。最好还是再下一个最新的Kenerl源代码吧。否则,即使能找到问题的所在也不值得。


我在网上查的资料说,编译的内核源文件必须和当前使用的系统使用一个版本,是吗?我怎么感觉好象这2个关系不大啊。不然怎么升级内核呀~
回复 支持 反对

使用道具 举报

发表于 2006-7-21 01:52:50 | 显示全部楼层
好像没什么关系。
回复 支持 反对

使用道具 举报

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

本版积分规则

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