Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm trying to build the python module pyodbc on a RHEL5 server. I've downloaded the source directly from the pyodbc google code page. Whenever I run the

python setup.py build

command, I'm greeted with this:

building 'pyodbc' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fPIC -DPYODBC_VERSION=2.1.8 -I/usr/include/python2.4 -c /home/pyodbc-2.1.8/src/pyodbcmodule.cpp -o build/temp.linux-x86_64-2.4/home/pyodbc-2.1.8/src/pyodbcmodule.o -Wno-write-strings
/home/pyodbc-2.1.8/src/pyodbcmodule.cpp: In function âvoid initpyodbc()â:
/home/pyodbc-2.1.8/src/pyodbcmodule.cpp:919: error: invalid conversion from âconst char*â to âchar*â
/home/pyodbc-2.1.8/src/pyodbcmodule.cpp:919: error:   initializing argument 3 of âint PyModule_AddStringConstant(PyObject*, char*, char*)â
error: command 'gcc' failed with exit status 1

Not sure where those "â" are coming from, but I have a hunch those are causing the problem. I have checked http://code.google.com/p/pyodbc/wiki/Building and have unixODBC-devel installed.

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

Those odd characters aren't causing the problem. The -Wall option is given causing type conversion warning to become an error. It is fixed in 2.1.9.

http://code.google.com/p/pyodbc/issues/detail?id=174

share|improve this answer
    
I'm guessing github is where to get 2.1.9? Thanks for the info! –  Omega192 Jul 20 '11 at 20:54
    
Wait. Nope. Github just has the ports to Python 3. Hmm, 2.1.9 hasn't been released yet? Drat. –  Omega192 Jul 20 '11 at 21:00
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.