Support for ecbuild v3.4. Fix AEC, maths library and Python/Numpy

This commit is contained in:
Shahram Najm 2020-08-19 16:08:07 +01:00
parent 9e7aa5e518
commit 455e39da46
2 changed files with 6 additions and 4 deletions

View File

@ -125,12 +125,11 @@ ecbuild_add_option( FEATURE AEC
ecbuild_find_python( VERSION 2.6 NO_LIBS )
find_package( NumPy )
message(STATUS "..............Python_FOUND=${PYTHON_FOUND} and NumPy_FOUND=${NUMPY_FOUND}")
ecbuild_add_option( FEATURE PYTHON
DESCRIPTION "Build the ecCodes Python2 interface (deprecated)"
DEFAULT OFF
#REQUIRED_PACKAGES "Python VERSION 2.6 NO_LIBS" NumPy
CONDITION Python_FOUND AND NumPy_FOUND
#CONDITION Python_FOUND AND NumPy_FOUND
CONDITION PYTHON_FOUND AND NUMPY_FOUND
)
# For Python2 we build our own bindings (using SWIG) in the build directory
# but for Python3 one has to add the eccodes from pip3 AFTER the install

View File

@ -440,7 +440,10 @@ ecbuild_add_library( TARGET eccodes
# griby.c gribl.c
${grib_api_srcs}
GENERATED grib_api_version.c
PRIVATE_LIBS ${ECCODES_EXTRA_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${CMATH_LIBRARIES}
#PRIVATE_LIBS ${ECCODES_EXTRA_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${CMATH_LIBRARIES}
PRIVATE_INCLUDES "${AEC_INCLUDE_DIRS}"
PRIVATE_LIBS ${ECCODES_EXTRA_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${AEC_LIBRARIES}
PUBLIC_LIBS ${CMATH_LIBRARIES}
TEMPLATES ${grib_api_extra_srcs}
INSTALL_HEADERS_LIST
grib_api.h