Skip to content

Update CMakeLists.txt#203

Merged
yanyiwu merged 1 commit intoyanyiwu:masterfrom
sheldonrobinson:master
Jul 18, 2025
Merged

Update CMakeLists.txt#203
yanyiwu merged 1 commit intoyanyiwu:masterfrom
sheldonrobinson:master

Conversation

@sheldonrobinson
Copy link
Contributor

Add cppjieba library definition

Add cppjieba library deefinition
@yanyiwu yanyiwu requested a review from Copilot July 18, 2025 11:23
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds the cppjieba library definition to the CMake build system. The change creates an interface library target for cppjieba with appropriate include directories.

  • Adds cppjieba as an INTERFACE library target
  • Configures include directories for the main project and limonp dependency

Comment on lines +24 to +28
add_library(cppjieba INTERFACE)
target_include_directories(cppjieba INTERFACE
${PROJECT_SOURCE_DIR}/include
${PROJECT_SOURCE_DIR}/deps/limonp/include
)
Copy link

Copilot AI Jul 18, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider checking if the cppjieba target already exists before creating it to avoid potential conflicts when this CMakeLists.txt is included multiple times. You can use if(NOT TARGET cppjieba) to guard the library creation.

Suggested change
add_library(cppjieba INTERFACE)
target_include_directories(cppjieba INTERFACE
${PROJECT_SOURCE_DIR}/include
${PROJECT_SOURCE_DIR}/deps/limonp/include
)
if(NOT TARGET cppjieba)
add_library(cppjieba INTERFACE)
target_include_directories(cppjieba INTERFACE
${PROJECT_SOURCE_DIR}/include
${PROJECT_SOURCE_DIR}/deps/limonp/include
)
endif()

Copilot uses AI. Check for mistakes.
@yanyiwu yanyiwu merged commit a2e3497 into yanyiwu:master Jul 18, 2025
32 of 36 checks passed
@yanyiwu
Copy link
Owner

yanyiwu commented Jul 18, 2025

Thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants