Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sqlite modules doesn't build with 2.7.4 on Mac OS X 10.4 #62057

Closed
malemburg opened this issue Apr 27, 2013 · 18 comments
Closed

sqlite modules doesn't build with 2.7.4 on Mac OS X 10.4 #62057

malemburg opened this issue Apr 27, 2013 · 18 comments
Assignees
Labels
build The build process and cross-build extension-modules C modules in the Modules dir release-blocker stdlib Python modules in the Lib dir

Comments

@malemburg
Copy link
Member

BPO 17857
Nosy @malemburg, @birkenfeld, @larryhastings, @benjaminp, @ned-deily, @davidmalcolm, @akheron, @msabramo, @serhiy-storchaka
Files
  • sqlite_int64.patch
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/serhiy-storchaka'
    closed_at = <Date 2013-05-12.09:14:39.665>
    created_at = <Date 2013-04-27.18:46:05.133>
    labels = ['extension-modules', 'build', 'library', 'release-blocker']
    title = "sqlite modules doesn't build with 2.7.4 on Mac OS X 10.4"
    updated_at = <Date 2013-05-12.10:32:40.254>
    user = 'https://github.com/malemburg'

    bugs.python.org fields:

    activity = <Date 2013-05-12.10:32:40.254>
    actor = 'python-dev'
    assignee = 'serhiy.storchaka'
    closed = True
    closed_date = <Date 2013-05-12.09:14:39.665>
    closer = 'georg.brandl'
    components = ['Extension Modules', 'Library (Lib)']
    creation = <Date 2013-04-27.18:46:05.133>
    creator = 'lemburg'
    dependencies = []
    files = ['30035']
    hgrepos = []
    issue_num = 17857
    keywords = ['patch']
    message_count = 18.0
    messages = ['187921', '187924', '187930', '187931', '187939', '187940', '187951', '187971', '187972', '187974', '188012', '188076', '188083', '188175', '188182', '188217', '188992', '189000']
    nosy_count = 12.0
    nosy_names = ['lemburg', 'georg.brandl', 'larry', 'benjamin.peterson', 'ned.deily', 'dmalcolm', 'python-dev', 'petri.lehtinen', 'Marc.Abramowitz', 'serhiy.storchaka', 'Joakim.Sernbrant', 'bharper']
    pr_nums = []
    priority = 'release blocker'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'compile error'
    url = 'https://bugs.python.org/issue17857'
    versions = ['Python 2.7', 'Python 3.2', 'Python 3.3', 'Python 3.4']

    @malemburg
    Copy link
    Member Author

    This is essentially the same issue as http://bugs.python.org/issue14572.

    The following addition in Python 2.7.4 (compared to 2.7.3) reintroduced the same problem in a different place:

    --- Python-2.7.3/Modules/_sqlite/util.h 2012-04-10 01:07:33.000000000 +0200
    +++ Python-2.7.4/Modules/_sqlite//util.h        2013-04-06 16:02:36.000000000 +0200
    @@ -33,6 +33,10 @@ int pysqlite_step(sqlite3_stmt* statemen
     /**
      * Checks the SQLite error code and sets the appropriate DB-API exception.
      * Returns the error code (0 means no error occurred).
      */
     int _pysqlite_seterror(sqlite3* db, sqlite3_stmt* st);
    +
    +PyObject * _pysqlite_long_from_int64(sqlite3_int64 value);
    +sqlite3_int64 _pysqlite_long_as_int64(PyObject * value);
    +
     #endif

    The fix is the same as for the 2.7.3 issue: replace sqlite3_int64 with sqlite_int64

    @malemburg malemburg added extension-modules C modules in the Modules dir stdlib Python modules in the Lib dir labels Apr 27, 2013
    @malemburg
    Copy link
    Member Author

    Adding the same people to the nosy list as on issue bpo-14572.

    @malemburg malemburg added the build The build process and cross-build label Apr 27, 2013
    @serhiy-storchaka
    Copy link
    Member

    The regression was introduced in bpo-17073.

    @malemburg malemburg changed the title sqlite modules doesn't build on 2.7.4 with Mac OS X 10.4 sqlite modules doesn't build with 2.7.4 on Mac OS X 10.4 Apr 27, 2013
    @serhiy-storchaka
    Copy link
    Member

    Here is a patch for 2.7. Please test. Should it be fixed on 3.x?

    @ned-deily
    Copy link
    Member

    The patch does solve the build problem for 2.7 on 10.4 (Tiger). The same problem exists for 3.3 and default as well. I see the Tiger buildbots aren't failing with this problem; I suspect that's because there is a newer version of libsqlite3 being supplied in /usr/local/{include,lib}, like the OS X installer builds do since the Apple-supplied version of libsqlite3 in 10.4 is the ancient 3.1.3.

    @malemburg
    Copy link
    Member Author

    On 27.04.2013 22:27, Serhiy Storchaka wrote:

    Serhiy Storchaka added the comment:

    Here is a patch for 2.7. Please test. Should it be fixed on 3.x?

    Thanks, Serhiy.

    I can confirm that the patch fixes the problem with 2.7.4 on
    Mac OS X (and probably other platforms with old sqlite libs as
    well).

    Python 3.3 is not affected by this. It uses a Python type
    for storing the values.

    @ned-deily
    Copy link
    Member

    Marc-Andre, can you elaborate on why you think Python 3 is not affected? The changes for bpo-17073 also added sqlite3_int64 to 3.2, 3.3, and default and, for me on 10.4, _sqlite3.so currently fails to build in all three. (I don't think 3.2 is worth worrying about but if Georg does spin a brown bag 3.2.5 he could cherry pick it.)

    @malemburg
    Copy link
    Member Author

    On 28.04.2013 05:20, Ned Deily wrote:

    Ned Deily added the comment:

    Marc-Andre, can you elaborate on why you think Python 3 is not affected? The changes for bpo-17073 also added sqlite3_int64 to 3.2, 3.3, and default and, for me on 10.4, _sqlite3.so currently fails to build in all three. (I don't think 3.2 is worth worrying about but if Georg does spin a brown bag 3.2.5 he could cherry pick it.)

    Oh, I just did a grep on the Python 3.3.0 code base and couldn't
    find any hits. Was the issue you mentioned applied to the 3.3.1 dot
    release ?

    If so, then those new mentions will have to be fixed as well,
    of course.

    @serhiy-storchaka serhiy-storchaka self-assigned this Apr 28, 2013
    @serhiy-storchaka
    Copy link
    Member

    Patch for bpo-14572 was applied only to 2.7 and then I backported the bug back from 3.x.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Apr 28, 2013

    New changeset 44fe1f5b07e3 by Serhiy Storchaka in branch '2.7':
    Issue bpo-17857: Prevent build failures with pre-3.5.0 versions of sqlite3,
    http://hg.python.org/cpython/rev/44fe1f5b07e3

    New changeset b677f656c0bf by Serhiy Storchaka in branch '3.3':
    Issue bpo-17857: Prevent build failures with pre-3.5.0 versions of sqlite3,
    http://hg.python.org/cpython/rev/b677f656c0bf

    New changeset 19015fc0c338 by Serhiy Storchaka in branch 'default':
    Issue bpo-17857: Prevent build failures with pre-3.5.0 versions of sqlite3,
    http://hg.python.org/cpython/rev/19015fc0c338

    @ned-deily
    Copy link
    Member

    Fix verified on OS X 10.4 for 2.7, 3.3, and default.

    @bharper
    Copy link
    Mannequin

    bharper mannequin commented Apr 29, 2013

    This issue, like 14572, is also effecting Python 2.7.4 on CentOS 5. I can confirm the patch fixes this issue on CentOS5.

    @malemburg
    Copy link
    Member Author

    Thanks, Serhiy.

    @serhiy-storchaka
    Copy link
    Member

    I think this fix should be included in the next regression release.

    @ned-deily
    Copy link
    Member

    Georg, do you want a 3.2 patch for this as well?

    @birkenfeld
    Copy link
    Member

    Would be nice, yes.

    @birkenfeld
    Copy link
    Member

    Cherry-picked to 3.2 branch.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented May 12, 2013

    New changeset d5b5116bf953 by Serhiy Storchaka in branch '3.2':
    Issue bpo-17857: Prevent build failures with pre-3.5.0 versions of sqlite3,
    http://hg.python.org/cpython/rev/d5b5116bf953

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    build The build process and cross-build extension-modules C modules in the Modules dir release-blocker stdlib Python modules in the Lib dir
    Projects
    None yet
    Development

    No branches or pull requests

    4 participants