Skip to content

v3: Fixes to allow for odd Python setups and f2py#427

Merged
mathomp4 merged 7 commits intorelease/v3from
feature/mathomp4/v3-fix-f2py-detect
Mar 18, 2025
Merged

v3: Fixes to allow for odd Python setups and f2py#427
mathomp4 merged 7 commits intorelease/v3from
feature/mathomp4/v3-fix-f2py-detect

Conversation

@mathomp4
Copy link
Copy Markdown
Member

@mathomp4 mathomp4 commented Feb 19, 2025

This PR to v3 is an attempt to let f2py work in odd scenarios where perhaps more than one Python stack is in the PATH. In some cases, this is expected (Spack) but in other cases, it is an unsupported way forward (two different Miniforge stacks of different Python vintage).

First, we look for bare f2py first as systems like Spack only install that.

Second, we look to see if the Python executable is the same path as the f2py found. If not, we add a WARNING to the CMake output. We cannot FATAL_ERROR because of things like Spack.

This is about as good as we can do.

We also add an ugly hack for f2py on macOS with AppleClang because meson and CC and I don't know anymore.

@mathomp4 mathomp4 added the 0 diff The changes in this pull request have verified to be zero-diff with the target branch. label Feb 19, 2025
@mathomp4 mathomp4 self-assigned this Feb 19, 2025
@mathomp4 mathomp4 requested a review from a team as a code owner February 19, 2025 13:46
@mathomp4 mathomp4 marked this pull request as draft February 19, 2025 16:15
@mathomp4 mathomp4 marked this pull request as ready for review March 18, 2025 14:04
@mathomp4 mathomp4 merged commit a2986c2 into release/v3 Mar 18, 2025
13 checks passed
@mathomp4 mathomp4 deleted the feature/mathomp4/v3-fix-f2py-detect branch March 18, 2025 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

0 diff The changes in this pull request have verified to be zero-diff with the target branch.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant