summaryrefslogtreecommitdiff
path: root/Modules/FindwxWidgets.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2018-04-05 17:28:14 +0000
committerKitware Robot <kwrobot@kitware.com>2018-04-05 13:28:19 -0400
commitd7af8a34b67026feaee558433db3a835d6007e06 (patch)
treebf8e915a5a41d3a9ce5c12f12836e6da1e9f12d9 /Modules/FindwxWidgets.cmake
parent57c2834da056394bed178936fbbe9811a36ae006 (diff)
parent44ad8e48def8d98eaff8fd6deb11731520183daa (diff)
downloadcmake-d7af8a34b67026feaee558433db3a835d6007e06.tar.gz
Merge topic 'findwxwidgets-msys-library-dirs'
44ad8e48de FindwxWidgets: Fix wxWidgets_LIBRARY_DIRS on Cygwin/MSYS Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !1930
Diffstat (limited to 'Modules/FindwxWidgets.cmake')
-rw-r--r--Modules/FindwxWidgets.cmake20
1 files changed, 20 insertions, 0 deletions
diff --git a/Modules/FindwxWidgets.cmake b/Modules/FindwxWidgets.cmake
index caff4db26a..af997ea39f 100644
--- a/Modules/FindwxWidgets.cmake
+++ b/Modules/FindwxWidgets.cmake
@@ -863,6 +863,26 @@ else()
set(wxWidgets_INCLUDE_DIRS ${_tmp_path})
separate_arguments(wxWidgets_INCLUDE_DIRS)
list(REMOVE_ITEM wxWidgets_INCLUDE_DIRS "")
+
+ set(_tmp_path "")
+ foreach(_path ${wxWidgets_LIBRARY_DIRS})
+ execute_process(
+ COMMAND cygpath -w ${_path}
+ OUTPUT_VARIABLE _native_path
+ RESULT_VARIABLE _retv
+ OUTPUT_STRIP_TRAILING_WHITESPACE
+ ERROR_QUIET
+ )
+ if(_retv EQUAL 0)
+ file(TO_CMAKE_PATH ${_native_path} _native_path)
+ DBG_MSG_V("Path ${_path} converted to ${_native_path}")
+ string(APPEND _tmp_path " ${_native_path}")
+ endif()
+ endforeach()
+ DBG_MSG("Setting wxWidgets_LIBRARY_DIRS = ${_tmp_path}")
+ set(wxWidgets_LIBRARY_DIRS ${_tmp_path})
+ separate_arguments(wxWidgets_LIBRARY_DIRS)
+ list(REMOVE_ITEM wxWidgets_LIBRARY_DIRS "")
endif()
unset(_cygpath_exe CACHE)
endif()