source:
scripts/untested/blfs-patches/Python-2.4-db43-2.patch@
a8f17cf
Last change on this file since a8f17cf was 617118d, checked in by , 19 years ago | |
---|---|
|
|
File size: 3.3 KB |
-
Modules/_bsddb.c
diff -uNr Python-2.4-orig/Modules/_bsddb.c Python-2.4/Modules/_bsddb.c
old new 466 466 /* Callback used to save away more information about errors from the DB 467 467 * library. */ 468 468 static char _db_errmsg[1024]; 469 static void _db_errorCallback(const char* prefix, char* msg) 469 static void _db_errorCallback( 470 #if (DBVER >= 43) 471 const DB_ENV *dbenv, 472 #endif 473 const char* prefix, 474 #if (DBVER >= 43) 475 const 476 #endif 477 char* msg) 470 478 { 471 479 strcpy(_db_errmsg, msg); 472 480 } … … 2146 2154 2147 2155 MYDB_BEGIN_ALLOW_THREADS; 2148 2156 #if (DBVER >= 33) 2149 err = self->db->stat(self->db, &sp, flags); 2157 err = self->db->stat(self->db, 2158 #if (DBVER >= 43) 2159 NULL /*txnid*/, 2160 #endif 2161 &sp, flags); 2150 2162 #else 2151 2163 err = self->db->stat(self->db, &sp, NULL, flags); 2152 2164 #endif … … 2408 2420 2409 2421 MYDB_BEGIN_ALLOW_THREADS; 2410 2422 #if (DBVER >= 33) 2411 err = self->db->stat(self->db, &sp, flags); 2423 err = self->db->stat(self->db, 2424 #if (DBVER >= 43) 2425 NULL /*txnid*/, 2426 #endif 2427 &sp, flags); 2412 2428 #else 2413 2429 err = self->db->stat(self->db, &sp, NULL, flags); 2414 2430 #endif … … 2536 2552 err = self->db->get(self->db, txn, &key, &data, 0); 2537 2553 MYDB_END_ALLOW_THREADS; 2538 2554 FREE_DBT(key); 2555 #if (DBVER >= 43) 2556 return PyInt_FromLong((err == DB_BUFFER_SMALL) || (err == 0)); 2557 #else 2539 2558 return PyInt_FromLong((err == ENOMEM) || (err == 0)); 2559 #endif 2540 2560 } 2541 2561 2542 2562 … … 4903 4923 4904 4924 #if (DBVER >= 33) 4905 4925 ADD_INT(d, DB_LSTAT_ABORTED); 4926 #if (DBVER < 43) 4906 4927 ADD_INT(d, DB_LSTAT_ERR); 4928 #endif 4929 #if (DBVER >= 42) 4930 ADD_INT(d, DB_LSTAT_EXPIRED); 4931 #endif 4907 4932 ADD_INT(d, DB_LSTAT_FREE); 4908 4933 ADD_INT(d, DB_LSTAT_HELD); 4909 4934 #if (DBVER == 33) -
setup.py
diff -uNr Python-2.4-orig/setup.py Python-2.4/setup.py
old new 492 492 # when sorted in reverse order, keys for this dict must appear in the 493 493 # order you wish to search - e.g., search for db4 before db3 494 494 db_try_this = { 495 'db4': {'libs': ('db-4.2', 'db42', 'db-4.1', 'db41', 'db-4.0', 'db4',), 496 'libdirs': ('/usr/local/BerkeleyDB.4.2/lib', 495 'db4': {'libs': ('db-4.3', 'db43', 'db-4.2', 'db42', 'db-4.1', 'db41', 'db-4.0', 'db4',), 496 'libdirs': ('/usr/local/BerkeleyDB.4.3/lib', 497 '/usr/local/BerkeleyDB.4.2/lib', 497 498 '/usr/local/BerkeleyDB.4.1/lib', 498 499 '/usr/local/BerkeleyDB.4.0/lib', 499 500 '/usr/local/lib', 500 501 '/opt/sfw', 501 502 '/sw/lib', 502 503 ), 503 'incdirs': ('/usr/local/BerkeleyDB.4.2/include', 504 'incdirs': ('/usr/local/BerkeleyDB.4.3/include', 505 '/usr/local/include/db43', 506 '/usr/local/BerkeleyDB.4.2/include', 504 507 '/usr/local/include/db42', 505 508 '/usr/local/BerkeleyDB.4.1/include', 506 509 '/usr/local/include/db41',
Note:
See TracBrowser
for help on using the repository browser.