Browse Source

Specify link library visibility

alex 2 years ago
parent
commit
e16e91ffc9
1 changed files with 3 additions and 3 deletions
  1. 3 3
      CMakeLists.txt

+ 3 - 3
CMakeLists.txt

@@ -5,7 +5,7 @@ if (ENET_STATIC)
     add_library(enet STATIC test/library.c)
 
     if (WIN32)
-        target_link_libraries(enet winmm ws2_32)
+        target_link_libraries(enet PUBLIC winmm ws2_32)
     endif()
 endif()
 
@@ -14,7 +14,7 @@ if (ENET_SHARED)
     add_library(enet SHARED test/library.c)
 
     if (WIN32)
-        target_link_libraries(enet winmm ws2_32)
+        target_link_libraries(enet PUBLIC winmm ws2_32)
     endif()
 endif()
 
@@ -22,7 +22,7 @@ if (ENET_TEST)
     add_executable(enet_test test/build.c)
 
     if (WIN32)
-        target_link_libraries(enet_test winmm ws2_32)
+        target_link_libraries(enet_test PUBLIC winmm ws2_32)
     endif()
 endif()