diff options
Diffstat (limited to 'Tests/FindRuby/Rvm/RvmDefault.cmake')
-rw-r--r-- | Tests/FindRuby/Rvm/RvmDefault.cmake | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Tests/FindRuby/Rvm/RvmDefault.cmake b/Tests/FindRuby/Rvm/RvmDefault.cmake new file mode 100644 index 0000000..a66b911 --- /dev/null +++ b/Tests/FindRuby/Rvm/RvmDefault.cmake @@ -0,0 +1,17 @@ +set(CMAKE_FIND_LIBRARY_PREFIXES "") +set(CMAKE_FIND_LIBRARY_SUFFIXES "") + +find_package (Ruby 2.1.1 REQUIRED) +if (NOT RUBY_EXECUTABLE MATCHES "^${RUBY_HOME}/.+") + message (FATAL_ERROR "Failed to use RVM environment: ${RUBY_EXECUTABLE}, ${RUBY_HOME}") +endif() + +find_package (Ruby 2.1 REQUIRED) +if (NOT RUBY_EXECUTABLE MATCHES "^${RUBY_HOME}/.+") + message (FATAL_ERROR "Failed to use RVM environment: ${RUBY_EXECUTABLE}, ${RUBY_HOME}") +endif() + +find_package (Ruby REQUIRED) +if (NOT RUBY_EXECUTABLE MATCHES "^${RUBY_HOME}/.+") + message (FATAL_ERROR "Failed to use RVM environment: ${RUBY_EXECUTABLE}, ${RUBY_HOME}") +endif() |