From ff357250f8b5988e94d10f825986ea1d85ac329d Mon Sep 17 00:00:00 2001 From: "Edward A. Lee" Date: Sat, 10 Feb 2024 07:17:25 -0800 Subject: [PATCH] Make WebSockets demos compile on Linux --- examples/C/src/lib/WebSocketCmake.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/examples/C/src/lib/WebSocketCmake.txt b/examples/C/src/lib/WebSocketCmake.txt index bc2089c8..851a57bc 100644 --- a/examples/C/src/lib/WebSocketCmake.txt +++ b/examples/C/src/lib/WebSocketCmake.txt @@ -1,3 +1,5 @@ find_package(libwebsockets REQUIRED) # Finds the libwebsockets library -target_link_libraries( ${LF_MAIN_TARGET} websockets ) # Links the websockets library +# Note that the PUBLIC keyword is needed otherwise CMake will issue an error +# saying that you must use either all-keywords or all-plain, and the keywords are previously used. +target_link_libraries( ${LF_MAIN_TARGET} PUBLIC websockets ) # Links the websockets library