Bug 486905 - Qt6 Webengine crash - required icudtl.dat is missing from image
Summary: Qt6 Webengine crash - required icudtl.dat is missing from image
Status: RESOLVED FIXED
Alias: None
Product: Craft
Classification: Developer tools
Component: Blueprints (show other bugs)
Version: unspecified
Platform: Microsoft Windows Microsoft Windows
: NOR crash
Target Milestone: ---
Assignee: Hannah von Reth
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-05-11 20:57 UTC by Thomas Friedrichsmeier
Modified: 2024-05-18 18:48 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Friedrichsmeier 2024-05-11 20:57:54 UTC
Trying to craft Qt6 version of RKWard on Windows, but getting a crash / exit as soon as a QWebEnginePage is created (no crash as long as this is avoided).

Very shortly before the crash, qt logs:
> Could not find any platform plugin

debug.log inside CraftRoot\bin gets this:
> [0511/134609.176:ERROR:icu_util.cc(244)] Invalid file descriptor to ICU data received.

ProcMon shows a failed read attempt to CraftRoot\resources\icudtl.dat (it does not exist), right before logging, and calling WerFault.exe .

Unfortunately, my debugging skills on Windows are not terribly developed. Any ideas on how to proceed.
Comment 1 Thomas Friedrichsmeier 2024-05-13 17:52:03 UTC
Ok, I can definitely confirm it's the missing icudtl.dat.

I tried crafting qtwebengine from source. This did not finish (limited space on virutal machine), but icudtl.dat was generated, nonetheless. Copying this into the CraftRoot\resources (where the other webengine resource files are, too), fixes the crash.

I see the qtwebengine blueprint has a conditional regarding ICU. I have no idea what value was used when compiling the branch, but here, craft --configure used "QT_FEATURE_webengine_system_icu=ON".
Comment 2 Thomas Friedrichsmeier 2024-05-17 16:09:45 UTC
Some more observations:
- The qtwebengine version in the craft cache was indeed built with -DQT_FEATURE_webengine_system=ON (see https://files.kde.org/craft/Qt6/24.04/windows/cl/msvc2022/x86_64/RelWithDebInfo/libs/qt6/qtwebengine/).
- This _should_ mean that icudtl.dat is not needed, but apparently, the option is not working correctly, on Windows. The log shows "bundled_icu" being built (around steps 5280+).
- I note a similar-sounding bug report in homebrew (MacOS): https://github.com/Homebrew/homebrew-core/issues/104008 . Here, the conclusion has apparently been to make system-icu a linux only option. In fact, the Mac logs, too show "bundled_icu" being built despite the build being configured for system_icu.

So, apparently what's happening is that the option is ignored while building, and then (inappropriately) honored while installing.

Easiest solution would be to confine the option to linux. (Still hoping to verify the approach with a test-build, though. Let's see if my (virtual) disk space is large enough, this time).