public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug python/23830] use the stable python 3 ABI
       [not found] <bug-23830-4717@http.sourceware.org/bugzilla/>
@ 2022-06-05 15:53 ` tromey at sourceware dot org
  2022-06-05 15:54 ` tromey at sourceware dot org
  1 sibling, 0 replies; 2+ messages in thread
From: tromey at sourceware dot org @ 2022-06-05 15:53 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=23830

--- Comment #1 from Tom Tromey <tromey at sourceware dot org> ---
I looked at this a little.

Buffer objects aren't in the stable API, see

https://github.com/python/cpython/issues/89622

PyTypeObject is opaque in the stable API, so we'd have
to change all the types to use PyType_FromSpec.

https://docs.python.org/3/c-api/type.html#c.PyType_Spec

This one doesn't seem so hard, though I didn't look to
see if everything gdb needs here is available.

There's this error:

../../binutils-gdb/gdb/python/py-gdb-readline.c:58:29: error:
‘_PyOS_ReadlineTState’ was not declared in this scope

I wonder if we could ever handle that one.  This readline stuff
was maybe a mistake.


../../binutils-gdb/gdb/python/py-gdb-readline.c:67:20: error: ‘PyMem_RawMalloc’
was not declared in this scope; did you mean ‘PyMem_Realloc’?

There seem to be other stable malloc APIs, maybe those can be used instead.


../../binutils-gdb/gdb/python/py-gdb-readline.c:97:7: error:
‘PyRun_SimpleString’ was not declared in this scope; did you mean
‘Py_CompileString’?

Would need a rewrite.


I think there more problems as well, but it's hard to see them through
all the noise of the repeated error messages.  Anyway this project
remains out of reach still.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug python/23830] use the stable python 3 ABI
       [not found] <bug-23830-4717@http.sourceware.org/bugzilla/>
  2022-06-05 15:53 ` [Bug python/23830] use the stable python 3 ABI tromey at sourceware dot org
@ 2022-06-05 15:54 ` tromey at sourceware dot org
  1 sibling, 0 replies; 2+ messages in thread
From: tromey at sourceware dot org @ 2022-06-05 15:54 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=23830

--- Comment #2 from Tom Tromey <tromey at sourceware dot org> ---
Oh, forgot to mention, we need at least 3.3 to pick up
PyArg_VaParseTupleAndKeywords.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-06-05 15:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-23830-4717@http.sourceware.org/bugzilla/>
2022-06-05 15:53 ` [Bug python/23830] use the stable python 3 ABI tromey at sourceware dot org
2022-06-05 15:54 ` tromey at sourceware dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).