Skip to content

Commit 58ba50a

Browse files
mgornytstellar
authored andcommitted
[cmake] Add missing CMakePushCheckState include to FindLibEdit.cmake
Add the missing include to fix an error when `cmake_push_check_state()` is called and incidentally the CMakePushCheckState module is not loaded by any other check running prior to `FindLibEdit.cmake`: CMake Error at /var/no-tmpfs/portage/dev-util/lldb-15.0.4/work/cmake/Modules/FindLibEdit.cmake:24 (cmake_push_check_state): Unknown CMake command "cmake_push_check_state". Call Stack (most recent call first): cmake/modules/LLDBConfig.cmake:52 (find_package) cmake/modules/LLDBConfig.cmake:59 (add_optional_dependency) CMakeLists.txt:28 (include) Gentoo Bug: https://bugs.gentoo.org/880065 Differential Revision: https://reviews.llvm.org/D137555 (cherry picked from commit 3676a86)
1 parent 931b6d5 commit 58ba50a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

cmake/Modules/FindLibEdit.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ find_library(LibEdit_LIBRARIES NAMES edit HINTS ${PC_LIBEDIT_LIBRARY_DIRS})
2121

2222
include(CheckIncludeFile)
2323
if(LibEdit_INCLUDE_DIRS AND EXISTS "${LibEdit_INCLUDE_DIRS}/histedit.h")
24+
include(CMakePushCheckState)
2425
cmake_push_check_state()
2526
list(APPEND CMAKE_REQUIRED_INCLUDES ${LibEdit_INCLUDE_DIRS})
2627
list(APPEND CMAKE_REQUIRED_LIBRARIES ${LibEdit_LIBRARIES})

0 commit comments

Comments
 (0)