summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dev-qt/qtwebengine/files/build_fix.patch13
-rw-r--r--dev-qt/qtwebengine/files/build_fix2.patch20
-rw-r--r--dev-qt/qtwebengine/files/qtwebengine-5.9.0-paxmark-mksnapshot.patch46
-rw-r--r--dev-qt/qtwebengine/files/qtwebengine-paxmark-mksnapshot.patch46
-rw-r--r--dev-qt/qtwebengine/metadata.xml27
-rw-r--r--dev-qt/qtwebengine/qtwebengine-5.9.9999-r1.ebuild115
6 files changed, 267 insertions, 0 deletions
diff --git a/dev-qt/qtwebengine/files/build_fix.patch b/dev-qt/qtwebengine/files/build_fix.patch
new file mode 100644
index 0000000..926e685
--- /dev/null
+++ b/dev-qt/qtwebengine/files/build_fix.patch
@@ -0,0 +1,13 @@
+diff -Naur qtwebengine-5.9.9999.orig/src/core/api/qwebengineurlrequestinfo.h qtwebengine-5.9.9999/src/core/api/qwebengineurlrequestinfo.h
+--- a/src/core/api/qwebengineurlrequestinfo.h 2017-07-09 16:18:41.375836372 +0300
++++ b/src/core/api/qwebengineurlrequestinfo.h 2017-07-09 16:18:11.829833351 +0300
+@@ -75,9 +75,7 @@
+ ResourceTypeServiceWorker, // the main resource of a service worker.
+ ResourceTypeCspReport, // Content Security Policy (CSP) violation report
+ ResourceTypePluginResource, // A resource requested by a plugin
+-#ifndef Q_QDOC
+ ResourceTypeLast,
+-#endif
+ ResourceTypeUnknown = 255
+ };
+
diff --git a/dev-qt/qtwebengine/files/build_fix2.patch b/dev-qt/qtwebengine/files/build_fix2.patch
new file mode 100644
index 0000000..6ba339a
--- /dev/null
+++ b/dev-qt/qtwebengine/files/build_fix2.patch
@@ -0,0 +1,20 @@
+diff -Naur /var/tmp/paludis/dev-qt-qtwebengine-5.9.9999/work/qtwebengine-5.9.9999/src/core/network_delegate_qt.cpp /home/sss/temp/qtwebengine-5.9.9999/src/core/network_delegate_qt.cpp
+--- a/src/core/network_delegate_qt.cpp 2017-07-09 17:37:49.762321907 +0300
++++ b/src/core/network_delegate_qt.cpp 2017-07-09 17:37:14.075318258 +0300
+@@ -55,6 +55,7 @@
+ #include "type_conversion.h"
+ #include "web_contents_adapter_client.h"
+ #include "web_contents_view_qt.h"
++#include <QWebEngineUrlRequestInfo>
+
+ namespace QtWebEngineCore {
+
+@@ -83,7 +84,7 @@
+
+ QWebEngineUrlRequestInfo::ResourceType toQt(content::ResourceType resourceType)
+ {
+- if (resourceType >= 0 && resourceType < content::ResourceType(QWebEngineUrlRequestInfo::ResourceTypeLast))
++ if (resourceType >= 0 && resourceType < content::ResourceType(QWebEngineUrlRequestInfo::ResourceTypeUnknown))
+ return static_cast<QWebEngineUrlRequestInfo::ResourceType>(resourceType);
+ return QWebEngineUrlRequestInfo::ResourceTypeUnknown;
+ }
diff --git a/dev-qt/qtwebengine/files/qtwebengine-5.9.0-paxmark-mksnapshot.patch b/dev-qt/qtwebengine/files/qtwebengine-5.9.0-paxmark-mksnapshot.patch
new file mode 100644
index 0000000..5eb8ce1
--- /dev/null
+++ b/dev-qt/qtwebengine/files/qtwebengine-5.9.0-paxmark-mksnapshot.patch
@@ -0,0 +1,46 @@
+--- a/src/3rdparty/chromium/v8/src/v8.gyp
++++ b/src/3rdparty/chromium/v8/src/v8.gyp
+@@ -36,6 +36,7 @@
+ 'v8_experimental_extra_library_files%': [],
+ 'v8_enable_inspector%': 0,
+ 'mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
++ 'mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot_u<(EXECUTABLE_SUFFIX)',
+ 'mkpeephole_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkpeephole<(EXECUTABLE_SUFFIX)',
+ 'v8_os_page_size%': 0,
+ },
+@@ -2432,7 +2433,7 @@
+ ]
+ },
+ {
+- 'target_name': 'mksnapshot',
++ 'target_name': 'mksnapshot_u',
+ 'type': 'executable',
+ 'dependencies': [
+ 'v8_base',
+@@ -2485,5 +2486,26 @@
+ }],
+ ],
+ },
++ {
++ 'target_name': 'mksnapshot',
++ 'type': 'executable',
++ 'dependencies': ['mksnapshot_u'],
++ 'actions': [
++ {
++ 'action_name': 'paxmark_m_mksnapshot',
++ 'inputs': [
++ '<(mksnapshot_u_exec)',
++ ],
++ 'outputs': [
++ '<(mksnapshot_exec)',
++ ],
++ 'action': [
++ 'sh',
++ '-c',
++ 'cp <(mksnapshot_u_exec) <(mksnapshot_exec) && paxmark.sh m <(mksnapshot_exec)',
++ ],
++ },
++ ],
++ },
+ ],
+ }
diff --git a/dev-qt/qtwebengine/files/qtwebengine-paxmark-mksnapshot.patch b/dev-qt/qtwebengine/files/qtwebengine-paxmark-mksnapshot.patch
new file mode 100644
index 0000000..c71cedc
--- /dev/null
+++ b/dev-qt/qtwebengine/files/qtwebengine-paxmark-mksnapshot.patch
@@ -0,0 +1,46 @@
+--- qtwebengine-opensource-src-5.6.0-orig/src/3rdparty/chromium/v8/tools/gyp/v8.gyp 2016-03-04 01:48:36.000000000 +1100
++++ qtwebengine-opensource-src-5.6.0/src/3rdparty/chromium/v8/tools/gyp/v8.gyp 2016-05-01 19:15:44.052770543 +1000
+@@ -33,6 +33,7 @@
+ 'embed_script%': "",
+ 'v8_extra_library_files%': [],
+ 'mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
++ 'mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot_u<(EXECUTABLE_SUFFIX)',
+ 'remove_v8base_debug_symbols%': 0,
+ },
+ 'includes': ['../../build/toolchain.gypi', '../../build/features.gypi'],
+@@ -1913,7 +1914,7 @@
+ ]
+ },
+ {
+- 'target_name': 'mksnapshot',
++ 'target_name': 'mksnapshot_u',
+ 'type': 'executable',
+ 'dependencies': ['v8_base', 'v8_nosnapshot', 'v8_libplatform'],
+ 'include_dirs+': [
+@@ -1936,5 +1937,26 @@
+ }],
+ ],
+ },
++ {
++ 'target_name': 'mksnapshot',
++ 'type': 'executable',
++ 'dependencies': ['mksnapshot_u'],
++ 'actions': [
++ {
++ 'action_name': 'paxmark_m_mksnapshot',
++ 'inputs': [
++ '<(mksnapshot_u_exec)',
++ ],
++ 'outputs': [
++ '<(mksnapshot_exec)',
++ ],
++ 'action': [
++ 'sh',
++ '-c',
++ 'cp <(mksnapshot_u_exec) <(mksnapshot_exec) && paxmark.sh m <(mksnapshot_exec)',
++ ],
++ },
++ ],
++ },
+ ],
+ }
diff --git a/dev-qt/qtwebengine/metadata.xml b/dev-qt/qtwebengine/metadata.xml
new file mode 100644
index 0000000..9c08bb1
--- /dev/null
+++ b/dev-qt/qtwebengine/metadata.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>qt@gentoo.org</email>
+ <name>Gentoo Qt Project</name>
+ </maintainer>
+ <use>
+ <flag name="geolocation">Enable physical position determination
+ via <pkg>dev-qt/qtpositioning</pkg></flag>
+ <flag name="pax_kernel">Enable building under a PaX enabled kernel</flag>
+ <flag name="system-ffmpeg">Use the system-wide <pkg>media-video/ffmpeg</pkg>
+ instead of bundled.</flag>
+ <flag name="system-icu">Use the system-wide <pkg>dev-libs/icu</pkg>
+ instead of bundled.</flag>
+ <flag name="widgets">Enable QtWidgets support</flag>
+ </use>
+ <upstream>
+ <bugs-to>https://bugreports.qt.io/</bugs-to>
+ <doc>http://doc.qt.io/</doc>
+ </upstream>
+ <slots>
+ <subslots>
+ Must only be used by packages that are known to use private parts of the Qt API.
+ </subslots>
+ </slots>
+</pkgmetadata>
diff --git a/dev-qt/qtwebengine/qtwebengine-5.9.9999-r1.ebuild b/dev-qt/qtwebengine/qtwebengine-5.9.9999-r1.ebuild
new file mode 100644
index 0000000..cd913e8
--- /dev/null
+++ b/dev-qt/qtwebengine/qtwebengine-5.9.9999-r1.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+PYTHON_COMPAT=( python2_7 )
+inherit multiprocessing pax-utils python-any-r1 qt5-build
+
+DESCRIPTION="Library for rendering dynamic web content in Qt5 C++ and QML applications"
+
+if [[ ${QT5_BUILD_TYPE} == release ]]; then
+ KEYWORDS="~amd64 ~arm64 ~x86"
+fi
+
+IUSE="alsa bindist geolocation pax_kernel pulseaudio +system-ffmpeg +system-icu widgets"
+
+RDEPEND="
+ app-arch/snappy
+ dev-libs/glib:2
+ dev-libs/nspr
+ dev-libs/nss
+ ~dev-qt/qtcore-${PV}
+ ~dev-qt/qtdeclarative-${PV}
+ ~dev-qt/qtgui-${PV}
+ ~dev-qt/qtnetwork-${PV}
+ ~dev-qt/qtwebchannel-${PV}[qml]
+ dev-libs/expat
+ dev-libs/libevent:=
+ dev-libs/libxml2
+ dev-libs/libxslt
+ dev-libs/protobuf:=
+ media-libs/fontconfig
+ media-libs/freetype
+ media-libs/harfbuzz:=
+ media-libs/libpng:0=
+ >=media-libs/libvpx-1.5:=[svc]
+ media-libs/libwebp:=
+ media-libs/mesa
+ media-libs/opus
+ net-libs/libsrtp:0=
+ sys-apps/dbus
+ sys-apps/pciutils
+ sys-libs/libcap
+ sys-libs/zlib[minizip]
+ virtual/jpeg:0
+ virtual/libudev
+ x11-libs/libdrm
+ x11-libs/libX11
+ x11-libs/libXcomposite
+ x11-libs/libXcursor
+ x11-libs/libXdamage
+ x11-libs/libXext
+ x11-libs/libXfixes
+ x11-libs/libXi
+ x11-libs/libXrandr
+ x11-libs/libXrender
+ x11-libs/libXScrnSaver
+ x11-libs/libXtst
+ alsa? ( media-libs/alsa-lib )
+ geolocation? ( ~dev-qt/qtpositioning-${PV} )
+ pulseaudio? ( media-sound/pulseaudio:= )
+ system-ffmpeg? ( media-video/ffmpeg:0= )
+ system-icu? ( dev-libs/icu:= )
+ widgets? ( ~dev-qt/qtwidgets-${PV} )
+"
+DEPEND="${RDEPEND}
+ ${PYTHON_DEPS}
+ dev-util/gperf
+ dev-util/ninja
+ dev-util/re2c
+ sys-devel/bison
+ pax_kernel? ( sys-apps/elfix )
+"
+
+src_prepare() {
+ use pax_kernel && PATCHES+=( "${FILESDIR}/${PN}-5.9.0-paxmark-mksnapshot.patch" )
+ PATCHES+=(
+ "${FILESDIR}/build_fix.patch"
+ "${FILESDIR}/build_fix2.patch"
+ )
+
+ qt_use_disable_config alsa alsa src/core/config/linux.pri
+ qt_use_disable_config pulseaudio pulseaudio src/core/config/linux.pri
+
+ qt_use_disable_mod geolocation positioning \
+ mkspecs/features/configure.prf \
+ src/core/core_chromium.pri \
+ src/core/core_common.pri
+
+ qt_use_disable_mod widgets widgets src/src.pro
+
+ qt5-build_src_prepare
+}
+
+src_configure() {
+ export NINJA_PATH=/usr/bin/ninja
+ export NINJAFLAGS="${NINJAFLAGS:--j$(makeopts_jobs) -l$(makeopts_loadavg "${MAKEOPTS}" 0) -v}"
+
+ local myqmakeargs=(
+ $(usex bindist '' 'WEBENGINE_CONFIG+=use_proprietary_codecs')
+ $(usex system-ffmpeg 'WEBENGINE_CONFIG+=use_system_ffmpeg' '')
+ $(usex system-icu 'WEBENGINE_CONFIG+=use_system_icu' '')
+ )
+ qt5-build_src_configure
+}
+
+src_install() {
+ qt5-build_src_install
+
+ # bug 601472
+ if [[ ! -f ${D%/}${QT5_LIBDIR}/libQt5WebEngine.so ]]; then
+ die "${CATEGORY}/${PF} failed to build anything. Please report to https://bugs.gentoo.org/"
+ fi
+
+ pax-mark m "${D%/}${QT5_LIBEXECDIR}"/QtWebEngineProcess
+}