Bobspadger / pyodbc

Automatically exported from code.google.com/p/pyodbc
MIT No Attribution
0 stars 0 forks source link

pydobc py3 branch won't build on OSX Py3.1 #200

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Install Python3.1 using macports on OSX Lion.
2. Get the py3 branch.
3. build

What is the expected output? What do you see instead?
Expected a full build, instead errors out.

Lots of warnings, bu I see those on py2.7 also.
/Users/rizwank/Documents/CodeZoo/pyodbc-py3/src/pyodbccompat.h:106:8: warning: 
extra tokens at end of #endif directive [-Wextra-tokens]
#endif PYODBCCOMPAT_H
       ^
       //
/Users/rizwank/Documents/CodeZoo/pyodbc-py3/src/row.cpp:344:13: error: no 
matching function for call to 'PySlice_GetIndicesEx'
        if (PySlice_GetIndicesEx(key, row->cValues, &start, &stop, &step, &slicelength) < 0)
            ^~~~~~~~~~~~~~~~~~~~
/opt/local/Library/Frameworks/Python.framework/Versions/3.1/include/python3.1/sl
iceobject.h:37:17: note: candidate function not viable: no known conversion 
from 'PyObject *'
      (aka '_object *') to 'PySliceObject *' for 1st argument
PyAPI_FUNC(int) PySlice_GetIndicesEx(PySliceObject *r, Py_ssize_t length,
                ^
/Users/rizwank/Documents/CodeZoo/pyodbc-py3/src/row.cpp:382:5: error: cannot 
initialize a member subobject of type 'void *' with an lvalue of type
      'PyObject *(PyObject *, Py_ssize_t, Py_ssize_t)'
    Row_slice,                         // sq_slice
    ^~~~~~~~~
/Users/rizwank/Documents/CodeZoo/pyodbc-py3/src/row.cpp:401:7: warning: 
conversion from string literal to 'char *' is deprecated 
[-Wdeprecated-writable-strings]
    { "cursor_description", T_OBJECT_EX, offsetof(Row, description), READONLY, description_doc },
      ^
2 warnings and 2 errors generated.
error: command '/Developer/usr/bin/clang' failed with exit status 1

Original issue reported on code.google.com by rizw...@gmail.com on 20 Aug 2011 at 6:59

GoogleCodeExporter commented 9 years ago
Fixed in py3-3.0.1-beta02

It turns out the problem was it would not build on any 3.1.  I had upgrade my 
development boxes to 3.2 and had not been able to get the OS/X box working 
lately.  I now have 3.1 and 3.2 installed on some other boxes for testing.

Original comment by mkleehammer on 21 Aug 2011 at 7:34