Repository navigation
Open
Description
There is an attempt to rebuild the stripy conda package with flang 21 here: conda-forge/stripy-feedstock#25
It's failing with errors like:
[34/39] Linking target _stripack.cp310-win_amd64.pyd
FAILED: [code=1104] _stripack.cp310-win_amd64.pyd
"link" /MACHINE:x64 /OUT:_stripack.cp310-win_amd64.pyd _stripack.cp310-win_amd64.pyd.p/meson-generated_..__stripackmodule.c.obj _stripack.cp310-win_amd64.pyd.p/meson-generated_..__stripack-f2pywrappers.f.obj _stripack.cp310-win_amd64.pyd.p/src_stripack.f90.obj _stripack.cp310-win_amd64.pyd.p/D__bld_stripy_1763207111809__h_env_lib_site-packages_numpy_f2py_src_fortranobject.c.obj "/release" "/nologo" "/OPT:REF" "/DLL" "/IMPLIB:_stripack.cp310-win_amd64.lib" "-static" "-Wl,-defaultlib:D:/bld/stripy_1763207111809/_build_env/lib/clang/21/lib/windows/clang_rt.builtins-x86_64.lib" "D:\bld\stripy_1763207111809\_h_env\libs\python310.lib" "kernel32.lib" "user32.lib" "gdi32.lib" "winspool.lib" "shell32.lib" "ole32.lib" "oleaut32.lib" "uuid.lib" "comdlg32.lib" "advapi32.lib"
LINK : warning LNK4044: unrecognized option '/static'; ignored
LINK : warning LNK4044: unrecognized option '/Wl,-defaultlib:D:/bld/stripy_1763207111809/_build_env/lib/clang/21/lib/windows/clang_rt.builtins-x86_64.lib'; ignored
LINK : fatal error LNK1104: cannot open file 'flang_rt.runtime.dynamic.lib'
[35/39] Linking target _tripack.cp310-win_amd64.pyd
FAILED: [code=1104] _tripack.cp310-win_amd64.pyd
"link" /MACHINE:x64 /OUT:_tripack.cp310-win_amd64.pyd _tripack.cp310-win_amd64.pyd.p/meson-generated_..__tripackmodule.c.obj _tripack.cp310-win_amd64.pyd.p/meson-generated_..__tripack-f2pywrappers.f.obj _tripack.cp310-win_amd64.pyd.p/src_tripack.f90.obj _tripack.cp310-win_amd64.pyd.p/D__bld_stripy_1763207111809__h_env_lib_site-packages_numpy_f2py_src_fortranobject.c.obj "/release" "/nologo" "/OPT:REF" "/DLL" "/IMPLIB:_tripack.cp310-win_amd64.lib" "-static" "-Wl,-defaultlib:D:/bld/stripy_1763207111809/_build_env/lib/clang/21/lib/windows/clang_rt.builtins-x86_64.lib" "D:\bld\stripy_1763207111809\_h_env\libs\python310.lib" "kernel32.lib" "user32.lib" "gdi32.lib" "winspool.lib" "shell32.lib" "ole32.lib" "oleaut32.lib" "uuid.lib" "comdlg32.lib" "advapi32.lib"
LINK : warning LNK4044: unrecognized option '/static'; ignored
LINK : warning LNK4044: unrecognized option '/Wl,-defaultlib:D:/bld/stripy_1763207111809/_build_env/lib/clang/21/lib/windows/clang_rt.builtins-x86_64.lib'; ignored
LINK : fatal error LNK1104: cannot open file 'flang_rt.runtime.dynamic.lib'
[36/39] Compiling Fortran object _ssrfpack.cp310-win_amd64.pyd.p/src_ssrfpack.f.obj
flang: warning: argument unused during compilation: '-Wall' [-Wunused-command-line-argument]
ninja: build stopped: subcommand failed.
error: subprocess-exited-with-error
Any idea what might be going on here? Thanks.
Metadata
Metadata
Assignees
Labels
No labels
Activity
meson: only emit GNU link flags for a GNU Fortran compiler (refs #116)
brmather commentedon Jul 23, 2026
Thanks for the report. I've pushed a change on branch
numpy2-build-robustness(031477f) that makesmeson.buildonly emit the GNU/gfortran-specific link flags when the Fortran compiler actually is gfortran:That removes stripy's contribution to the noise in your log — the
LNK4044: unrecognized option '/static'; ignoredwarning came from our unconditional-static, which is a MinGW convention that MSVC'slinkdoesn't understand. (get_compiler('fortran')returns the host compiler, so gfortran cross-builds like conda-forgelinux-aarch64/osx-arm64still get the right flags.)However, I don't think this fully fixes your build. The fatal error in that log is separate from stripy:
That's flang 21's runtime library (the flang runtime was renamed to
flang_rtaround LLVM 20/21), and the-Wl,-defaultlib:...clang_rt.builtins...line is injected by the flang driver itself, not by stripy. So the remaining failure looks like a flang-21 / compiler-activation packaging issue on the feedstock side rather than something in stripy's build. Worth checking whetherflang_rtis being provided/linked correctly in conda-forge/stripy-feedstock#25.If you can retry PR #25 against this branch, it'd confirm whether removing our
-staticclears the warnings and isolates theflang_rtproblem.