TCP 的逻辑实现,可以和客户端连接发送数据
This commit is contained in:
28
CMakeLists.txt
Normal file
28
CMakeLists.txt
Normal file
@@ -0,0 +1,28 @@
|
||||
cmake_minimum_required(VERSION 3.10)
|
||||
project(DTU_HMI)
|
||||
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
|
||||
# 导出编译数据库,供 Cursor/clangd 使用
|
||||
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
|
||||
|
||||
if(MSVC)
|
||||
add_compile_options(/utf-8)
|
||||
endif()
|
||||
|
||||
add_executable(DTU-HMI
|
||||
src/main.c
|
||||
src/menu.c
|
||||
src/thread_utils.c
|
||||
src/remoteDisplay.c
|
||||
src/TCP/tcp.c
|
||||
)
|
||||
|
||||
target_include_directories(DTU-HMI PRIVATE include src src/TCP)
|
||||
|
||||
if(WIN32)
|
||||
target_link_libraries(DTU-HMI PRIVATE ws2_32)
|
||||
else()
|
||||
target_link_libraries(DTU-HMI PRIVATE pthread)
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user