Skip to content

Commit 19a3986

Browse files
committed
[WIP] Use correct segment for metadata section
1 parent 2da64aa commit 19a3986

File tree

4 files changed

+7
-6
lines changed

4 files changed

+7
-6
lines changed

Cargo.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ object = "0.11.0"
4141

4242
[patch.crates-io]
4343
ar = { git = "https://github.com/bjorn3/rust-ar.git", branch = "non_multiple_of_two_identifiers_gnu_format" }
44+
faerie = { git = "https://github.com/m4b/faerie.git" }
4445

4546
[profile.dev.overrides."*"]
4647
opt-level = 3

src/debuginfo.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ impl<'a, 'tcx: 'a> DebugContext<'tcx> {
191191
let _: Result<()> = sections.for_each_mut(|id, section| {
192192
if !section.writer.slice().is_empty() {
193193
artifact
194-
.declare_with(id.name(), Decl::debug_section(), section.writer.take())
194+
.declare_with(id.name(), Decl::section(SectionKind::Debug), section.writer.take())
195195
.unwrap();
196196
}
197197
Ok(())

src/metadata.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ pub fn write_metadata<'a, 'gcx>(
9090
DeflateEncoder::new(&mut compressed, Compression::fast())
9191
.write_all(&metadata.raw_data).unwrap();
9292

93-
artifact.declare_with(".rustc", faerie::Decl::debug_section(), compressed).unwrap();
93+
artifact.declare_with(".rustc", faerie::Decl::section(faerie::SectionKind::Data), compressed).unwrap();
9494

9595
metadata
9696
}

0 commit comments

Comments
 (0)