mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-01-31 09:24:07 +03:00
parent
ebd73c14a8
commit
288f9ee809
|
@ -2,6 +2,9 @@
|
|||
|
||||
* setup.py: bumped to version 2.3.1.dev0
|
||||
|
||||
* datetime modules reorganized to work around CentOS 5.5 x86_64 buld
|
||||
problem. Closes ticket #23
|
||||
|
||||
2010-12-01 Daniele Varrazzo <daniele.varrazzo@gmail.com>
|
||||
|
||||
* lib/extras.py: DictRow items can be updated. Patch by Alex Aster.
|
||||
|
|
6
NEWS-2.3
6
NEWS-2.3
|
@ -1,3 +1,9 @@
|
|||
What's new in psycopg 2.3.1
|
||||
---------------------------
|
||||
|
||||
- Fixed build problem on CentOS 5.5 x86_64 (ticket #23).
|
||||
|
||||
|
||||
What's new in psycopg 2.3.0
|
||||
---------------------------
|
||||
|
||||
|
|
|
@ -48,12 +48,10 @@
|
|||
#include "psycopg/adapter_asis.h"
|
||||
#include "psycopg/adapter_list.h"
|
||||
#include "psycopg/typecast_binary.h"
|
||||
#include "psycopg/typecast_datetime.h"
|
||||
|
||||
#ifdef HAVE_MXDATETIME
|
||||
#include <mxDateTime.h>
|
||||
#include "psycopg/adapter_mxdatetime.h"
|
||||
#include "psycopg/typecast_mxdatetime.h"
|
||||
#endif
|
||||
|
||||
/* some module-level variables, like the datetime module */
|
||||
|
@ -764,7 +762,6 @@ init_psycopg(void)
|
|||
return;
|
||||
}
|
||||
if (psyco_adapter_mxdatetime_init()) { return; }
|
||||
if (psyco_typecast_mxdatetime_init()) { return; }
|
||||
#endif
|
||||
|
||||
/* import python builtin datetime module, if available */
|
||||
|
@ -778,7 +775,6 @@ init_psycopg(void)
|
|||
/* Initialize the PyDateTimeAPI everywhere is used */
|
||||
PyDateTime_IMPORT;
|
||||
if (psyco_adapter_datetime_init()) { return; }
|
||||
if (psyco_typecast_datetime_init()) { return; }
|
||||
|
||||
pydatetimeType.ob_type = &PyType_Type;
|
||||
if (PyType_Ready(&pydatetimeType) == -1) return;
|
||||
|
|
|
@ -277,6 +277,7 @@ typecast_init(PyObject *dict)
|
|||
|
||||
/* register the date/time typecasters with their original names */
|
||||
#ifdef HAVE_MXDATETIME
|
||||
if (psyco_typecast_mxdatetime_init()) { return -1; }
|
||||
for (i = 0; typecast_mxdatetime[i].name != NULL; i++) {
|
||||
typecastObject *t;
|
||||
Dprintf("typecast_init: initializing %s", typecast_mxdatetime[i].name);
|
||||
|
@ -285,6 +286,8 @@ typecast_init(PyObject *dict)
|
|||
PyDict_SetItem(dict, t->name, (PyObject *)t);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (psyco_typecast_datetime_init()) { return -1; }
|
||||
for (i = 0; typecast_pydatetime[i].name != NULL; i++) {
|
||||
typecastObject *t;
|
||||
Dprintf("typecast_init: initializing %s", typecast_pydatetime[i].name);
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
#include <math.h>
|
||||
#include "datetime.h"
|
||||
|
||||
int
|
||||
static int
|
||||
psyco_typecast_datetime_init(void)
|
||||
{
|
||||
Dprintf("psyco_typecast_datetime_init: datetime init");
|
||||
|
|
|
@ -1,44 +0,0 @@
|
|||
/* typecast_datetime.h - definitions for datetime objects typecasters
|
||||
*
|
||||
* Copyright (C) 2010 Daniele Varrazzo <daniele.varrazzo@gmail.com>
|
||||
*
|
||||
* This file is part of psycopg.
|
||||
*
|
||||
* psycopg2 is free software: you can redistribute it and/or modify it
|
||||
* under the terms of the GNU Lesser General Public License as published
|
||||
* by the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* In addition, as a special exception, the copyright holders give
|
||||
* permission to link this program with the OpenSSL library (or with
|
||||
* modified versions of OpenSSL that use the same license as OpenSSL),
|
||||
* and distribute linked combinations including the two.
|
||||
*
|
||||
* You must obey the GNU Lesser General Public License in all respects for
|
||||
* all of the code used other than OpenSSL.
|
||||
*
|
||||
* psycopg2 is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
* License for more details.
|
||||
*/
|
||||
|
||||
#ifndef PSYCOPG_TYPECAST_DATETIME_H
|
||||
#define PSYCOPG_TYPECAST_DATETIME_H 1
|
||||
|
||||
#define PY_SSIZE_T_CLEAN
|
||||
#include <Python.h>
|
||||
|
||||
#include "psycopg/config.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
HIDDEN int psyco_typecast_datetime_init(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !defined(PSYCOPG_TYPECAST_DATETIME_H) */
|
|
@ -25,7 +25,7 @@
|
|||
|
||||
#include "mxDateTime.h"
|
||||
|
||||
int
|
||||
static int
|
||||
psyco_typecast_mxdatetime_init(void)
|
||||
{
|
||||
Dprintf("psyco_typecast_mxdatetime_init: mx.DateTime init");
|
||||
|
|
|
@ -1,44 +0,0 @@
|
|||
/* typecast_mxdatetime.h - definitions for mx.DateTime typecasters
|
||||
*
|
||||
* Copyright (C) 2010 Daniele Varrazzo <daniele.varrazzo@gmail.com>
|
||||
*
|
||||
* This file is part of psycopg.
|
||||
*
|
||||
* psycopg2 is free software: you can redistribute it and/or modify it
|
||||
* under the terms of the GNU Lesser General Public License as published
|
||||
* by the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* In addition, as a special exception, the copyright holders give
|
||||
* permission to link this program with the OpenSSL library (or with
|
||||
* modified versions of OpenSSL that use the same license as OpenSSL),
|
||||
* and distribute linked combinations including the two.
|
||||
*
|
||||
* You must obey the GNU Lesser General Public License in all respects for
|
||||
* all of the code used other than OpenSSL.
|
||||
*
|
||||
* psycopg2 is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
* License for more details.
|
||||
*/
|
||||
|
||||
#ifndef PSYCOPG_TYPECAST_MXDATETIME_H
|
||||
#define PSYCOPG_TYPECAST_MXDATETIME_H 1
|
||||
|
||||
#define PY_SSIZE_T_CLEAN
|
||||
#include <Python.h>
|
||||
|
||||
#include "psycopg/config.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
HIDDEN int psyco_typecast_mxdatetime_init(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !defined(PSYCOPG_TYPECAST_MXDATETIME_H) */
|
Loading…
Reference in New Issue
Block a user