Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could NOT find Python3 (missing: Python3_NumPy_INCLUDE_DIR NumPy) (found version "3.7.4") #22

Open
cnwangfeng opened this issue Sep 5, 2019 · 1 comment

Comments

@cnwangfeng
Copy link

I use Anaconda 2019.07 as python environment. Cmake version is 3.15.3.
When I try to install with "brew install casacore", it reports "Could NOT find Python3 (missing: Python3_NumPy_INCLUDE_DIR NumPy) (found
version "3.7.4")"

Thanks.

Feng

(base) fwang-lt:Modules wangfeng$ brew install casacore
Updating Homebrew...
==> Auto-updated Homebrew!
Updated 1 tap (homebrew/core).
==> Updated Formulae
zim

==> Installing casacore from ska-sa/tap
==> Downloading https://github.com/casacore/casacore/archive/v3.1.1.tar.gz
Already downloaded: /Users/wangfeng/Library/Caches/Homebrew/downloads/3b570ca11953847e1fc2a5b18bc8e9593f9ee563b6aa9a505cb07298fc46514b--casacore-3.1.1.tar.gz
==> Patching
patching file python/CMakeLists-cmake3.12.txt
patching file python3/CMakeLists-cmake3.12.txt
patching file python/Converters/test/CMakeLists.txt
==> cmake ../.. -DCMAKE_C_FLAGS_RELEASE=-DNDEBUG -DCMAKE_CXX_FLAGS_RELEASE=-DNDEBUG -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/cas
Last 15 lines from /Users/wangfeng/Library/Logs/Homebrew/casacore/01.cmake:
-- Looking for python3 specific environment...
CMake Error at /usr/local/Cellar/cmake/3.15.3/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
Could NOT find Python3 (missing: Python3_NumPy_INCLUDE_DIR NumPy) (found
version "3.7.4")
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.15.3/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
/usr/local/Cellar/cmake/3.15.3/share/cmake/Modules/FindPython/Support.cmake:1653 (find_package_handle_standard_args)
/usr/local/Cellar/cmake/3.15.3/share/cmake/Modules/FindPython3.cmake:215 (include)
python3/CMakeLists-cmake3.12.txt:3 (find_package)
python3/CMakeLists.txt:4 (include)

@cnwangfeng
Copy link
Author

I finally find a method. It can work but obviously it's not a solution.

  1. I have to add a line to "casacore.rb"
    cmake_args << "-DPython2_NumPy_INCLUDE_DIR=#{HOMEBREW_PREFIX}/Cellar/numpy/1.16.4_1/lib/python2.7/site-packages/numpy/core/include/"

  2. After the modification of the casacore.rb, another problem regarding boost-python would be reported. I finally modified /usr/localCellar/cmake/3.15.3/share/cmake/Modules/FindBoost.cmake and set Boost_NO_BOOST_CMAKE with ON.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant