由于Openwrt有很多工具是要先编译的,在Ubuntu12.10平台下编译openwrt时就遇到了下面这样的错误:
elf.cpp: In static member function 'static Elf::file* Elf::file::open(const char*)':
elf.cpp:68:5: error: '::close' has not been declared
后经google,发现很多网友也遇到这样的问题,因此借鉴了他们的方法。

1、找到elf.cpp源文件(./build_dir/host/mklibs/src/mklibs-readelf/elf.cpp),打开.
2、在包含的头文件最后添加一行#include <unistd.h>
3、保存,重新编译,问题解决。

相关文章:

  • 2022-12-23
  • 2021-11-16
  • 2021-05-06
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-09
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-08-04
  • 2021-07-12
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案