From: Paul Zander <negril.nx+gentoo@gmail.com>
Date: Fri, 23 Aug 2024 13:19:21 +0200
Subject: [PATCH] fix numpy lookup

use cmake config for find_package()

Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com>

--- a/build_files/cmake/platform/platform_unix.cmake
+++ b/build_files/cmake/platform/platform_unix.cmake
@@ -463,13 +463,13 @@ if(WITH_BOOST)
     endif()
     list(APPEND __boost_packages system)
     set(Boost_NO_WARN_NEW_VERSIONS ON)
-    find_package(Boost 1.48 COMPONENTS ${__boost_packages})
+    find_package(Boost 1.48 CONFIG COMPONENTS ${__boost_packages})
     if(NOT Boost_FOUND)
       # try to find non-multithreaded if -mt not found, this flag
       # doesn't matter for us, it has nothing to do with thread
       # safety, but keep it to not disturb build setups
       set(Boost_USE_MULTITHREADED OFF)
-      find_package(Boost 1.48 COMPONENTS ${__boost_packages})
+      find_package(Boost 1.48 CONFIG COMPONENTS ${__boost_packages})
     endif()
     unset(__boost_packages)
     if(Boost_USE_STATIC_LIBS AND WITH_BOOST_ICU)
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2499,7 +2499,7 @@ if(WITH_PYTHON)
     # Always use numpy bundled in precompiled libs.
   elseif((WITH_PYTHON_INSTALL AND WITH_PYTHON_INSTALL_NUMPY) OR WITH_PYTHON_NUMPY)
     if(("${PYTHON_NUMPY_PATH}" STREQUAL "") OR (${PYTHON_NUMPY_PATH} MATCHES NOTFOUND))
-      find_python_package(numpy "core/include")
+      find_python_package(numpy "_core/include")
     endif()
   endif()
 
