source: trunk/dports/sysutils/apt-rpm/files/patch-rpmsense.diff @ 26873

Last change on this file since 26873 was 26873, checked in by afb@…, 12 years ago
  • new port, APT for RPM (compare "apt")
  • functional patches for Darwin/FreeBSD
  • using DistroVerPkg "macports-release"
  • sample config for a repo with MD data
File size: 1.4 KB
  • ./apt-pkg/rpm/rpmhandler.cc

    old new  
    4848#define rpmxxInitIterator(a,b,c,d) rpmdbInitIterator(a,b,c,d)
    4949#endif
    5050
     51#ifndef _RPMEVR_INTERNAL
     52// rpmevr.h/evrFlags_e
     53#define RPMSENSE_ANY 0
     54#endif
     55
    5156// An attempt to deal with false zero epochs from repomd. With older rpm's we
    5257// can only blindly trust the repo admin created the repository with options
    5358// suitable for those versions. For rpm >= 4.2.1 this is linked with
     
    231236   if (Type == pkgCache::Dep::Depends) {
    232237      if (flags & RPMSENSE_PREREQ)
    233238         Type = pkgCache::Dep::PreDepends;
    234 #if RPM_VERSION >= 0x040403
     239#if RPM_VERSION >= 0x040403 && defined(_RPMEVR_INTERNAL)
    235240      else if (flags & RPMSENSE_MISSINGOK)
    236241         Type = pkgCache::Dep::Suggests;
    237242#endif
     
    308313      case pkgCache::Dep::Provides:
    309314         deptype = RPMTAG_PROVIDENAME;
    310315         break;
    311 #if RPM_VERSION >= 0x040403
     316#if RPM_VERSION >= 0x040403 && defined(_RPMEVR_INTERNAL)
    312317      case pkgCache::Dep::Suggests:
    313318         deptype = RPMTAG_SUGGESTNAME;
    314319         break;
  • ./apt-pkg/rpm/rpmversion.cc

    old new  
    3232#include <rpm/rpmds.h>
    3333#endif
    3434
     35#ifndef _RPMEVR_INTERNAL
     36// rpmevr.h/evrFlags_e
     37#define RPMSENSE_ANY 0
     38#endif
     39
    3540rpmVersioningSystem rpmVS;
    3641
    3742// rpmVS::rpmVersioningSystem - Constructor                             /*{{{*/
Note: See TracBrowser for help on using the repository browser.