Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
int
Rust
提交
e7342b8f
R
Rust
项目概览
int
/
Rust
12 个月 前同步成功
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
Rust
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
e7342b8f
编写于
3月 09, 2018
作者:
M
Mark Simulacrum
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Permit constructing Build without executing
上级
a5e56b62
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
21 addition
and
19 deletion
+21
-19
src/bootstrap/lib.rs
src/bootstrap/lib.rs
+21
-19
未找到文件。
src/bootstrap/lib.rs
浏览文件 @
e7342b8f
...
...
@@ -326,7 +326,7 @@ pub fn new(config: Config) -> Build {
let
rls_info
=
channel
::
GitInfo
::
new
(
&
config
,
&
src
.join
(
"src/tools/rls"
));
let
rustfmt_info
=
channel
::
GitInfo
::
new
(
&
config
,
&
src
.join
(
"src/tools/rustfmt"
));
Build
{
let
mut
build
=
Build
{
initial_rustc
:
config
.initial_rustc
.clone
(),
initial_cargo
:
config
.initial_cargo
.clone
(),
local_rebuild
:
config
.local_rebuild
,
...
...
@@ -357,7 +357,27 @@ pub fn new(config: Config) -> Build {
delayed_failures
:
RefCell
::
new
(
Vec
::
new
()),
prerelease_version
:
Cell
::
new
(
None
),
tool_artifacts
:
Default
::
default
(),
};
build
.verbose
(
"finding compilers"
);
cc_detect
::
find
(
&
mut
build
);
build
.verbose
(
"running sanity check"
);
sanity
::
check
(
&
mut
build
);
// If local-rust is the same major.minor as the current version, then force a local-rebuild
let
local_version_verbose
=
output
(
Command
::
new
(
&
build
.initial_rustc
)
.arg
(
"--version"
)
.arg
(
"--verbose"
));
let
local_release
=
local_version_verbose
.lines
()
.filter
(|
x
|
x
.starts_with
(
"release:"
))
.next
()
.unwrap
()
.trim_left_matches
(
"release:"
)
.trim
();
let
my_version
=
channel
::
CFG_RELEASE_NUM
;
if
local_release
.split
(
'.'
)
.take
(
2
)
.eq
(
my_version
.split
(
'.'
)
.take
(
2
))
{
build
.verbose
(
&
format!
(
"auto-detected local-rebuild {}"
,
local_release
));
build
.local_rebuild
=
true
;
}
build
.verbose
(
"learning about cargo"
);
metadata
::
build
(
&
mut
build
);
build
}
pub
fn
build_triple
(
&
self
)
->
&
[
Interned
<
String
>
]
{
...
...
@@ -376,24 +396,6 @@ pub fn build(&mut self) {
return
clean
::
clean
(
self
,
all
);
}
self
.verbose
(
"finding compilers"
);
cc_detect
::
find
(
self
);
self
.verbose
(
"running sanity check"
);
sanity
::
check
(
self
);
// If local-rust is the same major.minor as the current version, then force a local-rebuild
let
local_version_verbose
=
output
(
Command
::
new
(
&
self
.initial_rustc
)
.arg
(
"--version"
)
.arg
(
"--verbose"
));
let
local_release
=
local_version_verbose
.lines
()
.filter
(|
x
|
x
.starts_with
(
"release:"
))
.next
()
.unwrap
()
.trim_left_matches
(
"release:"
)
.trim
();
let
my_version
=
channel
::
CFG_RELEASE_NUM
;
if
local_release
.split
(
'.'
)
.take
(
2
)
.eq
(
my_version
.split
(
'.'
)
.take
(
2
))
{
self
.verbose
(
&
format!
(
"auto-detected local-rebuild {}"
,
local_release
));
self
.local_rebuild
=
true
;
}
self
.verbose
(
"learning about cargo"
);
metadata
::
build
(
self
);
let
builder
=
builder
::
Builder
::
new
(
&
self
);
if
let
Some
(
path
)
=
builder
.paths
.get
(
0
)
{
if
path
==
Path
::
new
(
"nonexistent/path/to/trigger/cargo/metadata"
)
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录