CExA-project / ddc

DDC is a discrete domain computation library.
https://ddc.mdls.fr
Other
33 stars 5 forks source link

Add missing dependencies on installed DDC #665

Closed tpadioleau closed 3 weeks ago

tpadioleau commented 1 month ago

It seems to be working but could be further improved in future PR.

add_executable(main main.cpp) target_link_libraries(main PRIVATE DDC::DDC)

if(DDC_BUILD_PDI_WRAPPER) target_link_libraries(main PRIVATE DDC::PDI_Wrapper) endif()


but as soon as a user requires an option this looks bad
```cmake
find_package(DDC REQUIRED)

if(NOT DDC_BUILD_KERNELS_FFT)
    message(FATAL_ERROR "Expecting DDC_BUILD_KERNELS_FFT=ON")
endif()
yasahi-hpc commented 3 weeks ago

If you added install_test, should you also apply format check to that directory?

https://github.com/CExA-project/ddc/blob/579427b92e6246a5c4e67a4bc16747e9f2624a96/.github/workflows/tests.yml#L19

tpadioleau commented 3 weeks ago

If you added install_test, should you also apply format check to that directory?

https://github.com/CExA-project/ddc/blob/579427b92e6246a5c4e67a4bc16747e9f2624a96/.github/workflows/tests.yml#L19

Indeed good catch