找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
广告投放联系QQ68610888
查看: 5853|回复: 22

本机win10子系统Ubuntu18.04编译lede出错,求帮助

[复制链接]
发表于 2020-4-26 14:07 | 显示全部楼层 |阅读模式
在本机win10自带的Ubuntu18.04lts上编译lede,提示出错如下。
该Ubuntu是全新下载的,没有安装其它东西。
出错提示代码如下,请各位大神帮助看看,是什么问题,多谢指点!!

Enabling zerotier
sed -i "s/Installed-Time: .*/Installed-Time: 1587784102/" /home/zmcom/lede/build_dir/target-x86_64_musl/root-x86/usr/lib/opkg/status
rm -rf /home/zmcom/lede/build_dir/target-x86_64_musl/root-x86/tmp/*
rm -f /home/zmcom/lede/build_dir/target-x86_64_musl/root-x86/usr/lib/opkg/lists/*
rm -f /home/zmcom/lede/build_dir/target-x86_64_musl/root-x86/usr/lib/opkg/info/*.postinst*
rm -f /home/zmcom/lede/build_dir/target-x86_64_musl/root-x86/var/lock/*.lock
rm -rf /home/zmcom/lede/build_dir/target-x86_64_musl/root-x86/boot
find /home/zmcom/lede/build_dir/target-x86_64_musl/root-x86/ -mindepth 1 -execdir touch -hcd "@1587784102" "{}" +
find: The relative path 'Files/WindowsApps/CanonicalGroupLimited.Ubuntu18.04onWindows_1804.2020.423.0_x64__79rhkp1fndgsc' is included in the PATH environment variable, which is insecure in combination with the -execdir action of find.  Please remove that entry from $PATH
package/Makefile:65: recipe for target 'package/install' failed
make[2]: *** [package/install] Error 1
make[2]: Leaving directory '/home/zmcom/lede'
package/Makefile:108: recipe for target '/home/zmcom/lede/staging_dir/target-x86_64_musl/stamp/.package_install' failed
make[1]: *** [/home/zmcom/lede/staging_dir/target-x86_64_musl/stamp/.package_install] Error 2
make[1]: Leaving directory '/home/zmcom/lede'
Build failed - please re-run with -j1 to see the real error message
/home/zmcom/lede/include/toplevel.mk:225: recipe for target 'world' failed
make: *** [world] Error 1

我的恩山、我的无线 The best wifi forum is right here.
 楼主| 发表于 2020-4-26 14:08 | 显示全部楼层
编译的方法和过程如下:


1、sudo apt-get update
2、sudo apt-get -y install build-essential asciidoc binutils bzip2 gawk gettext git libncurses5-dev libz-dev patch python3.5 unzip zlib1g-dev lib32gcc1 libc6-dev-i386 subversion flex uglifyjs git-core gcc-multilib p7zip p7zip-full msmtp libssl-dev texinfo libglib2.0-dev xmlto qemu-utils upx libelf-dev autoconf automake libtool autopoint device-tree-compiler g++-multilib antlr3 gperf
3、git clone https://github.com/coolsnowwolf/lede
4、 cd lede //进入目录
5、./scripts/feeds update -a
6、./scripts/feeds install -a
7、make menuconfig //默认配置即可不需要改动
8、make -j8 download V=s
9、make -j1 V=s #编译
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

发表于 2020-4-26 14:47 | 显示全部楼层
架手工竹梯子才可以,推荐你用gitpod编译,速度快。下载源码非常快

点评

手工竹梯子都架好了,下载lede和download都非常快,但是编译总是出问题。。。  详情 回复 发表于 2020-4-26 16:23
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

 楼主| 发表于 2020-4-26 16:23 | 显示全部楼层
240038901 发表于 2020-4-26 14:47
架手工竹梯子才可以,推荐你用gitpod编译,速度快。下载源码非常快

手工竹梯子都架好了,下载lede和download都非常快,但是编译总是出问题。。。
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

 楼主| 发表于 2020-4-26 18:40 | 显示全部楼层
求大神路过指点一下下
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

发表于 2020-4-26 21:23 | 显示全部楼层
编译前先执行 source /etc/environment 来去掉wsl里从主机那获得的环境变量然后再编译试下?
这是我遇到过的情况,仅供参考,如果还不行我也不知道怎么解决了

点评

这个方法管用  详情 回复 发表于 2020-7-24 16:14
请教这步如何操作。谢谢  详情 回复 发表于 2020-7-21 21:51
再次感谢 silverx ,注册V用户,hcyme 的热心帮助  详情 回复 发表于 2020-4-27 07:08
这个解决方法是正解,解决问题了 早上起来趁着网络好,又跑了一遍编译,这次只用了几分钟就完成编译了。 然后继续进行二次编译,也成功了,下面是方法。 第1次编译成功,然后进行2次编译 1、git p  详情 回复 发表于 2020-4-27 07:06
谢谢,我去试试  详情 回复 发表于 2020-4-26 22:41
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

发表于 2020-4-26 21:47 | 显示全部楼层
猜测,是不是因为升级了的原因?运行过apt-get upgrade?

点评

运行了,也不行  详情 回复 发表于 2020-4-26 22:41
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

 楼主| 发表于 2020-4-26 22:41 | 显示全部楼层
sliverx 发表于 2020-4-26 21:23
编译前先执行 source /etc/environment 来去掉wsl里从主机那获得的环境变量然后再编译试下?
这是我遇到过 ...

谢谢,我去试试
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

 楼主| 发表于 2020-4-26 22:41 | 显示全部楼层
注册v用户 发表于 2020-4-26 21:47
猜测,是不是因为升级了的原因?运行过apt-get upgrade?

运行了,也不行

点评

我的意思是不要apt-get upgrade,在油管上看到有人说桌面版容易出一些莫名其妙的错误,建议安装服务器版,我现在正在安装 没有手工竹梯子,安装贼慢  详情 回复 发表于 2020-4-27 00:35
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

发表于 2020-4-27 00:35 | 显示全部楼层
zmweb 发表于 2020-4-26 22:41
运行了,也不行

我的意思是不要apt-get upgrade,在油管上看到有人说桌面版容易出一些莫名其妙的错误,建议安装服务器版,我现在正在安装

没有手工竹梯子,安装贼慢
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

发表于 2020-4-27 00:44 来自手机 | 显示全部楼层
虚拟机和子系统没用过,实体机没什么问题,1804和2004都正常,出错就看最后两句代码吧问东问西的瞎耽误事儿
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

 楼主| 发表于 2020-4-27 07:06 | 显示全部楼层
sliverx 发表于 2020-4-26 21:23
编译前先执行 source /etc/environment 来去掉wsl里从主机那获得的环境变量然后再编译试下?
这是我遇到过 ...

这个解决方法是正解,解决问题了
早上起来趁着网络好,又跑了一遍编译,这次只用了几分钟就完成编译了。

然后继续进行二次编译,也成功了,下面是方法。

第1次编译成功,然后进行2次编译
1、git pull
2、修改feeds.conf.default里helloworld的注释去掉#号
3、./scripts/feeds update -a && ./scripts/feeds install -a
4、make defconfig
5、rm -rf ./tmp && rm -rf .config
6、make menuconfig //选择你需要的配置(此时有你想要的东东)
7、修改network => projectv => v贰瑞 Con => 勾选第一个选项 //这个我是照着来的,不清楚具体意思
8、make -j8 download V=s //建议用-j1,下载稳定些,如果有些文件貌似没有成功,可以再运行一遍下载,确保都下载了
9、make -j$(($(nproc) + 1)) V=s
//第2次编译成功
//因为用的是wsl,文件在 C:\Users\用户名\AppData\Local\Packages\CanonicalGroupLimited.Ubuntu18.04onWindows_79rhkp1fndgsc\LocalState\rootfs\home\用户名\lede\bin\targets\x86\64,把其中“用户名”改成自己的用户名称,比如bill

点评

请教: 我也遇到同样的问题,你说“把其中“用户名”改成自己的用户名称” 请问是在那个地方改,谢谢  详情 回复 发表于 2020-7-21 14:57
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

 楼主| 发表于 2020-4-27 07:08 | 显示全部楼层
sliverx 发表于 2020-4-26 21:23
编译前先执行 source /etc/environment 来去掉wsl里从主机那获得的环境变量然后再编译试下?
这是我遇到过 ...

再次感谢 silverx ,注册V用户,hcyme 的热心帮助
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

 楼主| 发表于 2020-4-27 20:40 | 显示全部楼层
利用这个办法, 在vm下虚拟机Ubuntu18.04也成功了。
总结下来,-ji是重点,可以帮助分析失败的原因。
这个方法没有问题。编译中容易出现问题的地方是网络原因导致下载失败,从而编译出错。
推荐在早上6-8点之间进行编译,这时候网络情况比较快,很少发生下载失败的问题。
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

发表于 2020-7-21 14:57 | 显示全部楼层
zmweb 发表于 2020-4-27 07:06
这个解决方法是正解,解决问题了
早上起来趁着网络好,又跑了一遍编译,这次只用了几分钟就完 ...

请教:
我也遇到同样的问题,你说“把其中“用户名”改成自己的用户名称” 请问是在那个地方改,谢谢
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

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

本版积分规则

有疑问请添加管理员QQ86788181|手机版|小黑屋|Archiver|恩山无线论坛(常州市恩山计算机开发有限公司版权所有) ( 苏ICP备05084872号 )

GMT+8, 2024-4-26 19:17

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

| 江苏省互联网有害信息举报中心 举报信箱:js12377 | @jischina.com.cn 举报电话:025-88802724 本站不良内容举报信箱:68610888@qq.com 举报电话:0519-86695797

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