createrepo_c library  0.9.1
C library for metadata manipulation
package.h
1 /* createrepo_c - Library of routines for manipulation with repodata
2  * Copyright (C) 2012 Tomas Mlcoch
3  * Copyright (C) 2007 James Bowes
4  * Copyright (C) 2006 Seth Vidal
5  *
6  * This program is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU General Public License
8  * as published by the Free Software Foundation; either version 2
9  * of the License, or (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
19  * USA.
20  */
21 
22 #ifndef __C_CREATEREPOLIB_PACKAGE_H__
23 #define __C_CREATEREPOLIB_PACKAGE_H__
24 
25 #ifdef __cplusplus
26 extern "C" {
27 #endif
28 
29 #include <glib.h>
30 
36 typedef enum {
39  /* Some values are reserved (for sqlite, solv, etc..) */
45 
48 typedef struct {
49  char *name;
50  char *flags;
52  char *epoch;
53  char *version;
54  char *release;
55  gboolean pre;
57 
60 typedef struct {
61  char *type;
62  char *path;
63  char *name;
65 
68 typedef struct {
69  char *author;
70  gint64 date;
71  char *changelog;
73 
76 typedef struct {
77  void *data;
78  gsize size;
80 
83 typedef struct {
84  gint64 pkgKey;
85  char *pkgId;
86  char *name;
87  char *arch;
88  char *version;
89  char *epoch;
90  char *release;
91  char *summary;
92  char *description;
93  char *url;
94  gint64 time_file;
95  gint64 time_build;
96  char *rpm_license;
97  char *rpm_vendor;
98  char *rpm_group;
104  gint64 rpm_header_end;
105  char *rpm_packager;
106  gint64 size_package;
107  gint64 size_installed;
108  gint64 size_archive;
115  GSList *requires;
116  GSList *provides;
117  GSList *conflicts;
118  GSList *obsoletes;
119  GSList *suggests;
120  GSList *enhances;
121  GSList *recommends;
122  GSList *supplements;
124  GSList *files;
126  GSList *changelogs;
129  char *hdrid;
130  cr_BinaryData *siggpg;
131  cr_BinaryData *sigpgp;
132 
133  GStringChunk *chunk;
138 } cr_Package;
139 
144 
149 
154 
159 
164 
169 
173 void cr_package_free(cr_Package *package);
174 
179 gchar *cr_package_nvra(cr_Package *package);
180 
185 gchar *cr_package_nevra(cr_Package *package);
186 
192 
195 #ifdef __cplusplus
196 }
197 #endif
198 
199 #endif /* __C_CREATEREPOLIB_PACKAGE_H__ */
char * version
Definition: package.h:53
char * release
Definition: package.h:90
cr_Package * cr_package_copy(cr_Package *package)
char * url
Definition: package.h:93
cr_PackageLoadingFlags loadingflags
Definition: package.h:136
GSList * recommends
Definition: package.h:121
GStringChunk * chunk
Definition: package.h:133
cr_PackageLoadingFlags
Definition: package.h:36
cr_Package * cr_package_new_without_chunk(void)
char * name
Definition: package.h:49
char * name
Definition: package.h:86
void cr_package_free(cr_Package *package)
Definition: package.h:68
char * location_base
Definition: package.h:111
char * rpm_buildhost
Definition: package.h:100
gint64 time_build
Definition: package.h:95
GSList * enhances
Definition: package.h:120
char * description
Definition: package.h:92
char * author
Definition: package.h:69
GSList * requires
Definition: package.h:115
gint64 time_file
Definition: package.h:94
gint64 pkgKey
Definition: package.h:84
GSList * suggests
Definition: package.h:119
gint64 date
Definition: package.h:70
char * epoch
Definition: package.h:89
char * type
Definition: package.h:61
char * rpm_group
Definition: package.h:98
char * summary
Definition: package.h:91
char * location_href
Definition: package.h:110
cr_ChangelogEntry * cr_changelog_entry_new(void)
gint64 size_archive
Definition: package.h:108
cr_BinaryData * cr_binary_data_new(void)
gchar * cr_package_nevra(cr_Package *package)
GSList * conflicts
Definition: package.h:117
gint64 rpm_header_end
Definition: package.h:104
char * checksum_type
Definition: package.h:112
GSList * files
Definition: package.h:124
gboolean pre
Definition: package.h:55
cr_Package * cr_package_new(void)
char * rpm_sourcerpm
Definition: package.h:102
gchar * cr_package_nvra(cr_Package *package)
char * arch
Definition: package.h:87
char * changelog
Definition: package.h:71
cr_Dependency * cr_dependency_new(void)
char * rpm_vendor
Definition: package.h:97
char * pkgId
Definition: package.h:85
GSList * supplements
Definition: package.h:122
char * release
Definition: package.h:54
char * path
Definition: package.h:62
cr_PackageFile * cr_package_file_new(void)
GSList * provides
Definition: package.h:116
char * flags
Definition: package.h:50
gint64 rpm_header_start
Definition: package.h:103
char * version
Definition: package.h:88
GSList * obsoletes
Definition: package.h:118
char * rpm_packager
Definition: package.h:105
GSList * changelogs
Definition: package.h:126
char * epoch
Definition: package.h:52
char * name
Definition: package.h:63
char * rpm_license
Definition: package.h:96
gint64 size_package
Definition: package.h:106
gint64 size_installed
Definition: package.h:107