Skip to content

Commit

Permalink
Provide nice error message when given a bad override filepath
Browse files Browse the repository at this point in the history
  • Loading branch information
robertmaynard committed Sep 8, 2021
1 parent eb2c995 commit 785e41f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions rapids-cmake/cpm/package_override.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ version will be used.
function(rapids_cpm_package_override filepath)
list(APPEND CMAKE_MESSAGE_CONTEXT "rapids.cpm.rapids_cpm_package_override")

if(NOT EXISTS "${filepath}")
message(FATAL_ERROR "rapids_cpm_package_override asked to load "${filepath}" but it doesn't exist")
endif()
file(READ "${filepath}" json_data)

# Determine all the projects that exist in the json file
Expand Down

0 comments on commit 785e41f

Please sign in to comment.