Skip to content

Commit

Permalink
fix library names on Cygwin
Browse files Browse the repository at this point in the history
  • Loading branch information
DDoSolitary authored and zhaozg committed Feb 13, 2022
1 parent 6cd4940 commit 9d602ab
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -207,18 +207,13 @@ if (BUILD_MODULE)
endif (BUILD_MODULE)
if (BUILD_STATIC_LIBS)
add_library(libluv_a STATIC src/luv.c)
set_target_properties(libluv_a PROPERTIES PREFIX "")
set_target_properties(libluv_a PROPERTIES OUTPUT_NAME luv)
list(APPEND ACTIVE_TARGETS "libluv_a")
endif (BUILD_STATIC_LIBS)
if (BUILD_SHARED_LIBS)
add_library(libluv SHARED src/luv.c)
set_target_properties(libluv PROPERTIES PREFIX "")
set_target_properties(libluv
PROPERTIES VERSION ${LUV_VERSION} SOVERSION ${LUV_VERSION_MAJOR})
# Prevent lib prefix in shared library name
if(WIN32)
set_target_properties(libluv PROPERTIES IMPORT_PREFIX "")
endif(WIN32)
PROPERTIES VERSION ${LUV_VERSION} SOVERSION ${LUV_VERSION_MAJOR} OUTPUT_NAME luv)
if(APPLE)
set_target_properties(libluv
PROPERTIES LINK_FLAGS "-undefined dynamic_lookup")
Expand Down

0 comments on commit 9d602ab

Please sign in to comment.