谷动谷力

 找回密码
 立即注册
谷动谷力 首页 嵌入式 查看内容

【openwrt】编译OpenWRT 出错unsquashfs undefined reference to makedev解决方法 ...

2023-7-7 17:19| 发布者: sunsili| 查看: 85| 评论: 0|原作者: sunsili

摘要: 【openwrt】编译OpenWRT 15.05(Chaos Calmer CC)出错unsquashfs undefined reference to makedev解决方法 现象 出错提示: gcc unsquashfs.o unsquash-1.o unsquash-2.o unsquash-3.o unsquash-4.o swap.o compre ...
【openwrt】编译OpenWRT 15.05(Chaos Calmer CC)出错unsquashfs undefined reference to makedev解决方法

现象
出错提示:
gcc   unsquashfs.o unsquash-1.o unsquash-2.o unsquash-3.o unsquash-4.o swap.o compressor.o gzip_wrapper.o lzma_xz_wrapper.o xz_wrapper.o lzma_xz_options.o /home/fan/openwrt_CC_mt76xx_omj_source/staging_dir/host/lib/liblzma.a -lpthread -lm -lz -o unsquashfs
/usr/bin/ld: unsquashfs.o: in function create_inode': unsquashfs.c:(.text+0x24dc): undefined reference to makedev'
collect2: error: ld returned 1 exit status
make[4]: *** [Makefile:242: unsquashfs] Error 1
make[4]: Leaving directory '/home/fan/openwrt_CC_mt76xx_omj_source/build_dir/host/squashfs4.2/squashfs-tools'
make[3]: *** [Makefile:43: /home/fan/openwrt_CC_mt76xx_omj_source/build_dir/host/squashfs4.2/.built] Error 2
make[3]: Leaving directory '/home/fan/openwrt_CC_mt76xx_omj_source/tools/squashfs4'
make[2]: *** [tools/Makefile:123: tools/squashfs4/compile] Error 2
make[2]: Leaving directory '/home/fan/openwrt_CC_mt76xx_omj_source'
make[1]: *** [tools/Makefile:121: /home/fan/openwrt_CC_mt76xx_omj_source/staging_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/stamp/.tools_install_yynyynynynyyyyyyyyynyyyyyyyyynyyyyynnyyynnyynnnyy] Error 2
make[1]: Leaving directory '/home/fan/openwrt_CC_mt76xx_omj_source'
make: *** [/home/fan/openwrt_CC_mt76xx_omj_source/include/toplevel.mk:183: world] Error 2

解决方法
修改:
vim build_dir/host/squashfs4.2/squashfs-tools/unsquashfs.c
在代码头部添加
#include <sys/sysmacros.h>

重新编译此问题消除

鲜花

握手

雷人

路过

鸡蛋

相关阅读

发表评论

最新评论

最新热点

QQ|Archiver|手机版|深圳市光明谷科技有限公司|光明谷商城|Sunshine Silicon Corpporation ( 粤ICP备14060730号|Sitemap

GMT+8, 2024-9-30 23:14 , Processed in 0.107366 second(s), 35 queries .

Powered by Discuz! X3.2 Licensed

© 2001-2013 Comsenz Inc.

返回顶部