File tree 3 files changed +21
-1
lines changed
3 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -419,6 +419,20 @@ if(APPLE OR CMAKE_SYSTEM_NAME MATCHES "DragonFly|FreeBSD|Linux|NetBSD|OpenBSD")
419
419
list (APPEND uv_test_libraries util)
420
420
endif ()
421
421
422
+ if (CYGWIN OR MSYS)
423
+ list (APPEND uv_defines _GNU_SOURCE)
424
+ list (APPEND uv_sources
425
+ src/unix /cygwin .c
426
+ src/unix /bsd-ifaddrs.c
427
+ src/unix /no -fsevents.c
428
+ src/unix /no -proctitle.c
429
+ src/unix /posix-hrtime.c
430
+ src/unix /posix-poll.c
431
+ src/unix /procfs-exepath.c
432
+ src/unix /sysinfo-loadavg.c
433
+ src/unix /sysinfo-memory.c)
434
+ endif ()
435
+
422
436
if (LIBUV_BUILD_SHARED)
423
437
add_library (uv SHARED ${uv_sources} )
424
438
target_compile_definitions (uv
@@ -439,6 +453,7 @@ if(LIBUV_BUILD_SHARED)
439
453
set_target_properties (uv PROPERTIES LINKER_LANGUAGE CXX)
440
454
endif ()
441
455
target_link_libraries (uv ${uv_libraries} )
456
+ set_target_properties (uv PROPERTIES OUTPUT_NAME "uv" )
442
457
endif ()
443
458
444
459
add_library (uv_a STATIC ${uv_sources} )
@@ -455,6 +470,10 @@ if(CMAKE_SYSTEM_NAME STREQUAL "OS390")
455
470
set_target_properties (uv_a PROPERTIES LINKER_LANGUAGE CXX)
456
471
endif ()
457
472
target_link_libraries (uv_a ${uv_libraries} )
473
+ set_target_properties (uv_a PROPERTIES OUTPUT_NAME "uv" )
474
+ if (MSVC )
475
+ set_target_properties (uv_a PROPERTIES PREFIX "lib" )
476
+ endif ()
458
477
459
478
if (LIBUV_BUILD_TESTS)
460
479
# Small hack: use ${uv_test_sources} now to get the runner skeleton,
Original file line number Diff line number Diff line change @@ -8,5 +8,5 @@ Version: @PACKAGE_VERSION@
8
8
Description: multi-platform support library with a focus on asynchronous I/O.
9
9
URL: http://libuv.org/
10
10
11
- Libs: -L${libdir} -luv_a @LIBS@
11
+ Libs: -L${libdir} -l:libuv.a @LIBS@
12
12
Cflags: -I${includedir}
Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ prefix=@prefix@
2
2
exec_prefix=${prefix}
3
3
libdir=@libdir@
4
4
includedir=@includedir@
5
+ LIBUV_STATIC=-L${libdir} -l:libuv.a @LIBS@
5
6
6
7
Name: libuv
7
8
Version: @PACKAGE_VERSION@
You can’t perform that action at this time.
0 commit comments