RTEMS  5.0.0
Data Structures | Macros | Functions
untar.h File Reference

Untar an Image. More...

#include <stdbool.h>
#include <stddef.h>
#include <tar.h>
#include <zlib.h>
#include <xz.h>
#include <rtems/print.h>

Go to the source code of this file.

Data Structures

struct  Untar_ChunkContext
 
struct  Untar_GzChunkContext
 
struct  Untar_XzChunkContext
 

Macros

#define UNTAR_SUCCESSFUL   0
 
#define UNTAR_FAIL   1
 
#define UNTAR_INVALID_CHECKSUM   2
 
#define UNTAR_INVALID_HEADER   3
 
#define UNTAR_GZ_INFLATE_FAILED   4
 
#define UNTAR_GZ_INFLATE_END_FAILED   5
 

Functions

int Untar_FromMemory (void *tar_buf, size_t size)
 
int Untar_FromMemory_Print (void *tar_buf, size_t size, const rtems_printer *printer)
 
int Untar_FromFile (const char *tar_name)
 
int Untar_FromFile_Print (const char *tar_name, const rtems_printer *printer)
 
void Untar_ChunkContext_Init (Untar_ChunkContext *context)
 Initializes the Untar_ChunkContext files out of a part of a block of memory. More...
 
int Untar_FromChunk_Print (Untar_ChunkContext *context, void *chunk, size_t chunk_size, const rtems_printer *printer)
 
int Untar_GzChunkContext_Init (Untar_GzChunkContext *ctx, void *inflateBuffer, size_t inflateBufferSize)
 Initializes the Untar_ChunkGzContext. More...
 
int Untar_FromGzChunk_Print (Untar_GzChunkContext *ctx, void *chunk, size_t chunk_size, const rtems_printer *printer)
 
int Untar_XzChunkContext_Init (Untar_XzChunkContext *ctx, enum xz_mode mode, uint32_t dict_max, void *inflateBuffer, size_t inflateBufferSize)
 Initializes the Untar_ChunkXzContext. More...
 
int Untar_FromXzChunk_Print (Untar_XzChunkContext *ctx, const void *chunk, size_t chunk_size, const rtems_printer *printer)
 
unsigned long _rtems_octal2ulong (const char *octascii, size_t len)
 
int _rtems_tar_header_checksum (const char *bufr)
 

Detailed Description

Untar an Image.

This file defines the interface to methods which can untar an image.