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

Fix path to FindFFTW.cmake when using KokkosFFT as subdirectory #102

Merged
merged 1 commit into from
Jun 18, 2024

Conversation

kamilrakoczy
Copy link
Contributor

When KokkosFFT is used as a subdirectory, CMAKE_SOURCE_DIR points to top level of the current CMake source tree. CMAKE_CURRENT_SOURCE_DIR points to the source directory that is currently being processed by cmake.

Example error when installing project that is using KokkosFFT before this fix:

CMake Error at src/gpl2/kokkos-fft/cmake_install.cmake:107 (file):
  file INSTALL cannot find
  "project-name/cmake/FindFFTW.cmake":
  No such file or directory.
Call Stack (most recent call first):
  src/gpl2/cmake_install.cmake:47 (include)
  src/cmake_install.cmake:87 (include)
  cmake_install.cmake:52 (include)

When KokkosFFT is used as a subdirectory, CMAKE_SOURCE_DIR points to top
level of the current CMake source tree. CMAKE_CURRENT_SOURCE_DIR points
to the source directory that is currently being processed by cmake.

Signed-off-by: Kamil Rakoczy <[email protected]>
@yasahi-hpc
Copy link
Collaborator

Thank you for this PR. We did not notice this.

@yasahi-hpc yasahi-hpc merged commit 6b2ccb2 into kokkos:main Jun 18, 2024
19 checks passed
@kamilrakoczy kamilrakoczy deleted the fix-fftw-install-path branch June 19, 2024 10:01
@yasahi-hpc yasahi-hpc added the bug Something isn't working label Jul 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants