ECP-copa / Cabana

Performance-portable library for particle-based simulations
Other
216 stars 50 forks source link

Installing Cabana cannot find libkokkoscore.a #625

Closed dineshadepu closed 1 year ago

dineshadepu commented 1 year ago

Hi all,

I am trying to install Cabana, and implement discrete element method. I am running into installation issues. I have done the following.


----ThisIsLaptop ThisIsLaptop ThisIsLaptop ----------------------------------
  laptop laptop laptop (master) /home/dinesh/phd/code_post_doc/kokkos/build $  
|  LAPTOP LAPTOP=> cmake \
>       -D CMAKE_BUILD_TYPE="Release" \
>       -D CMAKE_INSTALL_PREFIX=$KOKKOS_INSTALL_DIR \
>       -D Kokkos_ENABLE_OPENMP=ON \
>       -D Kokkos_ENABLE_SERIAL=ON \
>       .. ;
-- Setting default Kokkos CXX standard to 17
-- The CXX compiler identification is GNU 8.4.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- The project name is: Kokkos
-- Using internal gtest for testing
-- Configured git information in /home/dinesh/phd/code_post_doc/kokkos/build/generated/Kokkos_Version_Info.cpp
-- Using -std=gnu++17 for C++17 extensions as feature
-- Built-in Execution Spaces:
--     Device Parallel: NoTypeDefined
--     Host Parallel: Kokkos::OpenMP
--       Host Serial: SERIAL
-- 
-- Architectures:
-- Found TPLLIBDL: /usr/include  
-- Found OpenMP_CXX: -fopenmp (found version "4.5") 
-- Found OpenMP: TRUE (found version "4.5")  
-- Using internal desul_atomics copy
-- Kokkos Devices: OPENMP;SERIAL, Kokkos Backends: OPENMP;SERIAL
-- Configuring done
-- Generating done
-- Build files have been written to: /home/dinesh/phd/code_post_doc/kokkos/build

 ----ThisIsLaptop ThisIsLaptop ThisIsLaptop ----------------------------------
  laptop laptop laptop (master) /home/dinesh/phd/code_post_doc/kokkos/build $  
|  LAPTOP LAPTOP=> make install
[  0%] Built target AlwaysCheckGit
[  3%] Building CXX object CMakeFiles/impl_git_version.dir/generated/Kokkos_Version_Info.cpp.o
[  6%] Linking CXX static library libimpl_git_version.a
[  6%] Built target impl_git_version
[ 10%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_CPUDiscovery.cpp.o
[ 13%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_Command_Line_Parsing.cpp.o
[ 17%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_Core.cpp.o
[ 20%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_Error.cpp.o
[ 24%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_ExecPolicy.cpp.o
[ 27%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_HostBarrier.cpp.o
[ 31%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_HostSpace.cpp.o
[ 34%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_HostSpace_deepcopy.cpp.o
[ 37%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_HostThreadTeam.cpp.o
[ 41%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_MemoryPool.cpp.o
[ 44%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_MemorySpace.cpp.o
[ 48%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_Profiling.cpp.o
[ 51%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_SharedAlloc.cpp.o
[ 55%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_Spinwait.cpp.o
[ 58%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_Stacktrace.cpp.o
[ 62%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/impl/Kokkos_hwloc.cpp.o
[ 65%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/OpenMP/Kokkos_OpenMP_Instance.cpp.o
[ 68%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/OpenMP/Kokkos_OpenMP_Task.cpp.o
[ 72%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/Serial/Kokkos_Serial.cpp.o
[ 75%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/Serial/Kokkos_Serial_Task.cpp.o
[ 79%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/__/__/tpls/desul/src/Lock_Array_CUDA.cpp.o
[ 82%] Building CXX object core/src/CMakeFiles/kokkoscore.dir/__/__/tpls/desul/src/Lock_Array_HIP.cpp.o
[ 86%] Linking CXX static library libkokkoscore.a
[ 86%] Built target kokkoscore
[ 89%] Building CXX object containers/src/CMakeFiles/kokkoscontainers.dir/impl/Kokkos_UnorderedMap_impl.cpp.o
[ 93%] Linking CXX static library libkokkoscontainers.a
[ 93%] Built target kokkoscontainers
[ 96%] Building CXX object simd/src/CMakeFiles/kokkossimd.dir/Kokkos_SIMD_dummy.cpp.o
[100%] Linking CXX static library libkokkossimd.a
[100%] Built target kokkossimd
Install the project...
-- Install configuration: "Release"
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/Kokkos_Parallel_Reduce.hpp
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/Kokkos_Macros.hpp
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/View
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/View/Hooks
================================================================================
================================================================================
Removed for readability
================================================================================
================================================================================
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/KokkosCore_config.h
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/bin/nvcc_wrapper
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/bin/hpcbind
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/bin/kokkos_launch_compiler
-- Up-to-date: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/KokkosCore_config.h
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/KokkosCore_Config_FwdBackend.hpp
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/KokkosCore_Config_SetupBackend.hpp
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/KokkosCore_Config_DeclareBackend.hpp
-- Installing: /home/dinesh/phd/code_post_doc/kokkos/build/kokkos/build/install/include/KokkosCore_Config_PostInclude.hpp

Then I tried installing Cabana with the following


----ThisIsLaptop ThisIsLaptop ThisIsLaptop ----------------------------------
  laptop laptop laptop (master) /home/dinesh/phd/code_post_doc/Cabana/build $  
|  LAPTOP LAPTOP=> cmake \
>       -D CMAKE_BUILD_TYPE="Debug" \
>       -D CMAKE_PREFIX_PATH=$KOKKOS_INSTALL_DIR \
>       -D CMAKE_INSTALL_PREFIX=$CABANA_INSTALL_DIR \
>       -D Cabana_REQUIRE_OPENMP=ON \
>       -D Cabana_ENABLE_EXAMPLES=ON \
>       -D Cabana_ENABLE_TESTING=ON \
>       -D Cabana_ENABLE_PERFORMANCE_TESTING=OFF \
>       -D Cabana_ENABLE_CAJITA=ON \
>       .. ;
-- The CXX compiler identification is GNU 8.4.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found OpenMP_CXX: -fopenmp (found version "4.5") 
-- Found OpenMP: TRUE (found version "4.5")  
CMake Error at /lib/cmake/Kokkos/KokkosTargets.cmake:136 (message):
  The imported target "Kokkos::kokkoscore" references the file

     "/lib/libkokkoscore.a"

  but this file does not exist.  Possible reasons include:

  * The file was deleted, renamed, or moved to another location.

  * An install or uninstall procedure did not complete successfully.

  * The installation package was faulty and contained

     "/lib/cmake/Kokkos/KokkosTargets.cmake"

  but not all the files it references.

Call Stack (most recent call first):
  /lib/cmake/Kokkos/KokkosConfig.cmake:52 (INCLUDE)
  CMakeLists.txt:39 (find_package)

-- Configuring incomplete, errors occurred!
See also "/home/dinesh/phd/code_post_doc/Cabana/build/CMakeFiles/CMakeOutput.log".

Many thanks for your help.

dalg24 commented 1 year ago

Did you check whether the file exists? (ls /lib/libkokkoscore.a)

dineshadepu commented 1 year ago

I have tried few more times and was able to install it succesfully. Thank you :) @dalg24