Added CMake copy of CEF resource files to avoid linux CEF runtime error

This commit is contained in:
GPayne
2022-05-15 13:59:15 -06:00
parent ecef586883
commit 77833f86fd

View File

@@ -67,14 +67,10 @@ set(CEF_VERSION "91.1.23+g04c8d56+chromium-91.0.4472.164")
#endif ()
# CEF Sandbox is not working with the latest Visual Studio, so we disable it for now.
if (WIN32)
if (WIN32 OR UNIX)
option(USE_SANDBOX OFF)
endif ()
if (OS_LINUX)
set(USE_SANDBOX OFF)
endif ()
# Add this project's cmake/ directory to the module path.
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
include(cef_support)
@@ -272,3 +268,13 @@ foreach (j ${CEF_RESOURCE_FILES})
list(APPEND deps "${CEF_RESOURCE_DIR}/${j}")
endforeach()
add_external_library_dependencies("${deps}")
# Linux needs to have copies of CEF files in Resources/ in its build-type dir to avoid
# the 'Couldn't mmap icu data file' runtime error
if (UNIX)
file(COPY ${CEF_ROOT}/Resources/
DESTINATION ${CEF_ROOT}/${CMAKE_BUILD_TYPE}/
FILES_MATCHING PATTERN *
)
endif ()