1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
//! # fitimage - FIT Image Library
//!
//! A Rust library for creating U-Boot compatible FIT (Flattened Image Tree) images.
//!
//! ## Features
//!
//! - Complete FIT image creation functionality
//! - Support for kernel, FDT (device tree), and ramdisk components
//! - Gzip compression support
//! - Multiple hash algorithms (MD5, SHA1, CRC32)
//! - U-Boot compatible device tree structure
//!
//! ## Quick Start
//!
//! ```rust,no_run
//! use fitimage::{FitImageBuilder, FitImageConfig, ComponentConfig};
//!
//! // Create FIT image configuration
//! let config = FitImageConfig::new("My FIT Image")
//! .with_kernel(
//! ComponentConfig::new("kernel", vec![/* kernel data */])
//! .with_load_address(0x80080000)
//! .with_entry_point(0x80080000)
//! )
//! .with_fdt(
//! ComponentConfig::new("fdt", vec![/* fdt data */])
//! .with_load_address(0x82000000)
//! );
//!
//! // Build FIT image
//! let mut builder = FitImageBuilder::new();
//! let fit_data = builder.build(config).unwrap();
//! ```
//!
//! ## Modules
//!
//! - [`fit`] - Core FIT image building functionality
//! - [`compression`] - Compression algorithms (gzip)
//! - [`hash`] - Hash calculation utilities (MD5, SHA1, CRC32)
//! - [`crc`] - CRC32 checksum calculation
//! - [`error`] - Error types and result definitions
/// Compression algorithms support (gzip, etc.)
/// CRC32 checksum calculation utilities.
/// Error types and result definitions for FIT image operations.
/// Core FIT image building functionality.
/// Hash calculation utilities (MD5, SHA1, CRC32).
// Re-export main types for convenience
pub use CompressionInterface;
pub use calculate_crc32;
pub use ;
pub use ;
pub use ;
/// Current version of the fitimage implementation
pub const VERSION: &str = env!;
/// FIT image magic number
pub const FIT_MAGIC: & = b"FIT";