- fix build with db 4.[234]
authorJakub Bogusz <qboosh@pld-linux.org>
Sat, 28 Jan 2006 23:29:57 +0000 (23:29 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    cDonkey-db.patch -> 1.1

cDonkey-db.patch [new file with mode: 0644]

diff --git a/cDonkey-db.patch b/cDonkey-db.patch
new file mode 100644 (file)
index 0000000..060a1a1
--- /dev/null
@@ -0,0 +1,23 @@
+--- cDonkey-0.9.0/db_macro.h.orig      2003-05-01 17:21:23.000000000 +0200
++++ cDonkey-0.9.0/db_macro.h   2006-01-29 00:02:01.652279750 +0100
+@@ -15,7 +15,7 @@
+ #define DB_associate(db,sec,key,art)       db->associate(db, sec, key, art)
+ #endif
+-#if (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 1)
++#if (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR >= 1)
+ #define DB_open(db,loc,name,type,art,mode) db->open(db, NULL, loc, name, type, art, mode)
+ #define DB_associate(db,sec,key,art)       db->associate(db, NULL, sec, key, art)
+ #endif
+@@ -43,7 +43,11 @@
+ #define DB_associate2(db,sec,key)             if (0 != (err = DB_associate(db,sec,key,DB_CREATE))) DB_error()
+ #define DB_set_cachesize2(db,len)             if (0 != (err = DB_set_cachesize(db,len          ))) DB_error()
+ #define DB_set_bt_compare2(db,cmp)            if (0 != (err = DB_set_bt_compare(db ,cmp        ))) DB_error()
++#if (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR >= 3)
++#define DB_stat(db,info)                      if (0 != (err = db->stat(db, NULL, &info, 0      ))) DB_error()
++#else
+ #define DB_stat(db,info)                      if (0 != (err = db->stat(db, &info, 0            ))) DB_error()
++#endif
+ #define DB_del2(db,key)                               if (0 != (err = DB_del (db, key                  ))) if (err != DB_NOTFOUND) DB_error()
+ #define DB_set_flags2(db,flag)                        if (0 != (err = DB_set_flags (db, flag           ))) DB_error()
This page took 0.04373 seconds and 4 git commands to generate.