[packages/wpe-webkit] - new

qboosh qboosh at pld-linux.org
Tue Mar 3 21:44:24 CET 2020


commit 8dd135444b248f274251b3c0a0550594e74d8e1e
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Tue Mar 3 21:45:09 2020 +0100

    - new

 wpe-webkit-x32.patch |  37 +++++++++
 wpe-webkit.spec      | 223 +++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 260 insertions(+)
---
diff --git a/wpe-webkit.spec b/wpe-webkit.spec
new file mode 100644
index 0000000..f5d797d
--- /dev/null
+++ b/wpe-webkit.spec
@@ -0,0 +1,223 @@
+# TODO: review configure options:
+# - FTL_JIT on !x86_64?
+# - WEB_RTC+MEDIA_STREAM (BR: openwebrtc)
+#
+# Conditional build:
+%bcond_with	cairogl		# accelerated 2D canvas using cairo-gl
+#
+# it's not possible to build this with debuginfo on 32bit archs due to
+# memory constraints during linking
+%ifarch %{ix86} x32
+%define		_enable_debug_packages		0
+%endif
+Summary:	Port of WebKit embeddable web component to WPE
+Summary(pl.UTF-8):	Port osadzalnego komponentu WWW WebKit do WPE
+Name:		wpe-webkit
+# NOTE: 2.26.x is stable, 2.27.x devel (see DEVEL-2.27 branch)
+Version:	2.26.4
+Release:	1
+License:	BSD-like
+Group:		X11/Libraries
+Source0:	https://wpewebkit.org/releases/wpewebkit-%{version}.tar.xz
+# Source0-md5:	4cd2883ec9da38a0ffe413bb75239874
+Patch0:		%{name}-x32.patch
+URL:		https://wpewebkit.org/
+BuildRequires:	/usr/bin/ld.gold
+BuildRequires:	EGL-devel
+BuildRequires:	OpenGLESv2-devel
+BuildRequires:	at-spi2-atk-devel >= 2.5.3
+BuildRequires:	atk-devel >= 1:2.16.0
+BuildRequires:	bubblewrap >= 0.3.1
+BuildRequires:	cairo-devel >= 1.16.0
+BuildRequires:	cmake >= 3.10
+BuildRequires:	docbook-dtd412-xml
+BuildRequires:	fontconfig-devel >= 2.13.0
+BuildRequires:	freetype-devel >= 1:2.9.0
+BuildRequires:	gcc-c++ >= 6:7.3.0
+BuildRequires:	glib2-devel >= 1:2.44
+BuildRequires:	glibc-misc
+BuildRequires:	gperf >= 3.0.1
+BuildRequires:	gstreamer-devel >= 1.14
+BuildRequires:	gstreamer-gl-devel >= 1.10.0
+# codecparsers,mpegts with -DUSE_GSTREAMER_MPEGTS=ON
+#BuildRequires:	gstreamer-plugins-bad-devel >= 1.10.0
+# app,audio,fft,pbutils,tag,video
+BuildRequires:	gstreamer-plugins-base-devel >= 1.10.0
+BuildRequires:	gtk-doc >= 1.10
+BuildRequires:	harfbuzz-devel >= 1.4.2
+BuildRequires:	harfbuzz-icu-devel >= 1.4.2
+BuildRequires:	libepoxy-devel >= 1.4.0
+BuildRequires:	libgcrypt-devel >= 1.7.0
+BuildRequires:	libicu-devel >= 59
+BuildRequires:	libjpeg-devel
+BuildRequires:	libpng-devel
+BuildRequires:	libseccomp-devel
+BuildRequires:	libsoup-devel >= 2.54.0
+BuildRequires:	libstdc++-devel >= 6:7.3.0
+BuildRequires:	libtasn1-devel
+BuildRequires:	libwebp-devel
+BuildRequires:	libwpe-devel >= 1.3.0
+BuildRequires:	libxml2-devel >= 1:2.8.0
+BuildRequires:	libxslt-devel >= 1.1.7
+BuildRequires:	openjpeg2-devel >= 2.2.0
+BuildRequires:	perl-base >= 1:5.10.0
+BuildRequires:	pkgconfig
+%if %{with cairogl}
+BuildRequires:	pkgconfig(cairo-egl) >= 1.10.2
+BuildRequires:	pkgconfig(cairo-gl) >= 1.10.2
+BuildRequires:	pkgconfig(cairo-glx) >= 1.10.2
+%endif
+BuildRequires:	python >= 1:2.7.0
+BuildRequires:	rpmbuild(macros) >= 1.699
+BuildRequires:	ruby >= 1:1.9
+BuildRequires:	ruby-modules >= 1:1.9
+BuildRequires:	sqlite3-devel >= 3
+BuildRequires:	tar >= 1:1.22
+BuildRequires:	wayland-devel
+BuildRequires:	wayland-egl-devel
+BuildRequires:	wpebackend-fdo-devel >= 1.3.0
+BuildRequires:	woff2-devel >= 1.0.2
+BuildRequires:	xdg-dbus-proxy
+BuildRequires:	xorg-lib-libICE-devel
+BuildRequires:	xorg-lib-libXcomposite-devel
+BuildRequires:	xorg-lib-libXdamage-devel
+BuildRequires:	xorg-lib-libXext-devel
+BuildRequires:	xorg-lib-libXrender-devel
+BuildRequires:	xorg-lib-libXt-devel
+BuildRequires:	xz
+BuildRequires:	zlib-devel
+Requires:	at-spi2-atk-libs >= 2.5.3
+Requires:	atk >= 1:2.16.0
+Requires:	cairo >= 1.16.0
+Requires:	fontconfig-libs >= 2.13.0
+Requires:	freetype >= 1:2.9.0
+Requires:	glib2 >= 1:2.44
+Requires:	gstreamer >= 1.2.3
+Requires:	gstreamer-plugins-base >= 1.2.3
+Requires:	harfbuzz >= 1.4.2
+Requires:	libepoxy >= 1.4.0
+Requires:	libgcrypt >= 1.7.0
+Requires:	libsoup >= 2.54.0
+Requires:	libxml2 >= 1:2.8.0
+Requires:	libxslt >= 1.1.7
+Requires:	openjpeg2 >= 2.2.0
+Requires:	woff2 >= 1.0.2
+# Source/JavaScriptCore/CMakeLists.txt /WTF_CPU_
+ExclusiveArch:	%{ix86} %{x8664} x32 %{arm} aarch64 hppa mips ppc ppc64 ppc64le s390 s390x sh4
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+wpe-webkit is a port of the WebKit embeddable web component to WPE.
+
+WPE (Webkit Port for Embedded) is the reference WebKit port for
+embedded and low-consumption computer devices.
+
+%description -l pl.UTF-8
+wpe-webkit to port osadzalnego komponentu WWW WebKit do WPE.
+
+WPE (Webkit Port for Embedded) to wzorcowy port biblioteki WebKit dla
+urządzeń komputerowych wbudowanych oraz o niskim poborze energii.
+
+%package devel
+Summary:	Development files for WebKit for WPE
+Summary(pl.UTF-8):	Pliki programistyczne komponentu WebKit dla WPE
+Group:		X11/Development/Libraries
+Requires:	%{name} = %{version}-%{release}
+Requires:	glib2-devel >= 1:2.44
+Requires:	libsoup-devel >= 2.54.0
+Requires:	libstdc++-devel >= 6:7.3.0
+Requires:	libwpe-devel >= 1.3.0
+
+%description devel
+Development files for WebKit for WPE.
+
+%description devel -l pl.UTF-8
+Pliki programistyczne komponentu WebKit dla WPE.
+
+%package apidocs
+Summary:	WebKit API documentation
+Summary(pl.UTF-8):	Dokumentacja API WebKita
+Group:		Documentation
+Requires:	gtk-doc-common
+%if "%{_rpmversion}" >= "5"
+BuildArch:	noarch
+%endif
+
+%description apidocs
+WebKit API documentation.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API WebKita.
+
+%prep
+%setup -q -n wpewebkit-%{version}
+%patch0 -p1
+
+%build
+install -d build
+cd build
+%cmake .. \
+	%{?with_cairogl:-DENABLE_ACCELERATED_2D_CANVAS=ON} \
+	-DENABLE_GEOLOCATION=ON \
+	-DENABLE_GTKDOC=ON \
+%ifarch x32
+	-DENABLE_C_LOOP=ON \
+	-DENABLE_JIT=OFF \
+	-DENABLE_SAMPLING_PROFILER=OFF \
+%endif
+	-DENABLE_VIDEO=ON \
+	-DENABLE_WEB_AUDIO=ON \
+	-DENABLE_WEBGL=ON \
+%ifarch %{ix86} %{x8664} x32
+	-DHAVE_SSE2_EXTENSIONS=ON \
+%endif
+	-DPORT=WPE \
+	-DSHOULD_INSTALL_JS_SHELL=ON
+
+%{__make}
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%{__make} -C build install \
+	DESTDIR=$RPM_BUILD_ROOT
+
+%if "%{_gtkdocdir}" != "%{_datadir}/gtk-doc/html"
+install -d $RPM_BUILD_ROOT%{_gtkdocdir}
+%{__mv} $RPM_BUILD_ROOT%{_datadir}/gtk-doc/html/* $RPM_BUILD_ROOT%{_gtkdocdir}
+%endif
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post	-p /sbin/ldconfig
+%postun	-p /sbin/ldconfig
+
+%files
+%defattr(644,root,root,755)
+%doc NEWS
+%attr(755,root,root) %{_bindir}/WPEWebDriver
+%attr(755,root,root) %{_libdir}/libWPEWebKit-1.0.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libWPEWebKit-1.0.so.3
+%if "%{_libexecdir}" != "%{_libdir}"
+%dir %{_libexecdir}/wpe-webkit-1.0
+%endif
+%attr(755,root,root) %{_libexecdir}/wpe-webkit-1.0/WPENetworkProcess
+%attr(755,root,root) %{_libexecdir}/wpe-webkit-1.0/WPEWebProcess
+%attr(755,root,root) %{_libexecdir}/wpe-webkit-1.0/jsc
+%dir %{_libdir}/wpe-webkit-1.0
+%attr(755,root,root) %{_libdir}/wpe-webkit-1.0/libWPEWebInspectorResources.so
+%dir %{_libdir}/wpe-webkit-1.0/injected-bundle
+%attr(755,root,root) %{_libdir}/wpe-webkit-1.0/injected-bundle/libWPEInjectedBundle.so
+
+%files devel
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libWPEWebKit-1.0.so
+%{_includedir}/wpe-webkit-1.0
+%{_pkgconfigdir}/wpe-web-extension-1.0.pc
+%{_pkgconfigdir}/wpe-webkit-1.0.pc
+
+%files apidocs
+%defattr(644,root,root,755)
+%{_gtkdocdir}/wpe-1.0
+%{_gtkdocdir}/wpe-webextensions-1.0
diff --git a/wpe-webkit-x32.patch b/wpe-webkit-x32.patch
new file mode 100644
index 0000000..715a4ff
--- /dev/null
+++ b/wpe-webkit-x32.patch
@@ -0,0 +1,37 @@
+From: Alberto Garcia <berto at igalia.com>
+Description: Use WTF_CPU_UNKNOWN when building for X32
+ WebKitGTK doesn't build on X32 even with the JIT disabled.
+ Treating the CPU as unknown is perhaps a bit severe, but it allows us
+ to get the build done until someone steps up to maintain this
+ properly.
+Forwarded: no
+Index: webkitgtk/Source/WTF/wtf/Platform.h
+===================================================================
+--- webkitgtk.orig/Source/WTF/wtf/Platform.h
++++ webkitgtk/Source/WTF/wtf/Platform.h
+@@ -142,10 +142,12 @@
+ /* CPU(X86_64) - AMD64 / Intel64 / x86_64 64-bit */
+ #if   defined(__x86_64__) \
+     || defined(_M_X64)
++#if !defined(__ILP32__)
+ #define WTF_CPU_X86_64 1
+ #define WTF_CPU_X86_SSE2 1
+ #define WTF_CPU_KNOWN 1
+ #endif
++#endif
+ 
+ /* CPU(ARM64) - Apple */
+ #if (defined(__arm64__) && defined(__APPLE__)) || defined(__aarch64__)
+Index: webkitgtk/CMakeLists.txt
+===================================================================
+--- webkitgtk.orig/CMakeLists.txt
++++ webkitgtk/CMakeLists.txt
+@@ -93,6 +93,8 @@ elseif (LOWERCASE_CMAKE_SYSTEM_PROCESSOR
+     set(WTF_CPU_MIPS64 1)
+ elseif (LOWERCASE_CMAKE_SYSTEM_PROCESSOR MATCHES "^mips")
+     set(WTF_CPU_MIPS 1)
++elseif (CMAKE_CXX_COMPILER_ABI STREQUAL "ELF X32")
++    set(WTF_CPU_UNKNOWN 1)
+ elseif (LOWERCASE_CMAKE_SYSTEM_PROCESSOR MATCHES "(x64|x86_64|amd64)")
+     # FORCE_32BIT is set in the build script when --32-bit is passed
+     # on a Linux/intel 64bit host. This allows us to produce 32bit
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/wpe-webkit.git/commitdiff/8dd135444b248f274251b3c0a0550594e74d8e1e



More information about the pld-cvs-commit mailing list