From 7080d540e21ebd8d5df78fa6abd686c7e0c261f3 Mon Sep 17 00:00:00 2001 From: Bert Belder Date: Wed, 12 Jun 2019 15:57:58 +0200 Subject: [PATCH] build: do not force-include wepoll.h using a command line switch --- CMakeLists.txt | 3 +-- src/api.c | 1 + src/sock.c | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 133136f..1b082d4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -69,10 +69,9 @@ set(DLL_TARGET "${HEADER_NAME}.dll") add_library(${DLL_TARGET} SHARED ${SOURCES_HEADER} ${SOURCES_SRC} ${SOURCES_SRC_REGULAR}) target_include_directories(${DLL_TARGET} PUBLIC include src/regular) if(MSVC) - target_compile_options(${DLL_TARGET} PUBLIC "-FI${SOURCES_HEADER}") target_compile_definitions(${DLL_TARGET} PUBLIC "-D${HEADER_NAME_UC}_EXPORT=__declspec(dllexport)" ) else() - target_compile_options(${DLL_TARGET} PUBLIC -include ${SOURCES_HEADER} -fvisibility=hidden) + target_compile_options(${DLL_TARGET} PUBLIC -fvisibility=hidden) target_compile_definitions(${DLL_TARGET} PUBLIC "-D${HEADER_NAME_UC}_EXPORT=__attribute__((visibility(\"default\")))") endif() set_target_properties(${DLL_TARGET} PROPERTIES OUTPUT_NAME ${DLL_NAME}) diff --git a/src/api.c b/src/api.c index 7482f5e..f330181 100644 --- a/src/api.c +++ b/src/api.c @@ -7,6 +7,7 @@ #include "port.h" #include "thread-safe-tree.h" #include "util.h" +#include "wepoll.h" #include "win.h" static ts_tree_t epoll__handle_tree; diff --git a/src/sock.c b/src/sock.c index 050295b..3fd0cad 100644 --- a/src/sock.c +++ b/src/sock.c @@ -9,6 +9,7 @@ #include "poll-group.h" #include "port.h" #include "sock.h" +#include "wepoll.h" #include "ws.h" static const uint32_t SOCK__KNOWN_EPOLL_EVENTS =