20 #ifndef __C_CREATEREPOLIB_MISC_H__
21 #define __C_CREATEREPOLIB_MISC_H__
29 #include <curl/curl.h>
30 #include "compression_wrapper.h"
31 #include "constants.h"
40 #define CR_UNUSED(x) (void)(x)
92 static inline int cr_is_primary(
const char *filename) {
93 if (!strncmp(filename,
"/etc/", 5))
95 if (!strcmp(filename,
"/usr/lib/sendmail"))
97 if (strstr(filename,
"bin/"))
138 #define CR_COPY_ERR 1
149 void cr_download(CURL *handle,
151 const char *destination,
213 GLogLevelFlags log_level,
214 const gchar *message,
224 GLogLevelFlags log_level,
225 const gchar *message,
253 #define cr_cmp_nvrea(A, B) (cr_cmp_evr((A)->epoch, (A)->version, (A)->release,\
254 (B)->epoch, (B)->version, (B)->release))
265 int cr_cmp_evr(
const char *e1,
const char *v1,
const char *r1,
266 const char *e2,
const char *v2,
const char *r2);