crosstool-ng无法获取linux tarball
内容导读
互联网集市收集整理的这篇技术教程文章主要介绍了crosstool-ng无法获取linux tarball,小编现在分享给大家,供广大互联网技能从业者学习和参考。文章包含4525字,纯文字阅读大概需要7分钟。
内容图文
![crosstool-ng无法获取linux tarball](/upload/InfoBanner/zyjiaocheng/965/9fa86f6c1e474037baf66efecb49ec2b.jpg)
我正在尝试使用crosstool-ng构建一个工具链,我已经完成了所有工作,按照http://crosstool-ng.org/#download_and_usage所述选择了我的cpu,我正处于可以构建工具链的阶段.但是当我输入ct-ng build时,会取消以下错误:
$ct-ng build
[INFO ] Performing some trivial sanity checks
[INFO ] Build started 20170126.135517
[INFO ] Building environment variables
[EXTRA] Preparing working directories
[EXTRA] Installing user-supplied crosstool-NG configuration
[EXTRA] =================================================================
[EXTRA] Dumping internal crosstool-NG configuration
[EXTRA] Building a toolchain for:
[EXTRA] build = x86_64-pc-linux-gnu
[EXTRA] host = x86_64-pc-linux-gnu
[EXTRA] target = powerpc-e500v2-linux-gnuspe
[EXTRA] Dumping internal crosstool-NG configuration: done in 0.09s (at 00:02)
[INFO ] =================================================================
[INFO ] Retrieving needed toolchain components' tarballs
[EXTRA] Retrieving 'linux-4.3'
[ERROR]
[ERROR] >>
[ERROR] >> Build failed in step 'Retrieving needed toolchain components' tarballs'
[ERROR] >> called in step '(top-level)'
[ERROR] >>
[ERROR] >> Error happened in: do_kernel_get[scripts/build/kernel/linux.sh@741]
[ERROR] >> called from: main[scripts/crosstool-NG.sh@590]
[ERROR] >>
[ERROR] >> For more info on this error, look at the file: 'build.log'
[ERROR] >> There is a list of known issues, some with workarounds, in:
[ERROR] >> '/usr/local/share/doc/crosstool-ng/crosstool-ng-1.22.0/B - Known issues.txt'
[ERROR]
[ERROR] (elapsed: 0:31.10)
[00:31] / make: *** [build] Error 1
在build.log中,我得到以下内容:
[EXTRA] Retrieving 'linux-4.3'
...
...
...
[DEBUG] Not at this location: "http://www.kernel.org/pub/linux/kernel/v4.x/longterm/v4.3/linux-4.3.zip"
[DEBUG] Trying 'http://www.kernel.org/pub/linux/kernel/v4.x/longterm/linux-4.3.zip'
[DEBUG] ==> Executing: 'wget' '--passive-ftp' '--tries=3' '-nc' '--...
[DEBUG] Not at this location: "http://www.kernel.org/pub/linux/kernel/v4.x/longterm/linux-4.3"
[ERROR]
[ERROR] >>
[ERROR] >> Build failed in step 'Retrieving needed toolchain components' tarballs'
[ERROR] >> called in step '(top-level)'
[ERROR] >>
[ERROR] >> Error happened in: do_kernel_get[scripts/build/kernel/linux.sh@741]
[ERROR] >> called from: main[scripts/crosstool-NG.sh@590]
[ERROR] >>
[ERROR] >> For more info on this error, look at the file: 'build.log'
[ERROR] >> There is a list of known issues, some with workarounds, in:
[ERROR] >> '/usr/local/share/doc/crosstool-ng/crosstool-ng-1.22.0/B - Known issues.txt'
[ERROR]
[ERROR] (elapsed: 0:31.10)
我知道它无法检索内核,有没有办法可以手动下载它并告诉脚本tarball所在的位置?
好的,我意识到了
wget http://www.kernel.org/pub/linux/kernel/v4.x/linux-4.3.tar.gz会失败,但是wget –no-check-certificate http://www.kernel.org/pub /linux/kernel/v4.x/linux-4.3.tar.gz可以通过代理下载tarball.
所以我将/usr/bin/wget复制到/usr/binwget~invand并写了一个包装器/usr/bin/wget`,看起来像:
#!/bin/bash
/usr/bin/wget~orig --no-check-certificate $1
但这似乎也不起作用,我现在在build.log中获得以下内容:
[DEBUG] ==> Executing: 'wget' '--passive-ftp' '--tries=3' '-nc' '--progress=dot:binary' '-T' '10' '-O' '/home/ron/src/toolchain/work/.build/tarballs/linux-4.3.tar.xz.tmp-dl' 'http://www.kernel.org/pub/linux/kernel/v4.x/linux-4.3.tar.xz'
[ALL ] wget~orig: missing URL
[ALL ] Usage: wget~orig [OPTION]... [URL]...
[ALL ]
[ALL ] Try `wget~orig --help' for more options.
[DEBUG] Not at this location: "http://www.kernel.org/pub/linux/kernel/v4.x/linux-4.3.tar.xz"
[DEBUG] Trying 'http://www.kernel.org/pub/linux/kernel/v4.x/longterm/v4.3/linux-4.3.tar.xz'
[DEBUG] ==> Executing: 'wget' '--passive-ftp' '--tries=3' '-nc' '--progress=dot:binary' '-T' '10' '-O' '/home/ron/src/toolchain/work/.build/tarballs/linux-4.3.tar.xz.tmp-dl' 'http://www.kernel.org/pub/linux/kernel/v4.x/longterm/v4.3/linux-4.3.tar.xz'
[ALL ] wget~orig: missing URL
[ALL ] Usage: wget~orig [OPTION]... [URL]...
它是如何自动地知道我的原始wget二进制文件现在被称为wget~inor ??? Andit尝试使用它而不是我现在位于/usr/bin/wget的包装器(是的,我已经添加了x权限并尝试了它,一个wget http://www.kernel.org/pub/linux/来自shell的kernel / v4.x / linux-4.3.tar.gz(利用我的包装脚本)现在工作得很好……
解决方法:
好的,
由于使用muliple(9)参数调用wget,我修复了我的包装器脚本(在/usr/bin/wget),如下所示:
#!/bin/bash
/usr/bin/wget~orig --no-check-certificate $1 $2 $3 $4 $5 $6 $7 $8 $9
这似乎成功地下载了ct-ng所需的源代码压缩包
内容总结
以上是互联网集市为您收集整理的crosstool-ng无法获取linux tarball全部内容,希望文章能够帮你解决crosstool-ng无法获取linux tarball所遇到的程序开发问题。 如果觉得互联网集市技术教程内容还不错,欢迎将互联网集市网站推荐给程序员好友。
内容备注
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 gblab@vip.qq.com 举报,一经查实,本站将立刻删除。
内容手机端
扫描二维码推送至手机访问。