From ee2c2d8ebd40289766819ff51eb08e63785e4e3e Mon Sep 17 00:00:00 2001 From: jaby Date: Wed, 12 Oct 2022 19:35:00 +0200 Subject: [PATCH] Add PathTables to Layout --- src/Tools/psxcdgen_ex/src/main.rs | 1 + src/Tools/psxcdgen_ex/src/types/layout.rs | 2 ++ 2 files changed, 3 insertions(+) diff --git a/src/Tools/psxcdgen_ex/src/main.rs b/src/Tools/psxcdgen_ex/src/main.rs index a09807ec..61563b31 100644 --- a/src/Tools/psxcdgen_ex/src/main.rs +++ b/src/Tools/psxcdgen_ex/src/main.rs @@ -36,6 +36,7 @@ fn run_main() -> Result<(), Error> { match element { Layout::SystemArea(_) => println!("SystemArea:"), Layout::PVD(_) => println!("PVD:"), + Layout::PathTables => println!("PathTables:"), Layout::Directory{name, properties} => println!("Dir: {} @{}-{}", name, properties.lba, properties.overwrite_size_bytes.unwrap_or(0)), Layout::File(file) => println!("File: {} @{}-{}", file, file.properties.lba, file.properties.overwrite_size_bytes.unwrap_or(0)), } diff --git a/src/Tools/psxcdgen_ex/src/types/layout.rs b/src/Tools/psxcdgen_ex/src/types/layout.rs index 6e288a9c..2ceb0a8f 100644 --- a/src/Tools/psxcdgen_ex/src/types/layout.rs +++ b/src/Tools/psxcdgen_ex/src/types/layout.rs @@ -20,6 +20,7 @@ macro_rules! declare_memory_layout { layout.push([< Layout$($val:camel),* >]::SystemArea(&$($val),* parent.system_area)); layout.push([< Layout$($val:camel),* >]::PVD(&$($val),* parent.pvd)); + layout.push(([< Layout$($val:camel),* >]::PathTables)); [< add_dir_and_subdir $(_$val),* >](&mut layout, &$($val),* parent.root); layout @@ -29,6 +30,7 @@ macro_rules! declare_memory_layout { pub enum [< Layout$($val:camel),* >]<'a> { SystemArea(&'a $($val),* SystemArea), PVD(&'a $($val),* PrimaryVolumeDescriptor), + PathTables, Directory{name: &'a $($val),* DirectoryName, properties: &'a $($val),* Properties}, File(&'a $($val),* File) }