- Upgraded gRPC version from v1.68.0 to v1.75.1 for improved compatibility across all platforms. - Removed /WHOLEARCHIVE linking for protobuf to prevent duplicate version resource errors in the dependency chain. - Updated status messages to reflect the latest gRPC version and build optimizations. Benefits: - Enhances build stability and compatibility with modern toolchains. - Simplifies linking process by avoiding unnecessary options that cause conflicts.
48 lines
1.3 KiB
CMake
48 lines
1.3 KiB
CMake
# This file defines the z3ed command-line tool.
|
|
|
|
add_executable(z3ed
|
|
cli/cli_main.cc
|
|
cli/cli.cc
|
|
cli/tui/tui.cc
|
|
cli/tui/unified_layout.cc
|
|
cli/tui/chat_tui.cc
|
|
cli/tui/autocomplete_ui.cc
|
|
cli/util/autocomplete.cc
|
|
# ... (source files)
|
|
)
|
|
|
|
target_compile_definitions(z3ed PRIVATE YAZE_ASSETS_PATH="${CMAKE_SOURCE_DIR}/assets")
|
|
|
|
# Copy agent assets for z3ed
|
|
if(EXISTS ${CMAKE_SOURCE_DIR}/assets/agent)
|
|
file(COPY ${CMAKE_SOURCE_DIR}/assets/agent/ DESTINATION "${CMAKE_BINARY_DIR}/assets/agent/")
|
|
add_custom_command(TARGET z3ed POST_BUILD
|
|
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/assets/agent $<TARGET_FILE_DIR:z3ed>/assets/agent
|
|
COMMENT "Copying agent assets for z3ed"
|
|
)
|
|
endif()
|
|
|
|
target_include_directories(z3ed PUBLIC
|
|
"${CMAKE_CURRENT_SOURCE_DIR}"
|
|
"${CMAKE_CURRENT_SOURCE_DIR}/tui"
|
|
)
|
|
|
|
target_link_libraries(z3ed PRIVATE
|
|
yaze_core
|
|
yaze_agent
|
|
ftxui::component
|
|
)
|
|
|
|
if(Z3ED_AI)
|
|
target_link_libraries(z3ed PRIVATE yaml-cpp)
|
|
endif()
|
|
|
|
if(YAZE_WITH_GRPC)
|
|
message(STATUS "Adding gRPC support to z3ed CLI")
|
|
target_link_libraries(z3ed PRIVATE grpc++ grpc++_reflection)
|
|
if(YAZE_PROTOBUF_TARGETS)
|
|
target_link_libraries(z3ed PRIVATE ${YAZE_PROTOBUF_TARGETS})
|
|
# NOTE: Removed /WHOLEARCHIVE for protobuf - causes duplicate version.res in dependency chain
|
|
endif()
|
|
endif()
|