diff --git a/scripts/cmake/vcpkg_common_definitions.cmake b/scripts/cmake/vcpkg_common_definitions.cmake index 3a1818bf56..724644abcb 100644 --- a/scripts/cmake/vcpkg_common_definitions.cmake +++ b/scripts/cmake/vcpkg_common_definitions.cmake @@ -64,7 +64,16 @@ else() endif() #Helper variables for libraries -if(VCPKG_TARGET_IS_WINDOWS) +if(VCPKG_TARGET_IS_MINGW) + set(VCPKG_TARGET_STATIC_LIBRARY_SUFFIX ".a") + set(VCPKG_TARGET_IMPORT_LIBRARY_SUFFIX ".dll.a") + set(VCPKG_TARGET_SHARED_LIBRARY_SUFFIX ".dll") + set(VCPKG_TARGET_STATIC_LIBRARY_PREFIX "lib") + set(VCPKG_TARGET_SHARED_LIBRARY_PREFIX "lib") + set(VCPKG_TARGET_IMPORT_LIBRARY_PREFIX "lib") + set(VCPKG_FIND_LIBRARY_SUFFIXES ".dll" ".dll.a" ".a" ".lib") + set(VCPKG_FIND_LIBRARY_PREFIXES "lib" "") +elseif(VCPKG_TARGET_IS_WINDOWS) set(VCPKG_TARGET_STATIC_LIBRARY_SUFFIX ".lib") set(VCPKG_TARGET_IMPORT_LIBRARY_SUFFIX ".lib") set(VCPKG_TARGET_SHARED_LIBRARY_SUFFIX ".dll") @@ -74,15 +83,6 @@ if(VCPKG_TARGET_IS_WINDOWS) set(VCPKG_TARGET_IMPORT_LIBRARY_PREFIX "") set(VCPKG_FIND_LIBRARY_SUFFIXES ".lib" ".dll") #This is a slight modification to CMakes value which does not include ".dll". set(VCPKG_FIND_LIBRARY_PREFIXES "" "lib") #This is a slight modification to CMakes value which does not include "lib". -elseif(VCPKG_TARGET_IS_MINGW) - set(VCPKG_TARGET_STATIC_LIBRARY_SUFFIX ".a") - set(VCPKG_TARGET_IMPORT_LIBRARY_SUFFIX ".dll.a") - set(VCPKG_TARGET_SHARED_LIBRARY_SUFFIX ".dll") - set(VCPKG_TARGET_STATIC_LIBRARY_PREFIX "lib") - set(VCPKG_TARGET_SHARED_LIBRARY_PREFIX "lib") - set(VCPKG_TARGET_IMPORT_LIBRARY_PREFIX "lib") - set(VCPKG_FIND_LIBRARY_SUFFIXES ".dll" ".dll.a" ".a" ".lib") - set(VCPKG_FIND_LIBRARY_PREFIXES "lib" "") elseif(VCPKG_TARGET_IS_OSX) set(VCPKG_TARGET_STATIC_LIBRARY_SUFFIX ".a") set(VCPKG_TARGET_IMPORT_LIBRARY_SUFFIX "")