Building chapi_bindings failed in AODT dev. container

Hi, community:
In development container whose cmake version==3.28.0 and Python==3.10.12, I try to build chapi_bindings.
However, When I type cmake .. -DCMAKE_BUILD_TYPE=RelWithDebInfo, the error is shown:

Then, I updated the version to Python 3.11.0rc1:

aerial@c_aodt_sim_administrator:/home/administrator/backend_bundle/aodt_sim/examples/build$ cmake .. -DCMAKE_BUILD_TYPE=RelWithDebInfo
-- Found Python: /usr/bin/python3 (found suitable version "3.11.0", minimum required is "3.11") found components: Interpreter Development Development.Module Development.Embed 
-- Project is top level.  Fetching external dependencies pybind11 and clickhouse-cpp.
-- pybind11 v2.11.1 
-- Performing Test HAS_FLTO
-- Performing Test HAS_FLTO - Success
CMake Deprecation Warning at build/_deps/clickhouse-cpp-lib-src/CMakeLists.txt:1 (CMAKE_MINIMUM_REQUIRED):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- The C compiler identification is GNU 11.4.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
absl::int128 properties:
        INCLUDE_DIRECTORIES : /home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-src/contrib/absl;/home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-src/contrib/absl
        BINARY_DIR : /home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-build/contrib/absl/absl
        INTERFACE_INCLUDE_DIRECTORIES : /home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-src/contrib/absl
        INTERFACE_LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES_ONLY_TARGETS : PROPERTY-NOTFOUND
        IMPORTED_LOCATION : PROPERTY-NOTFOUND
cityhash::cityhash properties:
        INCLUDE_DIRECTORIES : /home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-src/contrib/absl;/home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-src/contrib/lz4/lz4;/home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-src/contrib/cityhash/cityhash
        BINARY_DIR : /home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-build/contrib/cityhash/cityhash
        INTERFACE_INCLUDE_DIRECTORIES : PROPERTY-NOTFOUND
        INTERFACE_LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES_ONLY_TARGETS : PROPERTY-NOTFOUND
        IMPORTED_LOCATION : PROPERTY-NOTFOUND
lz4::lz4 properties:
        INCLUDE_DIRECTORIES : /home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-src/contrib/absl;/home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-src/contrib/lz4/lz4
        BINARY_DIR : /home/administrator/backend_bundle/aodt_sim/examples/build/_deps/clickhouse-cpp-lib-build/contrib/lz4/lz4
        INTERFACE_INCLUDE_DIRECTORIES : PROPERTY-NOTFOUND
        INTERFACE_LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES_ONLY_TARGETS : PROPERTY-NOTFOUND
        IMPORTED_LOCATION : PROPERTY-NOTFOUND
-- Configuring done (4.4s)
-- Generating done (0.0s)
-- Build files have been written to: /home/administrator/backend_bundle/aodt_sim/examples/build

and cmake --build . succeeded

However, the test failed like:

