drpm
A library for making, reading and applying deltarpm packages
|
Go to the source code of this file.
Macros | |
Errors / Return values | |
#define | DRPM_ERR_OK 0 |
no error | |
#define | DRPM_ERR_MEMORY 1 |
memory allocation error | |
#define | DRPM_ERR_ARGS 2 |
bad arguments | |
#define | DRPM_ERR_IO 3 |
I/O error. | |
#define | DRPM_ERR_FORMAT 4 |
wrong file format | |
#define | DRPM_ERR_CONFIG 5 |
misconfigured external library | |
#define | DRPM_ERR_OTHER 6 |
unspecified/unknown error | |
#define | DRPM_ERR_OVERFLOW 7 |
file too large | |
#define | DRPM_ERR_PROG 8 |
internal programming error | |
#define | DRPM_ERR_MISMATCH 9 |
file changed | |
#define | DRPM_ERR_NOINSTALL 10 |
old RPM not installed | |
Delta Types | |
#define | DRPM_TYPE_STANDARD 0 |
standard deltarpm | |
#define | DRPM_TYPE_RPMONLY 1 |
rpm-only deltarpm | |
Compression Types | |
#define | DRPM_COMP_NONE 0 |
no compression | |
#define | DRPM_COMP_GZIP 1 |
gzip | |
#define | DRPM_COMP_BZIP2 2 |
bzip2 | |
#define | DRPM_COMP_LZMA 3 |
lzma | |
#define | DRPM_COMP_XZ 4 |
xz | |
#define | DRPM_COMP_LZIP 5 |
lzip | |
Info Tags | |
#define | DRPM_TAG_FILENAME 0 |
file name | |
#define | DRPM_TAG_VERSION 1 |
version | |
#define | DRPM_TAG_TYPE 2 |
delta type | |
#define | DRPM_TAG_COMP 3 |
compression type | |
#define | DRPM_TAG_SEQUENCE 4 |
sequence | |
#define | DRPM_TAG_SRCNEVR 5 |
source NEVR (name-epoch:version-release) | |
#define | DRPM_TAG_TGTNEVR 6 |
target NEVR (name-epoch:version-release) | |
#define | DRPM_TAG_TGTSIZE 7 |
target size | |
#define | DRPM_TAG_TGTMD5 8 |
target MD5 | |
#define | DRPM_TAG_TGTCOMP 9 |
target compression type | |
#define | DRPM_TAG_TGTCOMPPARAM 10 |
target compression parameter block | |
#define | DRPM_TAG_TGTHEADERLEN 11 |
target header length | |
#define | DRPM_TAG_ADJELEMS 12 |
offset adjustment elements | |
#define | DRPM_TAG_TGTLEAD 13 |
lead/signatures of the new rpm | |
#define | DRPM_TAG_PAYLOADFMTOFF 14 |
payload format offset | |
#define | DRPM_TAG_INTCOPIES 15 |
copies from internal data (number of external copies to do before internal copy & length of internal copy) | |
#define | DRPM_TAG_EXTCOPIES 16 |
copies from external data (offset adjustment of external copy & length of external copy) | |
#define | DRPM_TAG_EXTDATALEN 17 |
length of external data | |
#define | DRPM_TAG_INTDATALEN 18 |
length of internal data | |
Compression Levels | |
#define | DRPM_COMP_LEVEL_DEFAULT 0 |
default compression level for given compression type | |
Check Modes | |
#define | DRPM_CHECK_NONE 0 |
no file checking | |
#define | DRPM_CHECK_FULL 1 |
full (i.e. slow) on-disk checking | |
#define | DRPM_CHECK_FILESIZES 2 |
only checking if filesizes have changed | |
Typedefs | |
typedef struct drpm | drpm |
DeltaRPM package info. | |
typedef struct drpm_make_options | drpm_make_options |
Options for drpm_make() | |
Functions | |
int | drpm_apply (const char *oldrpm, const char *deltarpm, const char *newrpm) |
Applies a DeltaRPM to an old RPM or on-disk data to re-create a new RPM. More... | |
int | drpm_check (const char *deltarpm, int checkmode) |
Checks if the reconstruction is possible based on DeltaRPM file. More... | |
int | drpm_check_sequence (const char *oldrpm, const char *sequence, int checkmode) |
Checks if the reconstruction is possible based on sequence ID. More... | |
int | drpm_destroy (drpm **delta) |
Frees memory allocated by drpm_read(). More... | |
int | drpm_get_string (drpm *delta, int tag, char **target) |
Fetches information representable as a string. More... | |
int | drpm_get_uint (drpm *delta, int tag, unsigned *target) |
Fetches information representable as an unsigned integer. More... | |
int | drpm_get_ullong (drpm *delta, int tag, unsigned long long *target) |
Fetches information representable as an unsigned long long integer. More... | |
int | drpm_get_ulong (drpm *delta, int tag, unsigned long *target) |
Fetches information representable as an unsigned long integer. More... | |
int | drpm_get_ulong_array (drpm *delta, int tag, unsigned long **target, unsigned long *size) |
Fetches information representable as an array of unsigned long integers. More... | |
int | drpm_make (const char *oldrpm, const char *newrpm, const char *deltarpm, const drpm_make_options *opts) |
Creates a DeltaRPM from two RPMs. More... | |
int | drpm_make_options_add_patches (drpm_make_options *opts, const char *oldrpmprint, const char *oldpatchrpm) |
Requests incorporation of RPM patch files for the old RPM. More... | |
int | drpm_make_options_copy (drpm_make_options *dst, const drpm_make_options *src) |
Copies drpm_make_options. More... | |
int | drpm_make_options_defaults (drpm_make_options *opts) |
Resets options to default values. More... | |
int | drpm_make_options_destroy (drpm_make_options **opts) |
Frees drpm_make_options. More... | |
int | drpm_make_options_forbid_addblk (drpm_make_options *opts) |
Forbids add block creation. More... | |
int | drpm_make_options_get_delta_comp_from_rpm (drpm_make_options *opts) |
DeltaRPM compression method is the same as used in the new RPM. More... | |
int | drpm_make_options_init (drpm_make_options **opts) |
Initializes drpm_make_options with default options. More... | |
int | drpm_make_options_set_addblk_comp (drpm_make_options *opts, unsigned short comp, unsigned short level) |
Sets add block compression type and level. More... | |
int | drpm_make_options_set_delta_comp (drpm_make_options *opts, unsigned short comp, unsigned short level) |
Sets DeltaRPM compression type and level. More... | |
int | drpm_make_options_set_seqfile (drpm_make_options *opts, const char *seqfile) |
Specifies file to which to write DeltaRPM sequence ID. More... | |
int | drpm_make_options_set_type (drpm_make_options *opts, unsigned short type) |
Sets DeltaRPM type. More... | |
int | drpm_make_options_set_version (drpm_make_options *opts, unsigned short version) |
Sets DeltaRPM version. More... | |
int | drpm_read (drpm **delta, const char *filename) |
Reads information from a DeltaRPM. More... | |
const char * | drpm_strerror (int error) |
Returns description of error code as a string. More... | |
const char* drpm_strerror | ( | int | error | ) |
Returns description of error code as a string.
Works very similarly to strerror(3).
[in] | error | error code |