rpm 5.2.1
Data Structures | Defines | Typedefs | Functions | Variables

rpmio/cpio.h File Reference

Structures used for cpio(1) archives. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  cpioCrcPhysicalHeader_s
 Cpio archive header information. More...

Defines

#define CPIO_NEWC_MAGIC   "070701"
#define CPIO_CRC_MAGIC   "070702"
#define CPIO_TRAILER   "TRAILER!!!"
#define PHYS_HDR_SIZE   110

Typedefs

typedef struct
cpioCrcPhysicalHeader_s
cpioHeader

Functions

int cpioHeaderRead (void *_iosm, struct stat *st)
 Read cpio header.
int cpioHeaderWrite (void *_iosm, struct stat *st)
 Write cpio header.
int cpioTrailerWrite (void *_iosm)
 Write cpio trailer.

Variables

int _cpio_debug

Detailed Description

Structures used for cpio(1) archives.

Definition in file cpio.h.


Define Documentation

#define CPIO_CRC_MAGIC   "070702"

Definition at line 15 of file cpio.h.

Referenced by cpioHeaderRead().

#define CPIO_NEWC_MAGIC   "070701"

Definition at line 14 of file cpio.h.

Referenced by cpioHeaderRead(), cpioHeaderWrite(), and cpioTrailerWrite().

#define CPIO_TRAILER   "TRAILER!!!"

Definition at line 16 of file cpio.h.

Referenced by cpioTrailerWrite(), and iosmStage().

#define PHYS_HDR_SIZE   110

Definition at line 18 of file cpio.h.

Referenced by cpioHeaderRead(), cpioHeaderWrite(), and cpioTrailerWrite().


Typedef Documentation

Definition at line 11 of file cpio.h.


Function Documentation

int cpioHeaderRead ( void *  _iosm,
struct stat *  st 
)
int cpioHeaderWrite ( void *  _iosm,
struct stat *  st 
)
int cpioTrailerWrite ( void *  _iosm)

Write cpio trailer.

Return values:
_iosmfile path and stat info
Returns:
0 on success

Definition at line 278 of file cpio.c.

References _cpio_debug, _iosmNext, _IOSMRC, CPIO_NEWC_MAGIC, CPIO_TRAILER, cpioWrite(), IOSM_PAD, cpioCrcPhysicalHeader_s::magic, cpioCrcPhysicalHeader_s::namesize, cpioCrcPhysicalHeader_s::nlink, and PHYS_HDR_SIZE.

Referenced by fsmSetup(), and iosmSetup().


Variable Documentation

Definition at line 20 of file cpio.c.