Skip to content

Commit ee9c17c

Browse files
committed
[WIP] Use correct segment for metadata section
1 parent 41a7c9b commit ee9c17c

File tree

4 files changed

+9
-6
lines changed

4 files changed

+9
-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: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,8 @@ object = "0.11.0"
3939
#[patch."https://github.com/gimli-rs/gimli.git"]
4040
#gimli = { path = "../" }
4141

42+
[patch.crates-io]
43+
faerie = { git = "https://github.com/m4b/faerie.git" }
44+
4245
[profile.dev.overrides."*"]
4346
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)