blob: c20c578f33226742a28b50942a464cbf630afdb4 (
plain)
1 # Description: Small, efficient and fast rendering engine for Web Browsers.
2 # URL: https://www.webkitgtk.org/
3 # Maintainer: Aaron Ball, nullspoon at oper dot io
4 # Depends on: gst-plugins-base gtk4 hyphen icu lcms2 libseccomp libsecret libsoup3 xorg-libxcomposite libwebp libxslt ruby woff2 xorg-libxt gi-docgen openjpeg2 libnotify enchant unifdef libavif bubblewrap xdg-dbus-proxy libjxl
5 # Optional:
6
7 name=webkitgtk-6.0
8 #version=2.43.4 # Stable
9 version=2.44.1 # Unstable
10 release=3
11 source=(https://webkitgtk.org/releases/webkitgtk-${version}.tar.xz
12 pipewire.patch)
13
14 build() {
15 # fail the build if dependencies are not met
16 if [ ! -f /usr/include/harfbuzz/hb-icu.h ]; then
17 printf '\e[1;31mYou need to install icu, then rebuild harfbuzz for webkitgtk to work, quitting...\e[m\n' >&2
18 return 1
19 fi
20
21 # Bug: https://bugs.webkit.org/show_bug.cgi?id=239682
22 # Fix: https://github.com/WebKit/WebKit/pull/5671
23 # Without this, the pipewire socket cannot be accessed because of bubblewrap
24 patch \
25 webkitgtk-${version}/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp \
26 pipewire.patch
27
28 export CFLAGS='-g1'
29 export CXXFLAGS='-g1'
30
31 cmake -S webkitgtk-${version} -B build -G Ninja \
32 -D CMAKE_INSTALL_PREFIX:PATH=/usr \
33 -D CMAKE_INSTALL_LIBDIR:PATH=/usr/lib \
34 -D CMAKE_INSTALL_LIBEXECDIR:PATH=/usr/lib \
35 -D CMAKE_BUILD_TYPE=Release \
36 -D USE_AVIF=ON \
37 -D PORT=GTK \
38 -D USE_GTK4=ON \
39 -D USE_GSTREAMER_TRANSCODER=ON \
40 -D ENABLE_MINIBROWSER=ON \
41 -D USE_LIBBACKTRACE=OFF \
42 -D ENABLE_GAMEPAD=OFF \
43 -D ENABLE_INTROSPECTION=OFF \
44 -D ENABLE_JOURNALD_LOG=OFF \
45 -D ENABLE_X11_TARGET=OFF \
46 -D ENABLE_WEBINSPECTORUI=ON \
47 -D ENABLE_WAYLAND_TARGET=ON
48
49 cmake --build build
50 DESTDIR=$PKG cmake --install build
51
52 rm -r $PKG/usr/share/locale
53 }
|