[EFL] The remote inspector does not show the base page.
[WebKit.git] / Source / PlatformEfl.cmake
1 add_subdirectory(${WEBCORE_DIR}/platform/efl/DefaultTheme)
2
3 if (ENABLE_INSPECTOR)
4     add_custom_target(
5         web-inspector-resources ALL
6         COMMAND ${CMAKE_COMMAND} -E copy_directory ${WEBINSPECTORUI_DIR}/UserInterface ${WEB_INSPECTOR_DIR}
7         COMMAND ${CMAKE_COMMAND} -E copy ${WEBINSPECTORUI_DIR}/Localizations/en.lproj/localizedStrings.js ${WEB_INSPECTOR_DIR}
8         COMMAND ${CMAKE_COMMAND} -E copy ${WEBKIT2_DIR}/UIProcess/InspectorServer/front-end/inspectorPageIndex.html ${WEB_INSPECTOR_DIR}
9         DEPENDS WebCore
10         WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
11     )
12     install(DIRECTORY "${CMAKE_BINARY_DIR}/${WEB_INSPECTOR_DIR}"
13         DESTINATION ${DATA_INSTALL_DIR}
14         FILES_MATCHING PATTERN "*.js"
15                        PATTERN "*.html"
16                        PATTERN "*.css"
17                        PATTERN "*.gif"
18                        PATTERN "*.png"
19                        PATTERN "*.svg")
20
21     find_program(UGLIFYJS_EXECUTABLE uglifyjs)
22     if (UGLIFYJS_EXECUTABLE AND (NOT ${CMAKE_BUILD_TYPE} STREQUAL "Debug"))
23         file(GLOB frontend_js_files "${WEBINSPECTORUI_DIR}/UserInterface/*.js")
24         set(all_js_files
25             ${frontend_js_files}
26             "${WEBINSPECTORUI_DIR}/Localizations/en.lproj/localizedStrings.js"
27         )
28
29         foreach (js_file ${all_js_files})
30             get_filename_component(filename ${js_file} NAME)
31             install(CODE
32                 "execute_process(
33                     COMMAND ${UGLIFYJS_EXECUTABLE} --overwrite ${filename}
34                     WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${WEB_INSPECTOR_DIR})")
35         endforeach ()
36
37         file(GLOB codemirror_js_files "${WEBINSPECTORUI_DIR}/UserInterface/External/CodeMirror/*.js")
38         foreach (js_file ${codemirror_js_files})
39             get_filename_component(filename ${js_file} NAME)
40             install(CODE
41                 "execute_process(
42                     COMMAND ${UGLIFYJS_EXECUTABLE} --overwrite ${filename}
43                     WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${WEB_INSPECTOR_DIR}/External/CodeMirror/)")
44         endforeach ()
45     endif ()
46 endif ()