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

Make THRUST_DEVICE_SYSTEM and THRUST_CPP_DIALECT independent of THRUST_HOST_SYSTEM #3659

Merged
merged 3 commits into from
Feb 5, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions thrust/cmake/ThrustMultiConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -107,21 +107,26 @@ function(thrust_configure_multiconfig)
# from a previous run.
if (DEFINED THRUST_HOST_SYSTEM)
set_property(CACHE THRUST_HOST_SYSTEM PROPERTY TYPE STRING)
set_property(CACHE THRUST_DEVICE_SYSTEM PROPERTY TYPE STRING)
set_property(CACHE THRUST_CPP_DIALECT PROPERTY TYPE STRING)
else()
set(THRUST_HOST_SYSTEM "CPP" CACHE STRING "The targeted host system: ${THRUST_HOST_SYSTEM_OPTIONS}")
set(THRUST_DEVICE_SYSTEM "CUDA" CACHE STRING "The targeted device system: ${THRUST_DEVICE_SYSTEM_OPTIONS}")
set(THRUST_CPP_DIALECT 17 CACHE STRING "The C++ standard to target: ${THRUST_CPP_DIALECT_OPTIONS}")

set_property(CACHE THRUST_HOST_SYSTEM
PROPERTY STRINGS
${THRUST_HOST_SYSTEM_OPTIONS}
)
endif()
if (DEFINED THRUST_DEVICE_SYSTEM)
set_property(CACHE THRUST_DEVICE_SYSTEM PROPERTY TYPE STRING)
else()
set(THRUST_DEVICE_SYSTEM "CUDA" CACHE STRING "The targeted device system: ${THRUST_DEVICE_SYSTEM_OPTIONS}")
set_property(CACHE THRUST_DEVICE_SYSTEM
PROPERTY STRINGS
${THRUST_DEVICE_SYSTEM_OPTIONS}
)
endif()
if (DEFINED THRUST_CPP_DIALECT)
set_property(CACHE THRUST_CPP_DIALECT PROPERTY TYPE STRING)
else()
set(THRUST_CPP_DIALECT 17 CACHE STRING "The C++ standard to target: ${THRUST_CPP_DIALECT_OPTIONS}")
set_property(CACHE THRUST_CPP_DIALECT
PROPERTY STRINGS
${THRUST_CPP_DIALECT_OPTIONS}
Expand Down
Loading