]> git.pld-linux.org Git - packages/poldek.git/blob - poldek-rpm-4.4.8.patch
- internal changes in rpm 4.4.9
[packages/poldek.git] / poldek-rpm-4.4.8.patch
1 diff -urN poldek-0.20.1-cvs20070108.22.org/pm/rpm/misc.c poldek-0.20.1-cvs20070108.22/pm/rpm/misc.c
2 --- poldek-0.20.1-cvs20070108.22.org/pm/rpm/misc.c      2007-01-08 22:14:18.000000000 +0100
3 +++ poldek-0.20.1-cvs20070108.22/pm/rpm/misc.c  2007-05-21 08:01:00.385663226 +0200
4 @@ -22,6 +22,7 @@
5  #include <stdint.h>
6  #include <string.h>
7  
8 +#define        _RPMPRCO_INTERNAL 1
9  #include <rpm/rpmlib.h>
10  #if HAVE_RPMDSRPMLIB
11  # include <rpm/rpmds.h>
12 @@ -73,6 +74,24 @@
13  
14  typedef int (*rpmcap_fn)(rpmds *ds, void *);
15  
16 +#ifdef HAVE_RPMDSSYSINFO
17 +static int pm_rpmdsSysinfo(rpmds * dsp, const char * fn) {
18 +       int ret;
19 +// XXX: better test welcome
20 +#define RPM_VERSION(a,b,c) ((a)*65536+(b)*256+(c))
21 +#if RPM_VERSION(RPM_FORMAT_VERSION,RPM_MAJOR_VERSION,RPM_MINOR_VERSION) >= RPM_VERSION(4,4,8)
22 +       rpmPRCO PRCO = rpmdsNewPRCO(NULL);
23 +       PRCO->Pdsp = dsp;
24 +       ret = rpmdsSysinfo(PRCO, fn);
25 +       PRCO->Pdsp = NULL;
26 +       rpmdsFreePRCO(PRCO);
27 +#else
28 +       ret = rpmdsSysinfo(dsp, fn);
29 +#endif
30 +       return ret;
31 +}
32 +#endif
33 +
34  static int get_rpmlib_caps(tn_array *caps)
35  {
36      rpmds     ds = NULL;
37 @@ -86,7 +105,7 @@
38          (rpmcap_fn)rpmdsGetconf,
39  #endif
40  #ifdef HAVE_RPMDSSYSINFO
41 -        (rpmcap_fn)rpmdsSysinfo,
42 +        (rpmcap_fn)pm_rpmdsSysinfo,
43  #endif        
44  #ifdef HAVE_RPMDSUNAME
45          (rpmcap_fn)rpmdsUname,
This page took 0.070576 seconds and 3 git commands to generate.