rpm
4.9.1.3
|
00001 #ifndef _RPMLEGACY_H 00002 #define _RPMLEGACY_H 00003 00004 #include <rpm/rpmtypes.h> 00005 #include <rpm/rpmutil.h> 00006 00007 /* ==================================================================== */ 00008 /* LEGACY INTERFACES AND TYPES, DO NOT USE IN NEW CODE! */ 00009 /* ==================================================================== */ 00010 00011 #ifdef __cplusplus 00012 extern "C" { 00013 #endif 00014 00015 #ifdef _RPM_4_4_COMPAT 00016 00017 /* mappings for legacy types */ 00018 typedef int32_t int_32 RPM_GNUC_DEPRECATED; 00019 typedef int16_t int_16 RPM_GNUC_DEPRECATED; 00020 typedef int8_t int_8 RPM_GNUC_DEPRECATED; 00021 typedef uint32_t uint_32 RPM_GNUC_DEPRECATED; 00022 typedef uint16_t uint_16 RPM_GNUC_DEPRECATED; 00023 typedef uint8_t uint_8 RPM_GNUC_DEPRECATED; 00024 00025 typedef rpm_tag_t * hTAG_t RPM_GNUC_DEPRECATED; 00026 typedef rpm_tagtype_t * hTYP_t RPM_GNUC_DEPRECATED; 00027 typedef const void * hPTR_t RPM_GNUC_DEPRECATED; 00028 typedef rpm_count_t * hCNT_t RPM_GNUC_DEPRECATED; 00029 00030 typedef rpmSpec Spec RPM_GNUC_DEPRECATED; 00031 00032 /* legacy header interfaces */ 00033 00048 int headerGetEntry(Header h, rpm_tag_t tag, 00049 rpm_tagtype_t * type, 00050 rpm_data_t * p, 00051 rpm_count_t * c) RPM_GNUC_DEPRECATED; 00052 00066 int headerGetEntryMinMemory(Header h, rpm_tag_t tag, 00067 rpm_tagtype_t * type, 00068 rpm_data_t * p, 00069 rpm_count_t * c) RPM_GNUC_DEPRECATED; 00070 00085 int headerAddEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, 00086 rpm_constdata_t p, rpm_count_t c) RPM_GNUC_DEPRECATED; 00087 00102 int headerAppendEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, 00103 rpm_constdata_t p, rpm_count_t c) RPM_GNUC_DEPRECATED; 00104 00114 int headerAddOrAppendEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, 00115 rpm_constdata_t p, rpm_count_t c) RPM_GNUC_DEPRECATED; 00116 00129 int headerModifyEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, 00130 rpm_constdata_t p, rpm_count_t c) RPM_GNUC_DEPRECATED; 00131 00142 int headerRemoveEntry(Header h, rpm_tag_t tag) RPM_GNUC_DEPRECATED; 00143 00156 #define headerSprintf(_h, _fmt, _tbltags, _exts, _emsg) \ 00157 headerFormat((_h), (_fmt), (_emsg)) 00158 00170 int headerNextIterator(HeaderIterator hi, 00171 rpm_tag_t * tag, 00172 rpm_tagtype_t * type, 00173 rpm_data_t * p, 00174 rpm_count_t * c) RPM_GNUC_DEPRECATED; 00175 00185 void * headerFreeTag(Header h, rpm_data_t data, rpm_tagtype_t type) RPM_GNUC_DEPRECATED; 00186 00195 void * headerFreeData(rpm_data_t data, rpm_tagtype_t type) RPM_GNUC_DEPRECATED; 00196 00201 typedef void * (*HFD_t) (rpm_data_t data, rpm_tagtype_t type) RPM_GNUC_DEPRECATED; 00202 typedef int (*HGE_t) (Header h, rpm_tag_t tag, rpm_tagtype_t * type, 00203 rpm_data_t * p, rpm_count_t * c) RPM_GNUC_DEPRECATED; 00204 typedef int (*HAE_t) (Header h, rpm_tag_t tag, rpm_tagtype_t type, 00205 rpm_constdata_t p, rpm_count_t c) RPM_GNUC_DEPRECATED; 00206 typedef int (*HME_t) (Header h, rpm_tag_t tag, rpm_tagtype_t type, 00207 rpm_constdata_t p, rpm_count_t c) RPM_GNUC_DEPRECATED; 00208 typedef int (*HRE_t) (Header h, rpm_tag_t tag) RPM_GNUC_DEPRECATED; 00211 /* other misc renamed / namespaced functions */ 00212 /* TODO: arrange deprecation warnings on these too... */ 00213 #define isCompressed rpmFileIsCompressed 00214 #define makeTempFile rpmMkTempFile 00215 #define whatis rpmfiWhatis 00216 #define tagName rpmTagGetName 00217 #define tagType rpmTagGetType 00218 #define tagValue rpmTagGetValue 00219 00220 #define xislower rislower 00221 #define xisupper risupper 00222 #define xisalpha risalpha 00223 #define xisdigit risdigit 00224 #define xisalnum risalnum 00225 #define xisblank risblank 00226 #define xisspace risspace 00227 #define xtolower rtolower 00228 #define xtoupper rtoupper 00229 #define xstrcasecmp rstrcasecmp 00230 #define xstrncasecmp rstrncasecmp 00231 00232 #define rpmMessage rpmlog 00233 #define rpmError rpmlog 00234 00235 #endif /* _RPM_4_4_COMPAT */ 00236 00237 #ifdef __cplusplus 00238 } 00239 #endif 00240 00241 #endif /* _RPMLEGACY_H */