[WPE][GTK] Improve dependency tracking of PDF.js files (and other GResources)
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 May 2022 20:57:08 +0000 (20:57 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 May 2022 20:57:08 +0000 (20:57 +0000)
commit14eccdf19e88ea4b25e8e60bb93e742cfdcd8d4c
tree3393f5509d045ec9ab33d354327561c3cca6bf5f
parent1d4aabab4f8685c23d14005fade7f97b38767c04
[WPE][GTK] Improve dependency tracking of PDF.js files (and other GResources)
https://bugs.webkit.org/show_bug.cgi?id=240535

Patch by Michael Catanzaro <mcatanzaro@redhat.com> on 2022-05-19
Reviewed by Adrian Perez de Castro.

This commit does two things. First, for each use of
glib-compile-resources, it adds the --dependency-file argument in order
to make the build command depend on the files included in the GResource
manifest, to ensure the resource is automatically recompiled whenever
any of its source files change. Second, for PDF.js only, it replaces the
GLOB_RECURSE command with a list of source files. The
generate-pdfjs-gresource-manifest.py script is adapted to create CMake
file lists in addition to GResource manifests, and renamed from
-gresource-manifest.py to -resource-manifest.py. The web inspector
GResource would benefit from similar work, but that will be a problem
for another day.

* Tools/TestWebKitAPI/glib/CMakeLists.txt:
* Tools/glib/generate-pdfjs-resource-manifest.py: Renamed from Tools/glib/generate-pdfjs-gresource-manifest.py.
(get_filenames):
(get_filenames.resource_name):
(is_compressible):
(write_cmake_file):
(write_gresource_manifest):
* Source/ThirdParty/pdfjs/PdfJSFiles.cmake: Added.
* Source/ThirdParty/pdfjs/README.webkit:
* Source/WebKit/InspectorGResources.cmake:
* Source/WebKit/PdfJSGResources.cmake:
* Source/WebKit/PlatformGTK.cmake:
* Source/WebKit/PlatformWPE.cmake:
* CMakeLists.txt:
* Source/cmake/OptionsGTK.cmake:
* Source/cmake/OptionsWPE.cmake:

link: https://commits.webkit.org/250761@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@294504 268f45cc-cd09-0410-ab3c-d52691b4dbfc
CMakeLists.txt
Source/ThirdParty/pdfjs/PdfJSFiles.cmake [new file with mode: 0644]
Source/ThirdParty/pdfjs/README.webkit
Source/WebKit/InspectorGResources.cmake
Source/WebKit/PdfJSGResources.cmake
Source/WebKit/PlatformGTK.cmake
Source/WebKit/PlatformWPE.cmake
Source/cmake/OptionsGTK.cmake
Source/cmake/OptionsWPE.cmake
Tools/TestWebKitAPI/glib/CMakeLists.txt
Tools/glib/generate-pdfjs-resource-manifest.py [moved from Tools/glib/generate-pdfjs-gresource-manifest.py with 72% similarity]