Skip to content

Commit

Permalink
Fix Xcode linking issues introduced by CMake 3.19.0 (#248)
Browse files Browse the repository at this point in the history
  • Loading branch information
PatTheMav committed Nov 27, 2020
1 parent a668444 commit 35b26e9
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions FindCEF.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,19 @@ if(WIN32)
debug ${CEFWRAPPER_LIBRARY_DEBUG})
endif()
else()
set(CEF_LIBRARIES
${CEF_LIBRARY}
${CEFWRAPPER_LIBRARY})
# Fixes cmake 3.19.0 commit that added support for modern Xcode build system, but "forgot"
# to also escape framework names themselves in addition to the framework path:
# Commit https://gitlab.kitware.com/cmake/cmake/-/commit/ce2dee9e5bae37c8117087bb83add075c3c123b4
if(${CMAKE_VERSION} VERSION_GREATER "3.19.0" AND XCODE)
string(REPLACE "Chromium Embedded Framework" "\"Chromium Embedded Framework\"" CEF_LIBRARY_FIXED ${CEF_LIBRARY})
set(CEF_LIBRARIES
${CEF_LIBRARY_FIXED}
${CEFWRAPPER_LIBRARY})
else()
set(CEF_LIBRARIES
${CEF_LIBRARY}
${CEFWRAPPER_LIBRARY})
endif()
endif()

find_package_handle_standard_args(CEF DEFAULT_MSG CEF_LIBRARY
Expand Down

0 comments on commit 35b26e9

Please sign in to comment.