From c35fd55b0e472311152040fd9700fe360ccc93c4 Mon Sep 17 00:00:00 2001 From: Rok Mandeljc Date: Mon, 28 Apr 2014 13:42:27 +0200 Subject: [PATCH] Matlab bindings: CMakeLists.txt: use "${LIBRARY_OUTPUT_PATH}/${CMAKE_CFG_INTDIR}" as MEX_LIB_DIR only when compiling with MSVC, otherwise, use only "${LIBRARY_OUTPUT_PATH}" --- modules/matlab/CMakeLists.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/modules/matlab/CMakeLists.txt b/modules/matlab/CMakeLists.txt index 3a5c6d12f..a4c1c3b16 100644 --- a/modules/matlab/CMakeLists.txt +++ b/modules/matlab/CMakeLists.txt @@ -104,7 +104,11 @@ set(RST_PARSER_PATH ${CMAKE_SOURCE_DIR}/modules/java/generator) # set mex compiler options prepend("-I" MEX_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/include) -prepend("-L" MEX_LIB_DIR ${LIBRARY_OUTPUT_PATH}/${CMAKE_CFG_INTDIR} ) +if (MSVC) + prepend("-L" MEX_LIB_DIR ${LIBRARY_OUTPUT_PATH}/${CMAKE_CFG_INTDIR}) +else() + prepend("-L" MEX_LIB_DIR ${LIBRARY_OUTPUT_PATH}) +endif() set(MEX_OPTS "-largeArrayDims") if (BUILD_TESTS)