summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-15 19:14:10 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-15 19:14:10 +0100
commitb0678711aadd72fd454634f42c5beff934e69a66 (patch)
tree889bc5d0d11ced892fd71be7f19d5dd07c645729
parentb2842112832e3fe38bc7fceb1b3db4b24264e542 (diff)
Revert "www-client/qupzilla : drop our ebuild, since the fullscreen patch is now included in the latest release"
This reverts commit aa72a0236bd72d145f1671803a66639896a3575a.
-rw-r--r--www-client/qupzilla/Manifest2
-rw-r--r--www-client/qupzilla/files/qupzilla-2.1.2-fullscreen.patch102
-rw-r--r--www-client/qupzilla/files/qupzilla-2.1.2-openssl-1.1.0.patch103
-rw-r--r--www-client/qupzilla/qupzilla-2.1.2.ebuild110
4 files changed, 317 insertions, 0 deletions
diff --git a/www-client/qupzilla/Manifest b/www-client/qupzilla/Manifest
new file mode 100644
index 00000000..120c8704
--- /dev/null
+++ b/www-client/qupzilla/Manifest
@@ -0,0 +1,2 @@
+DIST QupZilla-2.1.2.tar.xz 2767560 SHA256 d8f860d8c41bbf2bf78889aef3ffed118a34b2754f7e114ad44eb2c6103ee58a SHA512 d09a394ba70ae0f7f908940a26d6554a3706b6638c197d16b75e1e5855f76015c8e13b7155c40dacee3a38080a0c277d9410eaf07cf912dc4b295eafe1ff6343 WHIRLPOOL 1da85e81854d41e62bd28b71e9509571c789cc73c2a550a7165efa9dc65bb1099f8de17dafcdbbbcdf6498403e5e8458a82042f1090355c4df67144cb4fed59b
+DIST qupzilla-plugins-2016.05.02.tar.gz 425314 SHA256 276491a89daf1b64d6eab861b54d313e85c815d322bf51d47491f00ad22f55bc SHA512 b294ecb2372b3267603a43bc7412ab75d2cd29a8c4667331f0d2c74e3b0b99d0c2a005b9e4854c6d777894522bba9fb3b1607e85e8da6dcbaa760c9ddc6288f2 WHIRLPOOL 471807dc70dd3ea072f1e429a6e67ea97ecd5eadc02ac19debdcddfca4f5cb8e1767ad754aed1ff8a557f0734460a87b4e2d5e01ea57d07c473f48b006e32ef1
diff --git a/www-client/qupzilla/files/qupzilla-2.1.2-fullscreen.patch b/www-client/qupzilla/files/qupzilla-2.1.2-fullscreen.patch
new file mode 100644
index 00000000..c18b4210
--- /dev/null
+++ b/www-client/qupzilla/files/qupzilla-2.1.2-fullscreen.patch
@@ -0,0 +1,102 @@
+From 5812721e4822ae363866df2cc9fc762b25061c92 Mon Sep 17 00:00:00 2001
+From: David Rosca <nowrep@gmail.com>
+Date: Sat, 19 Aug 2017 18:52:26 +0200
+Subject: [PATCH] BrowserWindow: Fix failing to enter fullscreen sometimes
+
+---
+ src/lib/app/browserwindow.cpp | 23 ++++++++++++++++-------
+ src/lib/app/browserwindow.h | 5 ++++-
+ 2 files changed, 20 insertions(+), 8 deletions(-)
+
+diff --git a/src/lib/app/browserwindow.cpp b/src/lib/app/browserwindow.cpp
+index 1eab597d7..2a41fddf2 100644
+--- a/src/lib/app/browserwindow.cpp
++++ b/src/lib/app/browserwindow.cpp
+@@ -683,6 +683,15 @@ void BrowserWindow::showSource(WebView *view)
+ view->showSource();
+ }
+
++void BrowserWindow::showNormal()
++{
++ if (m_normalWindowState & Qt::WindowMaximized) {
++ QMainWindow::showMaximized();
++ } else {
++ QMainWindow::showNormal();
++ }
++}
++
+ SideBar* BrowserWindow::addSideBar()
+ {
+ if (m_sideBar) {
+@@ -786,9 +795,9 @@ void BrowserWindow::toggleFullScreen()
+ }
+
+ if (isFullScreen())
+- setWindowState(windowState() & ~Qt::WindowFullScreen);
++ showNormal();
+ else
+- setWindowState(windowState() | Qt::WindowFullScreen);
++ showFullScreen();
+ }
+
+ void BrowserWindow::enterHtmlFullScreen()
+@@ -1049,9 +1058,9 @@ bool BrowserWindow::event(QEvent* event)
+ case QEvent::WindowStateChange: {
+ QWindowStateChangeEvent* ev = static_cast<QWindowStateChangeEvent*>(event);
+
+- if (!(ev->oldState() & Qt::WindowFullScreen) && windowState() & Qt::WindowFullScreen) {
++ if (!(m_oldWindowState & Qt::WindowFullScreen) && windowState() & Qt::WindowFullScreen) {
+ // Enter fullscreen
+- m_windowStates = ev->oldState();
++ m_normalWindowState = m_oldWindowState;
+
+ m_statusBarVisible = statusBar()->isVisible();
+ #ifndef Q_OS_MACOS
+@@ -1063,7 +1072,7 @@ bool BrowserWindow::event(QEvent* event)
+ m_navigationContainer->hide();
+ m_navigationToolbar->buttonExitFullscreen()->show();
+ }
+- else if (ev->oldState() & Qt::WindowFullScreen && !(windowState() & Qt::WindowFullScreen)) {
++ else if (m_oldWindowState & Qt::WindowFullScreen && !(windowState() & Qt::WindowFullScreen)) {
+ // Leave fullscreen
+ statusBar()->setVisible(m_statusBarVisible);
+ #ifndef Q_OS_MACOS
+@@ -1074,13 +1083,13 @@ bool BrowserWindow::event(QEvent* event)
+ m_navigationToolbar->setSuperMenuVisible(!m_menuBarVisible);
+ m_navigationToolbar->buttonExitFullscreen()->hide();
+ m_isHtmlFullScreen = false;
+-
+- setWindowState(m_windowStates);
+ }
+
+ if (m_hideNavigationTimer) {
+ m_hideNavigationTimer->stop();
+ }
++
++ m_oldWindowState = windowState();
+ break;
+ }
+
+diff --git a/src/lib/app/browserwindow.h b/src/lib/app/browserwindow.h
+index 51d4023ce..5e326fc34 100644
+--- a/src/lib/app/browserwindow.h
++++ b/src/lib/app/browserwindow.h
+@@ -141,6 +141,8 @@ public slots:
+ void loadAddress(const QUrl &url);
+ void showSource(WebView *view = Q_NULLPTR);
+
++ void showNormal();
++
+ private slots:
+ void addTab();
+ void openLocation();
+@@ -211,7 +213,8 @@ private slots:
+ bool m_menuBarVisible;
+ bool m_statusBarVisible;
+ bool m_isHtmlFullScreen;
+- Qt::WindowStates m_windowStates;
++ Qt::WindowStates m_oldWindowState = Qt::WindowNoState;
++ Qt::WindowStates m_normalWindowState = Qt::WindowNoState;
+ QTimer* m_hideNavigationTimer;
+
+ QList<QPointer<QWidget> > m_deleteOnCloseWidgets;
diff --git a/www-client/qupzilla/files/qupzilla-2.1.2-openssl-1.1.0.patch b/www-client/qupzilla/files/qupzilla-2.1.2-openssl-1.1.0.patch
new file mode 100644
index 00000000..42effa56
--- /dev/null
+++ b/www-client/qupzilla/files/qupzilla-2.1.2-openssl-1.1.0.patch
@@ -0,0 +1,103 @@
+From efc4725e91e10ccfef257143408d3a683e74a866 Mon Sep 17 00:00:00 2001
+From: Jose Rios <joseriosneto@protonmail.com>
+Date: Mon, 1 May 2017 02:12:26 +0100
+Subject: [PATCH] Fixed compilation for Openssl 1.1.0
+
+Most of libcrypto and libssl internal structures were made
+opaque in this version not allowing to instatiate them in
+the stack.
+
+More info:
+ * https://www.openssl.org/news/openssl-1.1.0-notes.html
+ * https://github.com/openssl/openssl/issues/962#issuecomment-208792020
+---
+ src/lib/tools/aesinterface.cpp | 28 ++++++++++++++++------------
+ src/lib/tools/aesinterface.h | 4 ++--
+ 2 files changed, 18 insertions(+), 14 deletions(-)
+
+diff --git a/src/lib/tools/aesinterface.cpp b/src/lib/tools/aesinterface.cpp
+index fa33eb3..29ed37e 100644
+--- a/src/lib/tools/aesinterface.cpp
++++ b/src/lib/tools/aesinterface.cpp
+@@ -39,14 +39,18 @@ AesInterface::AesInterface(QObject* parent)
+ : QObject(parent)
+ , m_ok(false)
+ {
+- EVP_CIPHER_CTX_init(&m_encodeCTX);
+- EVP_CIPHER_CTX_init(&m_decodeCTX);
++ m_encodeCTX = EVP_CIPHER_CTX_new();
++ m_decodeCTX = EVP_CIPHER_CTX_new();
++ EVP_CIPHER_CTX_init(m_encodeCTX);
++ EVP_CIPHER_CTX_init(m_decodeCTX);
+ }
+
+ AesInterface::~AesInterface()
+ {
+- EVP_CIPHER_CTX_cleanup(&m_encodeCTX);
+- EVP_CIPHER_CTX_cleanup(&m_decodeCTX);
++ EVP_CIPHER_CTX_cleanup(m_encodeCTX);
++ EVP_CIPHER_CTX_cleanup(m_decodeCTX);
++ EVP_CIPHER_CTX_free(m_encodeCTX);
++ EVP_CIPHER_CTX_free(m_decodeCTX);
+ }
+
+ bool AesInterface::isOk()
+@@ -78,10 +82,10 @@ bool AesInterface::init(int evpMode, const QByteArray &password, const QByteArra
+ int result = 0;
+ if (evpMode == EVP_PKEY_MO_ENCRYPT) {
+ m_iVector = createRandomData(EVP_MAX_IV_LENGTH);
+- result = EVP_EncryptInit_ex(&m_encodeCTX, EVP_aes_256_cbc(), NULL, key, (uchar*)m_iVector.constData());
++ result = EVP_EncryptInit_ex(m_encodeCTX, EVP_aes_256_cbc(), NULL, key, (uchar*)m_iVector.constData());
+ }
+ else if (evpMode == EVP_PKEY_MO_DECRYPT) {
+- result = EVP_DecryptInit_ex(&m_decodeCTX, EVP_aes_256_cbc(), NULL, key, (uchar*)iVector.constData());
++ result = EVP_DecryptInit_ex(m_decodeCTX, EVP_aes_256_cbc(), NULL, key, (uchar*)iVector.constData());
+ }
+
+ if (result == 0) {
+@@ -106,14 +110,14 @@ QByteArray AesInterface::encrypt(const QByteArray &plainData, const QByteArray &
+ uchar* ciphertext = (uchar*)malloc(cipherlength);
+
+ // allows reusing of 'm_encodeCTX' for multiple encryption cycles
+- EVP_EncryptInit_ex(&m_encodeCTX, NULL, NULL, NULL, NULL);
++ EVP_EncryptInit_ex(m_encodeCTX, NULL, NULL, NULL, NULL);
+
+ // update ciphertext, c_len is filled with the length of ciphertext generated,
+ // dataLength is the size of plaintext in bytes
+- EVP_EncryptUpdate(&m_encodeCTX, ciphertext, &cipherlength, (uchar*)plainData.data(), dataLength);
++ EVP_EncryptUpdate(m_encodeCTX, ciphertext, &cipherlength, (uchar*)plainData.data(), dataLength);
+
+ // update ciphertext with the final remaining bytes
+- EVP_EncryptFinal_ex(&m_encodeCTX, ciphertext + cipherlength, &finalLength);
++ EVP_EncryptFinal_ex(m_encodeCTX, ciphertext + cipherlength, &finalLength);
+
+ dataLength = cipherlength + finalLength;
+ QByteArray out((char*)ciphertext, dataLength);
+@@ -163,9 +167,9 @@ QByteArray AesInterface::decrypt(const QByteArray &cipherData, const QByteArray
+ // because we have padding ON, we must allocate an extra cipher block size of memory
+ uchar* plainText = (uchar*)malloc(plainTextLength + AES_BLOCK_SIZE);
+
+- EVP_DecryptInit_ex(&m_decodeCTX, NULL, NULL, NULL, NULL);
+- EVP_DecryptUpdate(&m_decodeCTX, plainText, &plainTextLength, cipherText, cipherLength);
+- int success = EVP_DecryptFinal_ex(&m_decodeCTX, plainText + plainTextLength, &finalLength);
++ EVP_DecryptInit_ex(m_decodeCTX, NULL, NULL, NULL, NULL);
++ EVP_DecryptUpdate(m_decodeCTX, plainText, &plainTextLength, cipherText, cipherLength);
++ int success = EVP_DecryptFinal_ex(m_decodeCTX, plainText + plainTextLength, &finalLength);
+
+ cipherLength = plainTextLength + finalLength;
+
+diff --git a/src/lib/tools/aesinterface.h b/src/lib/tools/aesinterface.h
+index e0debc6..c3c940c 100644
+--- a/src/lib/tools/aesinterface.h
++++ b/src/lib/tools/aesinterface.h
+@@ -50,8 +50,8 @@ class QUPZILLA_EXPORT AesInterface : public QObject
+ private:
+ bool init(int evpMode, const QByteArray &password, const QByteArray &iVector = QByteArray());
+
+- EVP_CIPHER_CTX m_encodeCTX;
+- EVP_CIPHER_CTX m_decodeCTX;
++ EVP_CIPHER_CTX* m_encodeCTX;
++ EVP_CIPHER_CTX* m_decodeCTX;
+
+ bool m_ok;
+ QByteArray m_iVector;
diff --git a/www-client/qupzilla/qupzilla-2.1.2.ebuild b/www-client/qupzilla/qupzilla-2.1.2.ebuild
new file mode 100644
index 00000000..a13409d9
--- /dev/null
+++ b/www-client/qupzilla/qupzilla-2.1.2.ebuild
@@ -0,0 +1,110 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PLOCALES="ar_SA bg_BG ca_ES cs_CZ da_DK de_DE el_GR es_ES es_MX es_VE eu_ES
+ fa_IR fi_FI fr_FR gl_ES he_IL hr_HR hu_HU id_ID is it_IT ja_JP ka_GE
+ lg lt lv_LV nl_NL nqo pl_PL pt_BR pt_PT ro_RO ru_RU sk_SK sr
+ sr@ijekavian sr@ijekavianlatin sr@latin sv_SE tr_TR uk_UA uz@Latn
+ zh_CN zh_HK zh_TW"
+
+PLUGINS_HASH='c332d306c0f6cf645c75eaf198d2fc5e12339e9e'
+PLUGINS_VERSION='2016.05.02' # if there are no updates, we can use the older archive
+
+inherit l10n qmake-utils
+
+if [[ ${PV} == *9999 ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/QupZilla/${PN}.git"
+else
+ MY_P=QupZilla-${PV}
+ SRC_URI="https://github.com/QupZilla/${PN}/releases/download/v${PV}/${MY_P}.tar.xz"
+ KEYWORDS="~amd64 ~x86"
+ S=${WORKDIR}/${MY_P}
+fi
+
+DESCRIPTION="A cross-platform web browser using QtWebEngine"
+HOMEPAGE="https://www.qupzilla.com/"
+SRC_URI+=" https://github.com/QupZilla/${PN}-plugins/archive/${PLUGINS_HASH}.tar.gz -> ${PN}-plugins-${PLUGINS_VERSION}.tar.gz"
+
+LICENSE="GPL-3"
+SLOT="0"
+IUSE="dbus debug gnome-keyring kwallet libressl nonblockdialogs"
+
+RDEPEND="
+ >=dev-qt/qtcore-5.7.1:5
+ >=dev-qt/qtdeclarative-5.7.1:5[widgets]
+ >=dev-qt/qtgui-5.7.1:5
+ >=dev-qt/qtnetwork-5.7.1:5[ssl]
+ >=dev-qt/qtprintsupport-5.7.1:5
+ >=dev-qt/qtsql-5.7.1:5[sqlite]
+ >=dev-qt/qtwebchannel-5.7.1:5
+ >=dev-qt/qtwebengine-5.7.1:5[widgets]
+ >=dev-qt/qtwidgets-5.7.1:5
+ >=dev-qt/qtx11extras-5.7.1:5
+ x11-libs/libxcb:=
+ dbus? ( >=dev-qt/qtdbus-5.7.1:5 )
+ gnome-keyring? ( gnome-base/gnome-keyring )
+ kwallet? ( kde-frameworks/kwallet:5 )
+ libressl? ( dev-libs/libressl:= )
+ !libressl? ( dev-libs/openssl:0= )
+"
+DEPEND="${RDEPEND}
+ >=dev-qt/linguist-tools-5.7.1:5
+ >=dev-qt/qtconcurrent-5.7.1:5
+ virtual/pkgconfig
+"
+
+DOCS=( AUTHORS BUILDING.md CHANGELOG FAQ README.md )
+
+PATCHES=( "${FILESDIR}/${P}-openssl-1.1.0.patch"
+ "${FILESDIR}/${P}-fullscreen.patch" )
+
+src_unpack() {
+ if [[ ${PV} == *9999 ]]; then
+ git-r3_src_unpack
+ fi
+ default
+}
+
+src_prepare() {
+ # get extra plugins into qupzilla build tree
+ mv "${WORKDIR}"/${PN}-plugins-${PLUGINS_HASH}/plugins/* "${S}"/src/plugins/ || die
+
+ rm_loc() {
+ # remove localizations the user has not specified
+ sed -i -e "/${1}.ts/d" translations/translations.pri || die
+ rm translations/${1}.ts || die
+ }
+
+ # remove outdated prebuilt localizations
+ rm -rf bin/locale || die
+
+ # remove empty locale
+ rm translations/empty.ts || die
+
+ l10n_find_plocales_changes translations '' .ts
+ l10n_for_each_disabled_locale_do rm_loc
+
+ default
+}
+
+src_configure() {
+ # see BUILDING document for explanation of options
+ export \
+ QUPZILLA_PREFIX="${EPREFIX}/usr" \
+ USE_LIBPATH="${EPREFIX}/usr/$(get_libdir)" \
+ DEBUG_BUILD=$(usex debug true '') \
+ DISABLE_DBUS=$(usex dbus '' true) \
+ GNOME_INTEGRATION=$(usex gnome-keyring true '') \
+ KDE_INTEGRATION=$(usex kwallet true '') \
+ NONBLOCK_JS_DIALOGS=$(usex nonblockdialogs true '')
+
+ eqmake5
+}
+
+src_install() {
+ emake INSTALL_ROOT="${D}" install
+ einstalldocs
+}