# HG changeset patch
# User alfadur
# Date 1599340897 -10800
# Node ID 027a56b3895e61034c0d71201673d5294042a460
# Parent  6832dab555aefa6ef2830d9452a9a88c89299e85
fix vcpkg build

diff -r 6832dab555ae -r 027a56b3895e QTfrontend/CMakeLists.txt
--- a/QTfrontend/CMakeLists.txt	Mon Aug 10 12:56:53 2020 +0300
+++ b/QTfrontend/CMakeLists.txt	Sun Sep 06 00:21:37 2020 +0300
@@ -236,7 +236,7 @@
 
 if(WIN32 AND NOT UNIX)
     if(NOT SDL2_LIBRARIES)
-        list(APPEND HW_LINK_LIBS SDL2)
+        list(APPEND HW_LINK_LIBS SDL2::SDL2)
     endif()
 
     list(APPEND HW_LINK_LIBS
diff -r 6832dab555ae -r 027a56b3895e misc/libphyslayer/CMakeLists.txt
--- a/misc/libphyslayer/CMakeLists.txt	Mon Aug 10 12:56:53 2020 +0300
+++ b/misc/libphyslayer/CMakeLists.txt	Sun Sep 06 00:21:37 2020 +0300
@@ -17,7 +17,11 @@
 set_target_properties(physlayer PROPERTIES
                           VERSION 1.0
                           SOVERSION 1.0)
-target_link_libraries(physlayer ${SDL2_LIBRARIES} lua physfs)
+if(WIN32 AND VCPKG_TOOLCHAIN)                          
+    target_link_libraries(physlayer SDL2::SDL2 lua physfs)
+else()
+    target_link_libraries(physlayer ${SDL2_LIBRARIES} lua physfs)
+endif()
 install(TARGETS physlayer RUNTIME DESTINATION ${target_binary_install_dir}
                           LIBRARY DESTINATION ${target_library_install_dir}
                           ARCHIVE DESTINATION ${target_library_install_dir})