Skip to content

Commit

Permalink
v3: Use LOCATION Python FIND_STRATEGY
Browse files Browse the repository at this point in the history
  • Loading branch information
mathomp4 committed Jan 2, 2025
1 parent ee49277 commit 029f713
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Deprecated

## [3.56.0] - 2025-01-03

### Changed

- Move to use Python `FIND_STRATEGY LOCATION` by default. This is needed as NAS (at least) has a very recent, but empty (no f2py) Python stack in the default path. Using `LOCATION` should limit it to the Python we want (e.g., via GEOSpyD module)

## [3.55.0] - 2024-12-02

### Fixed
Expand Down
1 change: 0 additions & 1 deletion python/esma_find_python3_module.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
# Citation: https://cmake.org/pipermail/cmake/2011-January/041666.html
# Mark Moll

set(Python3_FIND_STRATEGY VERSION)
find_package(Python3 COMPONENTS Interpreter)

function(esma_find_python3_module module)
Expand Down
5 changes: 3 additions & 2 deletions python/esma_python.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,19 @@
cmake_minimum_required(VERSION 3.24)

# Find Python
set(Python_FIND_STRATEGY LOCATION)
find_package(Python COMPONENTS Interpreter)

# Find Python2
set(Python2_FIND_STRATEGY VERSION)
set(Python2_FIND_STRATEGY LOCATION)
find_package(Python2 COMPONENTS Interpreter)
list (APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/f2py2")
include (esma_find_python2_module)
include (esma_check_python2_module)
include (esma_add_f2py2_module)

# Find Python3
set(Python3_FIND_STRATEGY VERSION)
set(Python3_FIND_STRATEGY LOCATION)
find_package(Python3 COMPONENTS Interpreter)
list (APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/f2py3")
include (esma_find_python3_module)
Expand Down

0 comments on commit 029f713

Please sign in to comment.