@@ -7,67 +7,70 @@ add_executable(CodeFormatServer)
77add_dependencies (CodeFormatServer CodeService)
88
99target_include_directories (CodeFormatServer PUBLIC
10- ${LuaCodeStyle_SOURCE_DIR} /include
11- ${LuaCodeStyle_SOURCE_DIR} /3rd/asio-1.20.0/include
12- ${LuaCodeStyle_SOURCE_DIR} /3rd/nlohmann_json/include
13- ${LuaCodeStyle_SOURCE_DIR} /3rd/mimalloc-2.0.3/include
14- src
15- )
10+ ${LuaCodeStyle_SOURCE_DIR} /include
11+ ${LuaCodeStyle_SOURCE_DIR} /3rd/asio-1.20.0/include
12+ ${LuaCodeStyle_SOURCE_DIR} /3rd/nlohmann_json/include
13+ ${LuaCodeStyle_SOURCE_DIR} /3rd/mimalloc-2.0.3/include
14+ src
15+ )
1616
1717target_compile_options (CodeFormatServer PUBLIC -DASIO_STANDALONE)
1818
1919target_sources (CodeFormatServer
20- PRIVATE
21- ${CodeFormatServer_SOURCE_DIR} /src/main.cpp
22- ${CodeFormatServer_SOURCE_DIR} /src/LanguageServer.cpp
23-
24- #LSP
25- ${CodeFormatServer_SOURCE_DIR} /src/LSP/LSP.cpp
26- ${CodeFormatServer_SOURCE_DIR} /src/LSP/LSPHandle.cpp
27- #Session
28- ${CodeFormatServer_SOURCE_DIR} /src/Session/IOSession.cpp
29- ${CodeFormatServer_SOURCE_DIR} /src/Session/SocketIOSession.cpp
30- ${CodeFormatServer_SOURCE_DIR} /src/Session/StandardIOSession.cpp
31- #protocol
32- ${CodeFormatServer_SOURCE_DIR} /src/Session/Protocol/ProtocolParser.cpp
33- ${CodeFormatServer_SOURCE_DIR} /src/Session/Protocol/ProtocolBuffer.cpp
34-
35- #vfs
36- ${CodeFormatServer_SOURCE_DIR} /src/VFS/VirtualFile.cpp
37- ${CodeFormatServer_SOURCE_DIR} /src/VFS/VirtualFileSystem.cpp
38-
39- #DB
40- ${CodeFormatServer_SOURCE_DIR} /src/DB/FileDB.cpp
41- ${CodeFormatServer_SOURCE_DIR} /src/DB/UriDB.cpp
42- ${CodeFormatServer_SOURCE_DIR} /src/DB/LineIndexDB.cpp
43-
44- #lib
45- ${CodeFormatServer_SOURCE_DIR} /src/Lib/LineIndex/LineIndex.cpp
46- ${CodeFormatServer_SOURCE_DIR} /src/Lib/LineIndex/LineTypes.cpp
47-
48- #service
49- ${CodeFormatServer_SOURCE_DIR} /src/Service/Service.cpp
50- ${CodeFormatServer_SOURCE_DIR} /src/Service/FormatService.cpp
51- ${CodeFormatServer_SOURCE_DIR} /src/Service/DiagnosticService.cpp
52- # ${CodeFormatServer_SOURCE_DIR}/src/Service/CommandService.cpp
53- # ${CodeFormatServer_SOURCE_DIR}/src/Service/CodeActionService.cpp
54- ${CodeFormatServer_SOURCE_DIR} /src/Service/ConfigService.cpp
55-
56- # mimalloc
57- ${LuaCodeStyle_SOURCE_DIR} /3rd/mimalloc-2.0.3/src/static .c
58- )
20+ PRIVATE
21+ ${CodeFormatServer_SOURCE_DIR} /src/main.cpp
22+ ${CodeFormatServer_SOURCE_DIR} /src/LanguageServer.cpp
23+
24+ #Config
25+ ${CodeFormatServer_SOURCE_DIR} /src/Config/ClientConfig.cpp
26+
27+ #LSP
28+ ${CodeFormatServer_SOURCE_DIR} /src/LSP/LSP.cpp
29+ ${CodeFormatServer_SOURCE_DIR} /src/LSP/LSPHandle.cpp
30+ #Session
31+ ${CodeFormatServer_SOURCE_DIR} /src/Session/IOSession.cpp
32+ ${CodeFormatServer_SOURCE_DIR} /src/Session/SocketIOSession.cpp
33+ ${CodeFormatServer_SOURCE_DIR} /src/Session/StandardIOSession.cpp
34+ #protocol
35+ ${CodeFormatServer_SOURCE_DIR} /src/Session/Protocol/ProtocolParser.cpp
36+ ${CodeFormatServer_SOURCE_DIR} /src/Session/Protocol/ProtocolBuffer.cpp
37+
38+ #vfs
39+ ${CodeFormatServer_SOURCE_DIR} /src/VFS/VirtualFile.cpp
40+ ${CodeFormatServer_SOURCE_DIR} /src/VFS/VirtualFileSystem.cpp
41+
42+ #DB
43+ ${CodeFormatServer_SOURCE_DIR} /src/DB/FileDB.cpp
44+ ${CodeFormatServer_SOURCE_DIR} /src/DB/UriDB.cpp
45+ ${CodeFormatServer_SOURCE_DIR} /src/DB/LineIndexDB.cpp
46+
47+ #lib
48+ ${CodeFormatServer_SOURCE_DIR} /src/Lib/LineIndex/LineIndex.cpp
49+ ${CodeFormatServer_SOURCE_DIR} /src/Lib/LineIndex/LineTypes.cpp
50+
51+ #service
52+ ${CodeFormatServer_SOURCE_DIR} /src/Service/Service.cpp
53+ ${CodeFormatServer_SOURCE_DIR} /src/Service/FormatService.cpp
54+ ${CodeFormatServer_SOURCE_DIR} /src/Service/DiagnosticService.cpp
55+ ${CodeFormatServer_SOURCE_DIR} /src/Service/CommandService.cpp
56+ ${CodeFormatServer_SOURCE_DIR} /src/Service/CodeActionService.cpp
57+ ${CodeFormatServer_SOURCE_DIR} /src/Service/ConfigService.cpp
58+
59+ # mimalloc
60+ ${LuaCodeStyle_SOURCE_DIR} /3rd/mimalloc-2.0.3/src/static .c
61+ )
5962
6063target_link_libraries (CodeFormatServer PUBLIC CodeService)
6164
6265
63- if (CMAKE_SYSTEM_NAME MATCHES "Windows" )
64- target_compile_definitions (CodeFormatServer PUBLIC -D_WIN32_WINNT=0x0601)
65- elseif (CMAKE_SYSTEM_NAME MATCHES "Linux" )
66- target_link_libraries (CodeFormatServer PUBLIC pthread -static -libstdc++ -static -libgcc)
67- endif ()
66+ if (CMAKE_SYSTEM_NAME MATCHES "Windows" )
67+ target_compile_definitions (CodeFormatServer PUBLIC -D_WIN32_WINNT=0x0601)
68+ elseif (CMAKE_SYSTEM_NAME MATCHES "Linux" )
69+ target_link_libraries (CodeFormatServer PUBLIC pthread -static -libstdc++ -static -libgcc)
70+ endif ()
6871
6972install (
70- TARGETS CodeFormatServer
71- LIBRARY DESTINATION lib
72- RUNTIME DESTINATION bin
73+ TARGETS CodeFormatServer
74+ LIBRARY DESTINATION lib
75+ RUNTIME DESTINATION bin
7376)
0 commit comments