Chinaunix首页 | 论坛 | 博客
  • 博客访问: 185793
  • 博文数量: 9
  • 博客积分: 1722
  • 博客等级: 上尉
  • 技术积分: 225
  • 用 户 组: 普通用户
  • 注册时间: 2006-05-09 11:13
文章分类
文章存档

2012年(1)

2011年(5)

2010年(3)

分类: LINUX

2011-01-21 10:29:34

最近在编译dovecot时,遇到了一个头疼的问题,configure时出错,以前没遇到过,查了资料,写的也不尽详细,一直没找到好的办法,直到从一个外文网站上看到这么一个出错信息后,试了一下,生效!
 
在此把修正过程发于此处,供遇到此问题的朋友参考!
错误1:
  1. configure: error: cannot run C compiled programs.

  2. If you meant to cross compile, use `--host'.

  3. See `config.log' for more details.
解决1:
用./config.guess查出操作平台
  1. #./config.guess
  2. i686-pc-linux-gnu
在configure 后加入 --host=i686-pc-linux-gnu(./config.guess所得结果)
 
错误2:
  1. checking whether we can use epoll... configure: error: in `/root/dovecot-2.0.8':
  2. configure: error: cannot run test program while cross compiling
  3. See `config.log' for more details
解决2:
在configure 前加 i_cv_epoll_works=yes 解决
注,因为用--cache-file=i686-pc-linux-gnu.cache方式不好使,所以把上述字段加到configure前边
 
错误3:
  1. checking whether we can use epoll... (cached) yes
  2. checking whether we can use inotify... configure: error: in `/root/dovecot-2.0.8':
  3. configure: error: cannot run test program while cross compiling
  4. See `config.log' for more details

这些问题一个劲出,没办法,索性把网上查的资料全搬出来,加到configure前边,configure通地

 

  1. i_cv_epoll_works=yes
  2. i_cv_inotify_works=yes
  3. i_cv_posix_fallocate_works=yes
  4. i_cv_signed_size_t=no
  5. i_cv_gmtime_max_time_t=32
  6. i_cv_signed_time_t=yes
  7. i_cv_mmap_plays_with_write=yes
  8. i_cv_fd_passing=yes
  9. i_cv_c99_vsnprintf=yes
  10. lib_cv_va_copy=yes
  11. lib_cv___va_copy=yes
  12. lib_cv_va_val_copy=yes

上述选顶可根据需要进行设置!

make

make install

通过!

阅读(9905) | 评论(0) | 转发(0) |
0

上一篇:没有了

下一篇:试读《C++程序设计原理与实践》有感(上)

给主人留下些什么吧!~~