rpm: /home/mdomonko/code/rpm/rpm-4.20.x/include/rpm/rpmarchive.h Source File

rpm 4.20.0 The RPM Package Manager

Loading...
Searching...
No Matches
rpmarchive.h
Go to the documentation of this file.
1#ifndef H_ARCHIVE
2#define H_ARCHIVE
3
9#define RPMERR_CHECK_ERRNO -32768
10
14 enum rpmfilesErrorCodes {
15 RPMERR_ITER_END = -1,
16 RPMERR_BAD_MAGIC = -2,
17 RPMERR_BAD_HEADER = -3,
18 RPMERR_HDR_SIZE = -4,
19 RPMERR_UNKNOWN_FILETYPE= -5,
20 RPMERR_MISSING_FILE = -6,
21 RPMERR_DIGEST_MISMATCH = -7,
22 RPMERR_INTERNAL = -8,
23 RPMERR_UNMAPPED_FILE = -9,
24 RPMERR_ENOENT = -10,
25 RPMERR_ENOTEMPTY = -11,
26 RPMERR_FILE_SIZE = -12,
27 RPMERR_ITER_SKIP = -13,
28 RPMERR_EXIST_AS_DIR = -14,
29 RPMERR_INVALID_SYMLINK = -15,
30 RPMERR_ENOTDIR = -16,
31
32 RPMERR_OPEN_FAILED = -32768,
33 RPMERR_CHMOD_FAILED = -32769,
34 RPMERR_CHOWN_FAILED = -32770,
35 RPMERR_WRITE_FAILED = -32771,
36 RPMERR_UTIME_FAILED = -32772,
37 RPMERR_UNLINK_FAILED = -32773,
38 RPMERR_RENAME_FAILED = -32774,
39 RPMERR_SYMLINK_FAILED = -32775,
40 RPMERR_STAT_FAILED = -32776,
41 RPMERR_LSTAT_FAILED = -32777,
42 RPMERR_MKDIR_FAILED = -32778,
43 RPMERR_RMDIR_FAILED = -32779,
44 RPMERR_MKNOD_FAILED = -32780,
45 RPMERR_MKFIFO_FAILED = -32781,
46 RPMERR_LINK_FAILED = -32782,
47 RPMERR_READLINK_FAILED = -32783,
48 RPMERR_READ_FAILED = -32784,
49 RPMERR_COPY_FAILED = -32785,
50 RPMERR_LSETFCON_FAILED = -32786,
51 RPMERR_SETCAP_FAILED = -32787,
52 RPMERR_CLOSE_FAILED = -32788,
53};
54
55#ifdef __cplusplus
56extern "C" {
57#endif
58
64 char * rpmfileStrerror(int rc);
65
77rpmfi rpmfiNewArchiveWriter(FD_t fd, rpmfiles files);
78
90 rpmfi rpmfiNewArchiveReader(FD_t fd, rpmfiles files, int itype);
91
97 int rpmfiArchiveClose(rpmfi fi);
98
104rpm_loff_t rpmfiArchiveTell(rpmfi fi);
105
113 size_t rpmfiArchiveWrite(rpmfi fi, const void * buf, size_t size);
114
121 int rpmfiArchiveWriteFile(rpmfi fi, FD_t fd);
122
130ssize_t rpmfiArchiveRead(rpmfi fi, void * buf, size_t size);
131
137 int rpmfiArchiveHasContent(rpmfi fi);
138
146 int rpmfiArchiveReadToFile(rpmfi fi, FD_t fd, int nodigest);
147
148#ifdef __cplusplus
149}
150#endif
151
152#endif /* H_ARCHIVE */
rpmfiArchiveClose
int rpmfiArchiveClose(rpmfi fi)
rpmfiArchiveHasContent
int rpmfiArchiveHasContent(rpmfi fi)
rpmfiArchiveRead
ssize_t rpmfiArchiveRead(rpmfi fi, void *buf, size_t size)
rpmfilesErrorCodes
rpmfilesErrorCodes
Definition rpmarchive.h:14
rpmfiArchiveTell
rpm_loff_t rpmfiArchiveTell(rpmfi fi)
rpmfiArchiveReadToFile
int rpmfiArchiveReadToFile(rpmfi fi, FD_t fd, int nodigest)
rpmfileStrerror
char * rpmfileStrerror(int rc)
rpmfiArchiveWrite
size_t rpmfiArchiveWrite(rpmfi fi, const void *buf, size_t size)
rpmfiArchiveWriteFile
int rpmfiArchiveWriteFile(rpmfi fi, FD_t fd)
rpmfiNewArchiveReader
rpmfi rpmfiNewArchiveReader(FD_t fd, rpmfiles files, int itype)
rpmfiNewArchiveWriter
rpmfi rpmfiNewArchiveWriter(FD_t fd, rpmfiles files)
FD_t
struct _FD_s * FD_t
Definition rpmtypes.h:99