From 922a2f8c1cd90f6cc430857afca75c076645fb9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Per=20=C3=98yvind=20Karlsen?= Date: Wed, 16 Jan 2008 22:23:29 +0000 Subject: more rpm5 work.. --- URPM.xs | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/URPM.xs b/URPM.xs index 3f48775..8da8d36 100644 --- a/URPM.xs +++ b/URPM.xs @@ -37,7 +37,9 @@ static inline void *_free(const void * p) { typedef struct rpmSpec_s * Spec; #else #ifndef RPM_450 -#define rpmtsImportPubkey rpmcliImportPubkey +#define rpmtsImportPubkey rpmcliImportPubkey +#endif +#if !defined(RPM_450) || !defined(RPM_500) #define rpmProblemGetType(p) p->type #define rpmProblemGetPkgNEVR(p) p->pkgNEVR #define rpmProblemGetAltNEVR(p) p->altNEVR @@ -55,7 +57,16 @@ typedef struct rpmSpec_s * Spec; #include #ifdef RPM_500 +# define _RPMTAG_INTERNAL #include +/* (peroyvind): A bit ugly, work in progress.. */ +#define int_32 evrFlags +#define uint_16 uint16_t +#define RPM_NULL_TYPE 0 +#define RPM_CHAR_TYPE RPM_UINT8_TYPE +#define RPM_INT8_TYPE RPM_UINT8_TYPE +#define RPM_INT16_TYPE RPM_UINT16_TYPE +#define RPM_INT32_TYPE RPM_UINT32_TYPE #else #include #endif @@ -139,7 +150,7 @@ static const void* unused_variable(const void *p) { } static int rpmError_callback_data; -#ifdef RPM_ORG +#if defined(RPM_ORG) || defined(RPM_500) int rpmError_callback() { write_nocheck(rpmError_callback_data, rpmlogMessage(), strlen(rpmlogMessage())); return RPMLOG_DEFAULT; -- cgit v1.2.1