]> git.saurik.com Git - apt.git/blob - test/rpmver.cc
be982603b8107440f8b05420189204fd317593d4
[apt.git] / test / rpmver.cc
1 #include <apt-pkg/debversion.h>
2 #include <rpm/rpmio.h>
3 #include <rpm/misc.h>
4 #include <stdlib.h>
5
6 int main(int argc,const char *argv[])
7 {
8 printf("'%s' <> '%s': ",argv[1],argv[2]);
9 printf("rpm: %i deb: %i\n",rpmvercmp(argv[1],argv[2]),
10 debVS.CmpFragment(argv[1],argv[1]+strlen(argv[1]),
11 argv[2],argv[2]+strlen(argv[2])));
12
13 printf("'%s' <> '%s': ",argv[2],argv[1]);
14 printf("rpm: %i deb: %i\n",rpmvercmp(argv[2],argv[1]),
15 debVS.CmpFragment(argv[2],argv[2]+strlen(argv[2]),
16 argv[1],argv[1]+strlen(argv[1])));
17 return 0;
18 }