cmake/cmake-mingw-dl.patch

22 lines
910 B
Diff
Raw Normal View History

2020-02-17 22:02:11 +00:00
Index: cmake-3.17.0-rc1/Modules/Platform/Windows-GNU.cmake
2019-03-15 13:17:43 +00:00
===================================================================
2020-02-17 22:02:11 +00:00
--- cmake-3.17.0-rc1.orig/Modules/Platform/Windows-GNU.cmake
+++ cmake-3.17.0-rc1/Modules/Platform/Windows-GNU.cmake
@@ -25,12 +25,14 @@ endif()
if(MINGW)
set(CMAKE_FIND_LIBRARY_PREFIXES "lib" "")
- set(CMAKE_FIND_LIBRARY_SUFFIXES ".dll.a" ".a" ".lib")
+ set(CMAKE_FIND_LIBRARY_SUFFIXES ".dll" ".dll.a" ".a" ".lib")
2017-12-30 15:14:14 +00:00
set(CMAKE_C_STANDARD_LIBRARIES_INIT "-lkernel32 -luser32 -lgdi32 -lwinspool -lshell32 -lole32 -loleaut32 -luuid -lcomdlg32 -ladvapi32")
set(CMAKE_CXX_STANDARD_LIBRARIES_INIT "${CMAKE_C_STANDARD_LIBRARIES_INIT}")
+ set(CMAKE_DL_LIBS "dl")
+else()
+ set(CMAKE_DL_LIBS "")
endif()
-set(CMAKE_DL_LIBS "")
set(CMAKE_LIBRARY_PATH_FLAG "-L")
set(CMAKE_LINK_LIBRARY_FLAG "-l")
set(CMAKE_LINK_DEF_FILE_FLAG "") # Empty string: passing the file is enough