mirror of
https://github.com/libevent/libevent.git
synced 2025-01-31 09:12:55 +08:00
cmake: eliminate EVENT_BUILDING_REGRESS_TEST, since we link with shared libs
Before 7182c2f561570cd9ceb704623ebe9ae3608c7b43 ("cmake: build SHARED and STATIC libraries (like autoconf does)") it links with *.c.
This commit is contained in:
parent
a4b1828d6d
commit
30f2a969e8
@ -983,19 +983,11 @@ if (NOT EVENT__DISABLE_TESTS)
|
|||||||
|
|
||||||
add_executable(regress ${SRC_REGRESS})
|
add_executable(regress ${SRC_REGRESS})
|
||||||
|
|
||||||
# While building the test suite we don't want the visibility
|
|
||||||
# header trying to "dllimport" the symbols on windows (it
|
|
||||||
# generates a ton of warnings due to different link
|
|
||||||
# attributes for all of the symbols)
|
|
||||||
set_target_properties(regress
|
|
||||||
PROPERTIES COMPILE_DEFINITIONS
|
|
||||||
"EVENT_BUILDING_REGRESS_TEST=1")
|
|
||||||
|
|
||||||
target_link_libraries(regress
|
target_link_libraries(regress
|
||||||
${LIB_APPS}
|
${LIB_APPS}
|
||||||
${LIB_PLATFORM}
|
${LIB_PLATFORM}
|
||||||
event_core_shared
|
event_core_shared
|
||||||
event_extra_static)
|
event_extra_shared)
|
||||||
if (NOT EVENT__DISABLE_OPENSSL)
|
if (NOT EVENT__DISABLE_OPENSSL)
|
||||||
target_link_libraries(regress event_openssl_shared)
|
target_link_libraries(regress event_openssl_shared)
|
||||||
endif()
|
endif()
|
||||||
|
@ -44,7 +44,7 @@
|
|||||||
# define EVENT2_EXPORT_SYMBOL /* unknown compiler */
|
# define EVENT2_EXPORT_SYMBOL /* unknown compiler */
|
||||||
# endif
|
# endif
|
||||||
#else
|
#else
|
||||||
# if defined(_MSC_VER) && !defined(EVENT_BUILDING_REGRESS_TEST)
|
# if defined(_MSC_VER)
|
||||||
# define EVENT2_EXPORT_SYMBOL extern __declspec(dllimport)
|
# define EVENT2_EXPORT_SYMBOL extern __declspec(dllimport)
|
||||||
# else
|
# else
|
||||||
# define EVENT2_EXPORT_SYMBOL
|
# define EVENT2_EXPORT_SYMBOL
|
||||||
|
Loading…
x
Reference in New Issue
Block a user