Created attachment 1435151 [details] Build log of gdb building against python 3.7 Description of problem: When I try to bootsrap gdb / python 3.7, it fails to build with 3.7. Version-Release number of selected component (if applicable): 8.1-15.fc29 Steps to Reproduce: 1. Build gdb --without python 2. Build python3 3.7 https://src.fedoraproject.org/fork/churchyard/rpms/python3/tree/master37 3. Build gdb --with python Actual results: BUILDSTDERR: ../../gdb/python/python.c: In function 'bool do_start_initialization()': BUILDSTDERR: ../../gdb/python/python.c:1853:45: error: too few arguments to function 'int _PyImport_FixupBuiltin(PyObject*, const char*, PyObject*)' BUILDSTDERR: _PyImport_FixupBuiltin (gdb_module, "_gdb"); BUILDSTDERR: ^ BUILDSTDERR: In file included from /usr/include/python3.7m/Python.h:126, BUILDSTDERR: from ../../gdb/python/python-internal.h:100, BUILDSTDERR: from ../../gdb/python/python.c:94: BUILDSTDERR: /usr/include/python3.7m/import.h:113:17: note: declared here BUILDSTDERR: PyAPI_FUNC(int) _PyImport_FixupBuiltin( BUILDSTDERR: ^~~~~~~~~~~~~~~~~~~~~~ BUILDSTDERR: make[2]: *** [Makefile:1621: python/python.o] Error 1 BUILDSTDERR: make[2]: *** Waiting for unfinished jobs.... make[2]: Leaving directory '/builddir/build/BUILD/gdb-8.1/build-x86_64-redhat-linux-gnu/gdb' BUILDSTDERR: make[1]: *** [Makefile:8157: all-gdb] Error 2 make[1]: Leaving directory '/builddir/build/BUILD/gdb-8.1/build-x86_64-redhat-linux-gnu' BUILDSTDERR: make: *** [Makefile:850: all] Error 2 Expected results: Should build. Build log attached.
https://github.com/python/cpython/pull/1638 https://github.com/python/cpython/pull/3565 https://github.com/python/cpython/pull/3575 CC'ing Victor who was one of the reviewers.
https://bugs.python.org/issue33470 Adding this as a cross reference. Hopefully we can find out what is changed, and the reasons why, and we can create a fix for upstream as well as downstream GDB.
> BUILDSTDERR: ../../gdb/python/python.c:1853:45: error: too few arguments to function 'int _PyImport_FixupBuiltin(PyObject*, const char*, PyObject*)' This is a private API, gdb should not use it. I don't know why gdb chose to call a private function. To fix gdb, an #ifdef using PY_VERSION_HEX should be use to pass one more additional parameter to Python 3.7: "modules". This parameter can be found in interp->modules, where interp is the current interpreter. For example, use PyThreadState_Get()->interp to get the current interpreter.
Phil?
I've brought the issue up with upstream. I don't understand the purpose of the existing GDB code and so I've asked upstream for a resolution. https://sourceware.org/ml/gdb/2018-05/msg00027.html I'll monitor it and update this bug as the situation evolves.
A patch has been posted upstream: https://sourceware.org/ml/gdb-patches/2018-05/msg00863.html
Any news on that? 3.7.0c1 is expected in 3 days (2018-06-11, [1]). I'd like to start building stuff in a side tag soon after that. [1] https://www.python.org/dev/peps/pep-0537/
A patch has been submitted upstream, approved by the moderators, but it is not currently (as of an hour ago) checked in. Sergio may be able to carry the patch temporarily in the GDB rpm until upstream GDB propagates out.
(In reply to Miro Hrončok from comment #7) > Any news on that? 3.7.0c1 is expected in 3 days (2018-06-11, [1]). I'd like > to start building stuff in a side tag soon after that. > > > [1] https://www.python.org/dev/peps/pep-0537/ I will make a release of Fedora GDB on Rawhide containing the patch later today.
Thanks.
This issue was tracked in https://sourceware.org/bugzilla/show_bug.cgi?id=23252 I just committed the patch and closed that gdb bug report.
Fixed in gdb-8.1.50.20180605-18.fc29.
Thank you. Will retest and reopen if it doesn't work.
As this bugzilla is somewhat popular with spammers, I've checked the "(never email me about this bug)" checkbox. If anybody actually has something to say here, please open a new bugzilla instead of reopening this one.
Situs https://healthytuna.com/ bandar togel online terpercaya berlisensi internasional menyediakan hadiah togel jackpot 4d 10 juta dengan layanan daftar togel 10rb via dana, ovo, gopay, linkaja.
It’s great to see the resolution of Bug 1577396 and the improvements in gdb with Fedora. Keeping software up to date is crucial for performance and security. Speaking of engaging experiences, have you tried Block Blast? It’s a fun game that challenges your strategic thinking while you wait for updates like this. Let's continue to share updates and resources here! https://block-blast.online/