Re: python311 vs expat
Thomas Klausner <[email protected]> Fri, 20 Mar 2026 09:43:13 +0100
| Newsgroups | gmane.os.netbsd.devel.packages |
|---|---|
| Message-ID | <[email protected]> |
On Fri, Mar 20, 2026 at 07:22:12AM +0100, Adam CiarciĆski wrote: > > This change broke both macOS and SunOS: > > > > bac7175966909 (adam 2026-03-04 06:51:45 +0000 44) CONFIGURE_ARGS+= --without-system-expat # requires expat_config.h > > > > It means that python311 has both: > > > > CONFIGURE_ARGS+= --with-system-expat > > CONFIGURE_ARGS+= --without-system-expat # requires expat_config.h > > > > I don't understand how this can work. Does this even work on NetBSD? > > > > I think it's clearly a regression on any other system, so if this is a NetBSD-specific hack then it needs to go in an .if OPSYS section, and I'd recommend a very good comment explaining why we have both --with and --without because that makes no sense to me. > > The problem is, not every operating system provides 'expat_config.h', but pkgsrc thinks the external expat is fine. I just tried building after providing an empty expat_config.h, and it built fine. So either provide that (manually for this package, or from the expat/buildlink3.mk file), or just remove the include from Modules/pyexpat.c - I don't see it using anything from that header (the '#if's in it only check XML_COMBINED_VERSION, which is not provided by that header anyway). Thomas