#68265 closed defect (fixed)
py311-gnureadline @8.1.2: build failure
Reported by: | MaddTheSane (C.W. Betts) | Owned by: | stromnov (Andrey Stromnov) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.8.1 |
Keywords: | Cc: | wyuenho (Jimmy Yuen Ho Wong) | |
Port: | py-gnureadline |
Description
Another port that seems to be broken for Sonoma, on Apple Silicon
Log will be added.
Attachments (1)
Change History (11)
Changed 8 months ago by MaddTheSane (C.W. Betts)
comment:1 follow-up: 5 Changed 8 months ago by jmroot (Joshua Root)
Cc: | stromnov removed |
---|---|
Keywords: | sonoma removed |
Owner: | set to stromnov |
Port: | py-gnureadline added; py311-gnureadline removed |
Status: | new → assigned |
Looks like https://github.com/python/cpython/issues/109191, which is unexpected because that implies this is building against libedit headers instead of its own GNU readline headers.
comment:2 Changed 8 months ago by reneeotten (Renee Otten)
Cc: | wyuenho added |
---|
comment:4 Changed 8 months ago by wyuenho (Jimmy Yuen Ho Wong)
Keywords: | sonama arm64 added |
---|
comment:5 Changed 8 months ago by markmentovai (Mark Mentovai)
Replying to jmroot:
Looks like https://github.com/python/cpython/issues/109191, which is unexpected because that implies this is building against libedit headers instead of its own GNU readline headers.
gnureadline’s Modules/3.x/readline.c has this:
#ifdef WITH_EDITLINE # include <editline/readline.h> #else /* GNU readline definitions */ # undef HAVE_CONFIG_H /* Else readline/chardefs.h includes strings.h */ # include <readline/readline.h> # include <readline/history.h> #endif
The problem is that earlier in the same file, there’s
#include "Python.h"
"Python.h"
is resolved as ${prefix}/Library/Frameworks/Python.framework/Versions/3.11/include/python3.11/Python.h
; it #includes "pyconfig.h"
from the same directory, and that file contains:
/* Define to build the readline module against Editline. */ #define WITH_EDITLINE 1
This, of course, refers to Python’s own built-in readline
module, and should not be effective during the build of py-gnureadline, which is expecting and has configured itself to use its own embedded copy of GNU readline.
As a fix, I think we can just remove (or replace with #if 0
) that WITH_EDITLINE
branch.
comment:6 Changed 8 months ago by markmentovai (Mark Mentovai)
comment:7 Changed 8 months ago by jmroot (Joshua Root)
Keywords: | sonama arm64 removed |
---|
comment:8 Changed 8 months ago by Mark Mentovai <mark@…>
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
comment:9 Changed 8 months ago by jmroot (Joshua Root)
I guess this should be upstreamed as well, though they may want a fix that won't be wiped out when they import the latest readline module code from cpython core.
comment:10 Changed 8 months ago by markmentovai (Mark Mentovai)
Yes, I am attempting to upstream it at https://github.com/ludwigschwardt/python-gnureadline/pull/64.
Build log