python3: Fix cross compilation to FreeBSD

- autoreconf needs to be run if we patch configure.ac
- the patch lines need to be adjusted otherwise it applies wrong
This commit is contained in:
Audrey Dutcher
2025-12-06 15:51:49 -07:00
parent a937d80b7c
commit 5f12790a4c
2 changed files with 12 additions and 6 deletions
@@ -208,10 +208,16 @@ let
nativeBuildInputs = [
nukeReferences
]
++ optionals (!stdenv.hostPlatform.isDarwin && !withMinimalDeps) [
autoconf-archive # needed for AX_CHECK_COMPILE_FLAG
autoreconfHook
]
++
optionals
(
(!stdenv.hostPlatform.isDarwin && !withMinimalDeps)
|| (stdenv.hostPlatform != stdenv.buildPlatform && stdenv.hostPlatform.isFreeBSD)
)
[
autoconf-archive # needed for AX_CHECK_COMPILE_FLAG
autoreconfHook
]
++
optionals ((!stdenv.hostPlatform.isDarwin || passthru.pythonAtLeast "3.14") && !withMinimalDeps)
[