summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/FindMatlab/RunCMakeTest.cmake
diff options
context:
space:
mode:
authorRaffi Enficiaud <raffi.enficiaud@mines-paris.org>2017-04-29 18:31:58 (GMT)
committerBrad King <brad.king@kitware.com>2018-04-23 14:30:49 (GMT)
commit59fb9e89b2bd09a2edd5bbaecb01f43d6f3a2a7e (patch)
tree05897534fca0be23f67df31938a4c237a51f4c98 /Tests/RunCMake/FindMatlab/RunCMakeTest.cmake
parentccd17a557cbf8ada18207a72eea78d2adcc9d752 (diff)
downloadCMake-59fb9e89b2bd09a2edd5bbaecb01f43d6f3a2a7e.zip
CMake-59fb9e89b2bd09a2edd5bbaecb01f43d6f3a2a7e.tar.gz
CMake-59fb9e89b2bd09a2edd5bbaecb01f43d6f3a2a7e.tar.bz2
FindMatlab: Matlab Runtime Compiler support
* Determining automatically the MCR version on OSX and Windows * Distinguishing between MCR and Matlab * Specific tests for the MCR * mexext on windows does not work properly: the mexext is hardcoded * Doc updates for the MCR Fixes: #16487
Diffstat (limited to 'Tests/RunCMake/FindMatlab/RunCMakeTest.cmake')
-rw-r--r--Tests/RunCMake/FindMatlab/RunCMakeTest.cmake11
1 files changed, 11 insertions, 0 deletions
diff --git a/Tests/RunCMake/FindMatlab/RunCMakeTest.cmake b/Tests/RunCMake/FindMatlab/RunCMakeTest.cmake
index f0eb6b4..deebf89 100644
--- a/Tests/RunCMake/FindMatlab/RunCMakeTest.cmake
+++ b/Tests/RunCMake/FindMatlab/RunCMakeTest.cmake
@@ -1,5 +1,13 @@
include(RunCMake)
+
+
+if(NOT "${MCR_ROOT}" STREQUAL "")
+ if(NOT EXISTS "${MCR_ROOT}")
+ message(FATAL_ERROR "MCR does not exist ${MCR_ROOT}")
+ endif()
+ set(RunCMake_TEST_OPTIONS "-Dmatlab_root=${MCR_ROOT}")
+endif()
run_cmake(MatlabTest1)
if(RunCMake_GENERATOR MATCHES "Make" AND UNIX)
@@ -11,6 +19,9 @@ if(RunCMake_GENERATOR MATCHES "Make" AND UNIX)
message(STATUS "RerunFindMatlab: first configuration to extract real Matlab_ROOT_DIR")
set(RunCMake_TEST_OPTIONS "-Dmatlab_required=REQUIRED")
+ if(NOT "${MCR_ROOT}" STREQUAL "")
+ set(RunCMake_TEST_OPTIONS ${RunCMake_TEST_OPTIONS} "-Dmatlab_root=${MCR_ROOT}")
+ endif()
run_cmake(MatlabTest2)
message(STATUS "RerunFindMatlab: flushing the variables")