Skip to content

Commit

Permalink
Work around a bug in CMake that breaks ^ anchors.
Browse files Browse the repository at this point in the history
https://gitlab.kitware.com/cmake/cmake/-/issues/16899 was reported
seven years ago. The bug existed at least ten years ago. It hasn't
been fixed.

Change-Id: Ifbe3e77ce6371091b24303d5c4953d401ed29826
Reviewed-on: https://code-review.googlesource.com/c/re2/+/63071
Reviewed-by: Alex Chernyakhovsky <[email protected]>
Reviewed-by: Paul Wankadia <[email protected]>
  • Loading branch information
junyer committed May 20, 2024
1 parent 630d011 commit a771d3f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,9 @@ if(UNIX)
endif()

foreach(dep ${ABSL_DEPS})
string(REGEX REPLACE "^absl_" "absl::" dep ${dep})
# Work around https://gitlab.kitware.com/cmake/cmake/-/issues/16899. >:(
string(PREPEND dep "^")
string(REGEX REPLACE "\\^absl_" "absl::" dep ${dep})
target_link_libraries(re2 PUBLIC ${dep})
endforeach()

Expand Down

0 comments on commit a771d3f

Please sign in to comment.