openwrt lede编译使用Windows sever2019 wsl子系统 失败/出错/遇到的坑


还是比较习惯使用Windows,
最近在使用windows sever2019的Ubuntu18.4编译openwrt,
其中lienol大源码编译,基于openwrt19.7的,基本一遍就能成功
但是lean大源码,出错的几率很大,下面记录了遇到的坑

除了要全局留学上网,下载好文件make download -j8 V=s,还有以下的可能会出错

1、要开启文件系统大小写文件名
fsutil.exe file setCaseSensitiveInfo D:openwrt enable

2、Linux系统与Windows文件系统权限管理不一样,WSL安装目录也可能会有影响,
可以使用 LxRunOffline 对 WSL 目录进行转移
mv: cannot move 'bin/aclocal.tmp2' to 'bin/aclocal.tmp': Permission denied
Makefile:51: recipe for target '/mnt/e/Downloads/OpenWrt/lede/build_dir/host/automake-1.15.1/.configured' failed
make[3]: * [/mnt/e/Downloads/OpenWrt/lede/build_dir/host/automake-1.15.1/.configured] Error 1
make[3]: Leaving directory '/mnt/e/Downloads/OpenWrt/lede/tools/automake'
time: tools/automake/compile#0.20#1.85#2.00
tools/Makefile:155: recipe for target 'tools/automake/compile' failed
make[2]: * [tools/automake/compile] Error 2
make[2]: Leaving directory '/mnt/e/Downloads/OpenWrt/lede'
tools/Makefile:153: recipe for target '/mnt/e/Downloads/OpenWrt/lede/staging_dir/target-x86_64_musl/stamp/.tools_c
ompile_yynyyyyynyyyyynyyynnyyyynyyyyyyyyyyyyyyyyyyynynnyyynnyy' failed
make[1]: * [/mnt/e/Downloads/OpenWrt/lede/staging_dir/target-x86_64_musl/stamp/.tools_compile_yynyyyyynyyyyynyyy
nnyyyynyyyyyyyyyyyyyyyyyyynynnyyynnyy] Error 2

3、D:WSLrootfsetc,wsl.conf文件,定义变量问题
[automount]
options = "metadata,umask=22,fmask=111"

[filesystem]
umask = 022

[interop]
enabled = "false"
appendWindowsPath = "false"

4、居然Windows变量里面的haozip也有影响,要删掉
The relative path 'Files/2345Soft/HaoZip' is included in the PATH

终于,成功了

声明:It小小鸟 itxiaoniao.cn|版权所有,违者必究|如未注明,均为原创|本网站采用BY-NC-SA协议进行授权

转载:转载请注明原文链接 - openwrt lede编译使用Windows sever2019 wsl子系统 失败/出错/遇到的坑


Carpe Diem and Do what I like.