How To Use WebKit 6 (2.40.1) In Snaps

I have successfully snapped wike, a popular gtk client for wikipedia, but the app uses the latest webkit6 and sadly the gnome-sdk 42 doesnt offer it, and there is no way i believe i can stage packages from lunar or mantic ?? So i tried building it from source, and fails after two hours with the following error ;

error: ‘isnan’ was not declared in this scope; did you mean ‘std::isnan’?

Here is the build-log --> https://launchpadlibrarian.net/667530941/buildlog_snap_ubuntu_jammy_amd64_37e1ff448535683247d63ef4f5760db6_BUILDING.txt.gz

I request some urgent lookup here as this isnt a problem from my side, this is a error due to lack of webkit6 in the snap gnome sdk etc.

Without webkit6, this happens;

File "/snap/wike/current/usr/share/wike/wike/application.py", line 12, in <module>
    gi.require_version('WebKit', '6.0')
  File "/snap/wike/47/gnome-platform/usr/lib/python3/dist-packages/gi/__init__.py", line 126, in require_version
    raise ValueError('Namespace %s not available' % namespace)
ValueError: Namespace WebKit not available

isnan is C99 while std:isnan is C++11… you might need to use a different -std= option for gcc here …

i suspect webkit6 in a packaged form will likely not be available before core24 … you could use a PPA to backport it though …

Thanks for the insight,I think building directly from source in a snap is the best bet as i dont think the ppa will be more viable. This thing of waiting for next LTS core is just a hindrance in packaging apps requiring cutting edge, i think a better solution for such apps would be to provide core based on upon interim release(9 months-kinetic,lunar) with a short span of support and such core shouldn’t be used for enterprise or projects needing stability etc.

Flatpak has unfortunately gnome-44 runtime, wished we could too take such measures, as also another app loupe is stuck due to need for latest gtk4 beta version.

I give up, I couldnt build latest wike version but thats not a error from my side its due to lack of latest webkit in gnome-sdk, and since i always get a impression of building broken snaps, even though the fault is usually of the snap architecture itself(Python plugin broken, permission error, latest toolkits not available etc.) i simply build an older version using older webkit to at-least shed off my wrong and improper impression

Edit: Removed the issue thats not due to the snap architecture

libpango-1.0.so.0: undefined symbol: hb_ot_color_has_paint

This is clearly an error with you including a wrong harfbuzz version while the extension already ships one of a different version… just make sure to not ship it and let the extension do its job…

I agree but sometimes these deps automatically come in as deps for other needed libs, i have fixed that one for celluloid but it still occurs in komikku (I will resolve it later)

well, yes, that is what being a packager means, you dig up and sort out such discrepancies :wink:

1 Like