aerial@c_aodt_sim_administrator:/home/administrator/backend_bundle/aodt_sim/examples/build$ python
Python 3.11.0rc1 (main, Aug 12 2022, 10:02:14) [GCC 11.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import chapi_bindings
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: Python version mismatch: module was compiled for Python 3.10, but the interpreter version is incompatible: 3.11.0rc1 (main, Aug 12 2022, 10:02:14) [GCC 11.2.0].

Then, I changed python to 3.10 BUT error came up
ImportError: Python version mismatch: module was compiled for Python 3.10, but the interpreter version is incompatible: 3.11.0rc1 (main, Aug 12 2022, 10:02:14) [GCC 11.2.0].

I am not sure how to fix this issue. Can anyone provide suggestions?

Thank you.

@guofachang The docker container comes with the correct version of the python. We will try to recreate this and revert back to you.

@kpasad1 Thank you for your reply.

When I follow the user guide, i.e.,

cd aodt_sim
GPU=2 ./container/run_aodt_sim_devel.sh # there are 3 A6000 in the server
docker exec -it c_aodt_sim_$USER /bin/bash
SM=80
cmake -Bbuild -GNinja -DCMAKE_CUDA_ARCHITECTURES=$SM -DNVTX_ENABLED=OFF -DENABLE_CCACHE=OFF -DCMAKE_BUILD_TYPE=RelWithDebInfo

The error came up again

aerial@c_aodt_sim_administrator:/home/administrator/backend_bundle/aodt_sim$ cmake -Bbuild -GNinja -DCMAKE_CUDA_ARCHITECTURES=$SM -DNVTX_ENABLED=OFF -DENABLE_CCACHE=OFF -DCMAKE_BUILD_TYPE=RelWithDebInfo
CURRENT CMAKE_CUDA_ARCH=80
-- Found Python: /usr/bin/python3.10 (found suitable version "3.10.12", minimum required is "3.10") found components: Interpreter Development Development.Module Development.Embed 
-- Using CMAKE_BUILD_TYPE=RelWithDebInfo
CMake Deprecation Warning at external/clickhouse-cpp/CMakeLists.txt:1 (CMAKE_MINIMUM_REQUIRED):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


absl::int128 properties:
        INCLUDE_DIRECTORIES : /home/administrator/backend_bundle/aodt_sim/external/clickhouse-cpp/contrib/absl;/home/administrator/backend_bundle/aodt_sim/external/clickhouse-cpp/contrib/absl
        BINARY_DIR : /home/administrator/backend_bundle/aodt_sim/build/external/clickhouse-cpp/contrib/absl/absl
        INTERFACE_INCLUDE_DIRECTORIES : /home/administrator/backend_bundle/aodt_sim/external/clickhouse-cpp/contrib/absl
        INTERFACE_LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES_ONLY_TARGETS : PROPERTY-NOTFOUND
        IMPORTED_LOCATION : PROPERTY-NOTFOUND
cityhash::cityhash properties:
        INCLUDE_DIRECTORIES : /home/administrator/backend_bundle/aodt_sim/external/clickhouse-cpp/contrib/absl;/home/administrator/backend_bundle/aodt_sim/external/clickhouse-cpp/contrib/lz4/lz4;/home/administrator/backend_bundle/aodt_sim/external/clickhouse-cpp/contrib/cityhash/cityhash
        BINARY_DIR : /home/administrator/backend_bundle/aodt_sim/build/external/clickhouse-cpp/contrib/cityhash/cityhash
        INTERFACE_INCLUDE_DIRECTORIES : PROPERTY-NOTFOUND
        INTERFACE_LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES_ONLY_TARGETS : PROPERTY-NOTFOUND
        IMPORTED_LOCATION : PROPERTY-NOTFOUND
lz4::lz4 properties:
        INCLUDE_DIRECTORIES : /home/administrator/backend_bundle/aodt_sim/external/clickhouse-cpp/contrib/absl;/home/administrator/backend_bundle/aodt_sim/external/clickhouse-cpp/contrib/lz4/lz4
        BINARY_DIR : /home/administrator/backend_bundle/aodt_sim/build/external/clickhouse-cpp/contrib/lz4/lz4
        INTERFACE_INCLUDE_DIRECTORIES : PROPERTY-NOTFOUND
        INTERFACE_LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES : PROPERTY-NOTFOUND
        LINK_LIBRARIES_ONLY_TARGETS : PROPERTY-NOTFOUND
        IMPORTED_LOCATION : PROPERTY-NOTFOUND
-- Using pre-built emsolver /home/administrator/backend_bundle/aodt_sim/external/aerial_emsolver_api/libaerial_emsolver.so
-- Using GPU architectures 80
-- Need CCCL. Finding...
-- CPM: adding package CCCL@2.2.0 (v2.2.0)
-- Enabling pybind11 support
-- CPM: adding package pybind11@2.6.2 (v2.6.2)
CMake Deprecation Warning at build/_deps/pybind11-src/CMakeLists.txt:8 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- pybind11 v2.6.2 
-- checking python import module numpy
-- checking python import module cupy
-- Final: share
-- ... disable color and URL extended diagnostic messages
-- ....All Warnings are enabled
-- Could NOT find ZLIB (missing: ZLIB_DIR)
-- Filter PLUGIN file is /
-- ... disable color and URL extended diagnostic messages
-- ....All Warnings are enabled
-- Using toolchain ../cmake/toolchains/devkit
-- cuPHY using CMAKE_CUDA_ARCHITECTURES=80
-- including nvlog
-- Setting NVIPC_FMTLOG_ENABLE ON
CMake Deprecation Warning at external/cuBB/cuPHY/external/googletest/CMakeLists.txt:4 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Deprecation Warning at external/cuBB/cuPHY/external/googletest/googlemock/CMakeLists.txt:45 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Deprecation Warning at external/cuBB/cuPHY/external/googletest/googletest/CMakeLists.txt:56 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- Found Python: /usr/bin/python3.10 (found version "3.10.12") found components: Interpreter 
-- Failed to find LLVM FileCheck
-- git version: v0.0.0 normalized to 0.0.0
-- Google Benchmark version: 1.8.2
-- Performing Test HAVE_STD_REGEX -- success
-- Performing Test HAVE_GNU_POSIX_REGEX -- failed to compile
-- Performing Test HAVE_POSIX_REGEX -- success
-- Performing Test HAVE_STEADY_CLOCK -- success
-- Performing Test HAVE_PTHREAD_AFFINITY -- success
CMake Deprecation Warning at external/cuBB/cuPHY/external/libyaml/CMakeLists.txt:2 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- Module support is disabled.
-- Version: 9.1.0
-- Build type: RelWithDebInfo
-- CXX_STANDARD: 17
-- Required features: cxx_variadic_templates
-- Using HDF5 CXX target hdf5_cpp-shared.
CMake Error at /usr/local/share/cmake-3.28/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find Python: Found unsuitable version "3.10.12", but required is
  at least "3.11" (found /usr/bin/python3.10, found components: Interpreter
  Development Development.Module Development.Embed)
Call Stack (most recent call first):
  /usr/local/share/cmake-3.28/Modules/FindPackageHandleStandardArgs.cmake:598 (_FPHSA_FAILURE_MESSAGE)
  /usr/local/share/cmake-3.28/Modules/FindPython/Support.cmake:3867 (find_package_handle_standard_args)
  /usr/local/share/cmake-3.28/Modules/FindPython.cmake:574 (include)
  examples/CMakeLists.txt:14 (find_package)

I fixed it by modifying the package requirement in the path examples/CMakeLists.txt

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.