PKGNAME=zen-browser
PKGSEC=web
PKGDES="A Firefox-based browser with the aim of improving your productivity"
PKGDEP="gtk-3 startup-notification dbus-glib alsa-lib \
        desktop-file-utils hicolor-icon-theme libevent nss hunspell sqlite \
        networkmanager mozilla-common ffmpeg icu openh264"
BUILDDEP="autoconf-2.13 rustc unzip llvm mercurial nodejs libnotify \
          xorg-server nasm yasm cbindgen llvm-runtime+wasi libvips"

ABTYPE=self
USECLANG=1

# FIXME: STL code can only be used with -fno-exceptions
AB_FLAGS_EXC=0

# Too heavy for your average 512M-RAM 2K0300
# FIXME: Build fails on ppc64el:
# /var/cache/acbs/build/acbs.cq00dgxc/zen-browser/engine/mozglue/build/ppc.cpp:56:1: error: Global variable has runtime initialisation, try to remove it, make it constexpr or constinit if possible, or as a last resort flag it as MOZ_RUNINIT.
# 00:33:16 E    56 | bool vmx_enabled = !!(get_ppc_cpu_flags() & PPC_FLAG_VMX);
# 00:33:16 E       | ^
# 00:33:16 E /var/cache/acbs/build/acbs.cq00dgxc/zen-browser/engine/mozglue/build/ppc.cpp:57:1: error: Global variable has runtime initialisation, try to remove it, make it constexpr or constinit if possible, or as a last resort flag it as MOZ_RUNINIT.
# 00:33:16 E    57 | bool vsx_enabled = !!(get_ppc_cpu_flags() & PPC_FLAG_VSX);
# 00:33:16 E       | ^
# 00:33:16 E /var/cache/acbs/build/acbs.cq00dgxc/zen-browser/engine/mozglue/build/ppc.cpp:58:1: error: Global variable has runtime initialisation, try to remove it, make it constexpr or constinit if possible, or as a last resort flag it as MOZ_RUNINIT.
# 00:33:16 E    58 | bool vsx3_enabled = !!(get_ppc_cpu_flags() & PPC_FLAG_VSX3);
# 00:33:16 E       | ^
# 00:33:16 E 3 errors generated.
# 00:33:16 E make[4]: *** [/var/cache/acbs/build/acbs.cq00dgxc/zen-browser/engine/config/rules.mk:668: ppc.o] Error 1
FAIL_ARCH="@(loongarch64_nosimd|ppc64el)"
