Open GoogleCodeExporter opened 8 years ago
This is the result of the build, perhaps it is useful.
~/pyodbc-3.0.7$ sudo python setup.py build
running build
running build_ext
building 'pyodbc' extension
creating build
creating build/temp.linux-x86_64-3.3
creating build/temp.linux-x86_64-3.3/datos
creating build/temp.linux-x86_64-3.3/datos/usuarios
creating build/temp.linux-x86_64-3.3/home/user
creating build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7
creating build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/pyodbcmodule.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/pyodbcmodule.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/buffer.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/buffer.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/connection.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/connection.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
/home/user/pyodbc-3.0.7/src/connection.cpp: In function ‘PyObject*
Connection_getinfo(PyObject*, PyObject*)’:
/home/user/pyodbc-3.0.7/src/connection.cpp:600:40: warning: dereferencing
type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
SQLUINTEGER n = *(SQLUINTEGER*)szBuffer; // Does this work on PPC or do we need a union?
^
/home/user/pyodbc-3.0.7/src/connection.cpp:613:49: warning: dereferencing
type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
result = PyInt_FromLong(*(SQLUSMALLINT*)szBuffer);
^
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/row.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/row.o -Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/cursor.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/cursor.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/params.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/params.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/sqlwchar.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/sqlwchar.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/cnxninfo.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/cnxninfo.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/getdata.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/getdata.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/pyodbcdbg.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/pyodbcdbg.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/pyodbccompat.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/pyodbccompat.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2 -fPIC -DPYODBC_VERSION=3.0.7 -I/usr/include/python3.3m -c
/home/user/pyodbc-3.0.7/src/errors.cpp -o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/errors.o
-Wno-write-strings
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for
C/ObjC but not for C++ [enabled by default]
creating build/lib.linux-x86_64-3.3
x86_64-linux-gnu-g++ -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions
-Wl,-Bsymbolic-functions -Wl,-z,relro -Wno-unused-result -DNDEBUG -g -fwrapv
-O2 -Wall -Wstrict-prototypes -g -fstack-protector --param=ssp-buffer-size=4
-Wformat -Werror=format-security -Wl,-Bsymbolic-functions -Wl,-z,relro -g
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
-D_FORTIFY_SOURCE=2
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/pyodbcmodule.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/buffer.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/connection.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/row.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/cursor.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/params.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/sqlwchar.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/cnxninfo.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/getdata.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/pyodbcdbg.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/pyodbccompat.o
build/temp.linux-x86_64-3.3/home/user/pyodbc-3.0.7/src/errors.o -lodbc -o
build/lib.linux-x86_64-3.3/pyodbc.cpython-33m.so
~/pyodbc-3.0.7$ sudo python setup.py install
running install
running build
running build_ext
running install_lib
copying build/lib.linux-x86_64-3.3/pyodbc.cpython-33m.so ->
/usr/local/lib/python3.3/dist-packages
running install_egg_info
Removing /usr/local/lib/python3.3/dist-packages/pyodbc-3.0.7.egg-info
Writing /usr/local/lib/python3.3/dist-packages/pyodbc-3.0.7.egg-info
Thanks!
Original comment by a.navarr...@gmail.com
on 26 Aug 2014 at 8:46
Same issue on Ubuntu 15.4 with Python 3.4 and latest PyODBC.
Same code works on windows under python 3.2.
Original comment by tswor...@gmail.com
on 26 Apr 2015 at 5:39
wanted to follow up. In my case the ODBC driver (NetezzaSQL) was set to use
UTF8. I first though the issue was either a UC2 or UC4 build of Python. Both
made no difference. Switching the driver to UTF16
(UnicodeTranslationOption=utf16) fixed the issue for me.
Original comment by tswor...@gmail.com
on 26 Apr 2015 at 6:42
Original issue reported on code.google.com by
a.navarr...@gmail.com
on 26 Aug 2014 at 8:36