summaryrefslogtreecommitdiff
path: root/app-editors/kile
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-11-25 22:39:15 +0000
committerV3n3RiX <venerix@redcorelinux.org>2020-11-25 22:39:15 +0000
commitd934827bf44b7cfcf6711964418148fa60877668 (patch)
tree0625f358789b5e015e49db139cc1dbc9be00428f /app-editors/kile
parent2e34d110f164bf74d55fced27fe0000201b3eec5 (diff)
gentoo resync : 25.11.2020
Diffstat (limited to 'app-editors/kile')
-rw-r--r--app-editors/kile/Manifest6
-rw-r--r--app-editors/kile/files/kile-2.9.93-fix-crash-when-deleting-templates.patch35
-rw-r--r--app-editors/kile/files/kile-2.9.93-fix-ktoolbar-usage.patch25
-rw-r--r--app-editors/kile/files/kile-2.9.93-fix-overriding-existing-templates.patch164
-rw-r--r--app-editors/kile/files/kile-2.9.93-no-khtml.patch58
-rw-r--r--app-editors/kile/kile-2.9.93-r1.ebuild (renamed from app-editors/kile/kile-2.9.93.ebuild)27
6 files changed, 303 insertions, 12 deletions
diff --git a/app-editors/kile/Manifest b/app-editors/kile/Manifest
index 8aa748e09ee7..ceb068e92962 100644
--- a/app-editors/kile/Manifest
+++ b/app-editors/kile/Manifest
@@ -1,4 +1,8 @@
AUX kile-2.9.93-cmake.patch 549 BLAKE2B f93414f3b09b45952a5082e9c9c0cd53b01b7b2ee3b080e6d4ef554cd3cbbf84f60061e1b4f9d1ab060f2e4ea221af3407140f9d897bece353691d9f262033e2 SHA512 be9a14c712c05bc63b1bf31eb959083580913c2ae37f642eab86f47a07f75d63d633fa154cce2ac65866b25da530cf0699e654c7b05ffc4361d35bc389a13faa
+AUX kile-2.9.93-fix-crash-when-deleting-templates.patch 1480 BLAKE2B 65260e42c42264d73ec8e18273a19f539dbd820cd8529212a346bcfbc83796736ac5cf4062b2787841791a65bf450735e1a45b5e3f9f3bd853cab90f6d78a235 SHA512 b9f8369f4d480de5678cb1ef1ed599ba1df06355d0cf63966185f989f9a92af81ec3d567d829a417dfc00d70eae22b1ec351041847b46fe72eb6f8a7917fe687
+AUX kile-2.9.93-fix-ktoolbar-usage.patch 962 BLAKE2B 05ef1605d01aabb40f2c64a8ec1c0212f442860add397ee85bd4597ec71ffdeb3120bd895e4a3b2e5bf02fdab15f75ccf9550e1c65aa6c8fd076aaa5e13f53e2 SHA512 06c8c2e0de25247edc0e2798b1455f1cd062d1f04c020a78f557958214b28b4228d56af57a1e154d1bb0598f22f9fe8e850d7b11f7ae9e569b15f89e95c43f2c
+AUX kile-2.9.93-fix-overriding-existing-templates.patch 6492 BLAKE2B 38b851368913d50aba95d5f037933fdd801be90921bfffc2b25fb2cca433c85806875f1472368fc9aace4475d9b24926bfe32ca5d4615ee83bbc728d402bc8aa SHA512 24cc76a554da0e25a37dc05356cf59224fd697278da8532ee2baaa6be4e04710620120545b11dd8a7986f56859ee9365fb072c1d3eaf6ef3fb4fcd5ed9543455
+AUX kile-2.9.93-no-khtml.patch 1361 BLAKE2B 01ab239474e4446368bd4a39da8e2f26f7cefc72f1150ea99a8ecf69dafc405fbdbc18d357da136f97ab446464a579a1d3e792f3d62c7c22a22954f6e6a7ab4e SHA512 2cc92a484315c61941ea19e73a5c98e0ae275a1475fd46bbfccb9f57283454f90d2b6a7e03da0a8e7f766c4486a4d1f6fef4b6c21b6349bc368ef14d936d9ed9
DIST kile-2.9.93.tar.bz2 8580239 BLAKE2B a43f160240dfdffc23c6898385994ee4e49e1f3d793915d1f392e41f606350269f2b9e80592c373680adb56454510abdd0b7e69131f20737fb5efa54d4eaa111 SHA512 d87277b8ef16c82cfd415dd191916641fa1a25e316e1eb2c463b275d3654dcfe180bea03027589ab30cd8b769d92d97005846a78aff8058bcfb20eed76287504
-EBUILD kile-2.9.93.ebuild 1717 BLAKE2B 06e3bb50cb1d6046ab51f705f82c7ef01d316376490cd61ed45a4f5180d9d46362f2c6004f947f55ec22b3489ef253c1f94fdbec358e71f2fecd492048218c1d SHA512 229a52d69a1b043e95786adacd56204153201c578d1a003759074d29500982cdf512885fb7239b061b356546ede8a86b81d630af2fe0aa47ae63a433f6443bca
+EBUILD kile-2.9.93-r1.ebuild 1880 BLAKE2B 5e21133d5523c4279a19df92f1c512eb4d584a8a0bb47a28667e7eef4e190c27d1867e22d2bfe0c5c346513567cd56b9bb9dbffa5b67e2b56905655111475d41 SHA512 51dc55144cbbd90593cd6ce897971b9cbb162362f9328de82ce29a94b35b33916aa0692196d86b9850fa1a2bda0361ca4528cab8be585ae4fbe4a195500a0407
MISC metadata.xml 476 BLAKE2B a152c0446aad3c66df2574332dc89f6797a16db142daafc82c3845f159b68bfcb922615f5912429d9965141ede27945512e5af1f5811ccbfa761026cc105b4b3 SHA512 82eaa93d944622e571887200fc50166b34ad4098ca2612749e72fff4e80f9f3fa07736cb8cd171fe3258fcd18209f7e60b01c859ad3cf20e4e238eab9dc3e486
diff --git a/app-editors/kile/files/kile-2.9.93-fix-crash-when-deleting-templates.patch b/app-editors/kile/files/kile-2.9.93-fix-crash-when-deleting-templates.patch
new file mode 100644
index 000000000000..232bd3894833
--- /dev/null
+++ b/app-editors/kile/files/kile-2.9.93-fix-crash-when-deleting-templates.patch
@@ -0,0 +1,35 @@
+From 483743aa9f194376a8b496ac4e58a946070a36af Mon Sep 17 00:00:00 2001
+From: Michel Ludwig <michel.ludwig@kdemail.net>
+Date: Sun, 1 Dec 2019 09:09:55 +0100
+Subject: [PATCH] Don't crash when deleting templates
+
+BUG: 413506
+---
+ src/dialogs/managetemplatesdialog.cpp | 11 -----------
+ 1 file changed, 11 deletions(-)
+
+diff --git a/src/dialogs/managetemplatesdialog.cpp b/src/dialogs/managetemplatesdialog.cpp
+index fe6537ad..c5298b21 100644
+--- a/src/dialogs/managetemplatesdialog.cpp
++++ b/src/dialogs/managetemplatesdialog.cpp
+@@ -317,17 +317,6 @@ bool ManageTemplatesDialog::removeTemplate()
+
+ KileTemplate::Info templateInfo = templateItem->getTemplateInfo();
+
+- KIO::StatJob* statJob = KIO::stat(QUrl::fromUserInput(templateInfo.path), KIO::StatJob::DestinationSide, 0);
+- KIO::StatJob* statJob2 = KIO::stat(QUrl::fromUserInput(templateInfo.icon), KIO::StatJob::DestinationSide, 0);
+- KJobWidgets::setWindow(statJob, this);
+- KJobWidgets::setWindow(statJob2, this);
+- statJob->exec();
+- statJob2->exec();
+- if ((statJob->error() && statJob2->error()) || !QFileInfo(templateInfo.icon).exists()) {
+- KMessageBox::error(this, i18n("Sorry, but you do not have the necessary permissions to remove the selected template."));
+- return false;
+- }
+-
+ if (KMessageBox::warningYesNo(this, i18n("You are about to remove the template \"%1\"; are you sure?", templateInfo.name)) == KMessageBox::No) {
+ return false;
+ }
+--
+GitLab
+
diff --git a/app-editors/kile/files/kile-2.9.93-fix-ktoolbar-usage.patch b/app-editors/kile/files/kile-2.9.93-fix-ktoolbar-usage.patch
new file mode 100644
index 000000000000..2afd0622ea3d
--- /dev/null
+++ b/app-editors/kile/files/kile-2.9.93-fix-ktoolbar-usage.patch
@@ -0,0 +1,25 @@
+From 5c268679da2fb2cdc414890bdd79a5592e37cb22 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Andrius=20=C5=A0tikonas?= <andrius@stikonas.eu>
+Date: Tue, 15 Sep 2020 15:33:51 +0100
+Subject: [PATCH] Fix KToolbar usage.
+
+---
+ src/widgets/scriptsmanagementwidget.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/widgets/scriptsmanagementwidget.cpp b/src/widgets/scriptsmanagementwidget.cpp
+index 79552da3..94f58f18 100644
+--- a/src/widgets/scriptsmanagementwidget.cpp
++++ b/src/widgets/scriptsmanagementwidget.cpp
+@@ -66,7 +66,7 @@ ScriptsManagement::ScriptsManagement(KileInfo *kileInfo, QWidget *parent, const
+ baseLayout->setContentsMargins(0, 0, 0, 0);
+ setLayout(baseLayout);
+
+- m_toolBar = new KToolBar(this, "scriptControlToolBar");
++ m_toolBar = new KToolBar("scriptControlToolBar", this);
+ m_toolBar->setToolButtonStyle(Qt::ToolButtonIconOnly);
+ m_toolBar->setIconDimensions(KIconLoader::SizeSmall);
+
+--
+GitLab
+
diff --git a/app-editors/kile/files/kile-2.9.93-fix-overriding-existing-templates.patch b/app-editors/kile/files/kile-2.9.93-fix-overriding-existing-templates.patch
new file mode 100644
index 000000000000..f303cff0b0f0
--- /dev/null
+++ b/app-editors/kile/files/kile-2.9.93-fix-overriding-existing-templates.patch
@@ -0,0 +1,164 @@
+From 7a55cf2d93c9daa13f2fa2ec1ae25646507cfc0c Mon Sep 17 00:00:00 2001
+From: Michel Ludwig <michel.ludwig@kdemail.net>
+Date: Sun, 1 Dec 2019 15:56:05 +0100
+Subject: [PATCH] Fix overriding of existing templates
+
+Also, don't delete the original file after the template has been
+created from it.
+
+BUG: 413473
+
+* asturm 2020-10-17: backport to 2.9.93 (drop unnecessary string change)
+
+---
+ src/dialogs/managetemplatesdialog.cpp | 7 ++-
+ src/templates.cpp | 78 ++-------------------------
+ src/templates.h | 10 ++--
+ 3 files changed, 12 insertions(+), 83 deletions(-)
+
+diff --git a/src/dialogs/managetemplatesdialog.cpp b/src/dialogs/managetemplatesdialog.cpp
+index c5298b21..77d5d6ff 100644
+--- a/src/dialogs/managetemplatesdialog.cpp
++++ b/src/dialogs/managetemplatesdialog.cpp
+@@ -292,11 +292,10 @@ void ManageTemplatesDialog::addTemplate()
+ reject();
+ return;
+ }
+- returnValue = m_templateManager->replace(templateInfo, m_sourceURL, templateName, iconURL);
+- }
+- else {
+- returnValue = m_templateManager->add(m_sourceURL, templateName, iconURL);
+ }
++
++ returnValue = m_templateManager->add(m_sourceURL, templateName, iconURL);
++
+ if (!returnValue) {
+ KMessageBox::error(this, i18n("Failed to create the template."));
+ reject();
+diff --git a/src/templates.cpp b/src/templates.cpp
+--- a/src/templates.cpp
++++ b/src/templates.cpp
+@@ -82,7 +82,10 @@ bool Manager::copyAppData(const QUrl &src, const QString& subdir, const QString&
+ testDir.mkpath(dir);
+ }
+ // copy file
+- KIO::FileCopyJob* copyJob = KIO::file_copy(src, targetURL);
++ if(src == targetURL) { // copying a file over itself
++ return true;
++ }
++ KIO::FileCopyJob* copyJob = KIO::file_copy(src, targetURL, -1, KIO::Overwrite);
+ KJobWidgets::setWindow(copyJob, m_kileInfo->mainWindow());
+ return copyJob->exec();
+ }
+@@ -130,77 +133,6 @@ bool Manager::remove(Info ti) {
+ return removeAppData(ti.path) && removeAppData(ti.icon);
+ }
+
+-bool Manager::replace(const KileTemplate::Info& toBeReplaced, const QUrl &newTemplateSourceURL, const QString& newName, const QUrl& newIcon) {
+- KileDocument::Type type = m_kileInfo->extensions()->determineDocumentType(newTemplateSourceURL);
+-
+- //start by copying the files that belong to the new template to a safe place
+- QString templateTempFile, iconTempFile;
+-
+- if( newTemplateSourceURL.isLocalFile() ) {
+- // file protocol. We do not need the network
+- templateTempFile = newTemplateSourceURL.toLocalFile();
+- }
+- else {
+- QTemporaryFile tmpFile;
+- tmpFile.setAutoRemove( false );
+- tmpFile.open();
+-
+- templateTempFile = tmpFile.fileName();
+- m_TempFilePath = tmpFile.fileName();
+- KIO::FileCopyJob* fileCopyJob = KIO::file_copy( newTemplateSourceURL, QUrl::fromLocalFile(templateTempFile), -1, KIO::Overwrite );
+- KJobWidgets::setWindow( fileCopyJob, m_kileInfo->mainWindow() );
+-
+- if( ! fileCopyJob->exec() ) {
+- return false;
+- }
+- }
+-
+- if( newIcon.isLocalFile() ) {
+- // file protocol. We do not need the network
+- iconTempFile = newIcon.toLocalFile();
+- }
+- else {
+- QTemporaryFile tmpFile;
+- tmpFile.setAutoRemove( false );
+- tmpFile.open();
+-
+- iconTempFile = tmpFile.fileName();
+- m_TempFilePath = tmpFile.fileName();
+- KIO::FileCopyJob* fileCopyJob = KIO::file_copy( newIcon, QUrl::fromLocalFile(iconTempFile), -1, KIO::Overwrite );
+- KJobWidgets::setWindow( fileCopyJob, m_kileInfo->mainWindow() );
+-
+- if( ! fileCopyJob->exec() ) {
+- if( ! templateTempFile.isEmpty() )
+- QFile::remove( templateTempFile );
+- return false;
+- }
+- }
+-
+- //now delete the template that should be replaced
+- if(!remove(toBeReplaced)) {
+- if( ! templateTempFile.isEmpty() )
+- QFile::remove( templateTempFile );
+- if( ! iconTempFile.isEmpty() )
+- QFile::remove( iconTempFile );
+- }
+-
+- //finally, create the new template
+- if(!add(QUrl::fromUserInput(templateTempFile), type, newName, QUrl::fromUserInput(iconTempFile))) {
+- if( ! templateTempFile.isEmpty() )
+- QFile::remove( templateTempFile );
+- if( ! iconTempFile.isEmpty() )
+- QFile::remove( iconTempFile );
+- return false;
+- }
+-
+- if( ! templateTempFile.isEmpty() )
+- QFile::remove( templateTempFile );
+- if( ! iconTempFile.isEmpty() )
+- QFile::remove( iconTempFile );
+-
+- return true;
+-}
+-
+ void Manager::scanForTemplates() {
+ KILE_DEBUG_MAIN << "===scanForTemplates()===================";
+ QStringList dirs = KileUtilities::locateAll(QStandardPaths::AppDataLocation, "templates", QStandardPaths::LocateDirectory);
+diff --git a/src/templates.h b/src/templates.h
+--- a/src/templates.h
++++ b/src/templates.h
+@@ -1,7 +1,7 @@
+ /***************************************************************************************
+ begin : Sat Apr 26 2003
+ copyright : (C) 2003 by Jeroen Wijnhout (wijnhout@science.uva.nl)
+- 2007, 2008 by Michel Ludwig (michel.ludwig@kdemail.net)
++ 2007-2019 by Michel Ludwig (michel.ludwig@kdemail.net)
+ ***************************************************************************************/
+
+ /***************************************************************************
+@@ -79,15 +79,13 @@ public:
+ **/
+ bool searchForTemplate(const QString& name, KileDocument::Type& type) const;
+
+- // add a template in $HOME/kile/templates/
++ // Add a template in .kde/share/kile/templates/
++ // This function will override any existing template.
+ bool add(const QUrl &templateSourceURL, const QString &name, const QUrl &icon);
+
+- // remove a template from $HOME/kile/templates/
++ // Remove a template from .kde/share/kile/templates/
+ bool remove(KileTemplate::Info ti);
+
+- // replaces a template
+- bool replace(const KileTemplate::Info& toBeReplaced, const QUrl &newTemplateSourceURL, const QString& newName, const QUrl& newIcon);
+-
+ // these have to be methods as we cannot use i18n calls in global objects
+ static QString defaultEmptyTemplateCaption();
+ static QString defaultEmptyLaTeXTemplateCaption();
+--
+GitLab
+
diff --git a/app-editors/kile/files/kile-2.9.93-no-khtml.patch b/app-editors/kile/files/kile-2.9.93-no-khtml.patch
new file mode 100644
index 000000000000..cf055fc84490
--- /dev/null
+++ b/app-editors/kile/files/kile-2.9.93-no-khtml.patch
@@ -0,0 +1,58 @@
+From 7c050b5e306cab115573aea1bfc951aaaa1203e9 Mon Sep 17 00:00:00 2001
+From: Michel Ludwig <michel.ludwig@kdemail.net>
+Date: Fri, 22 Nov 2019 09:40:53 +0100
+Subject: [PATCH] Remove dependency on KHTML
+
+---
+ CMakeLists.txt | 1 -
+ src/CMakeLists.txt | 2 --
+ src/kilelauncher.cpp | 1 -
+ 3 files changed, 4 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 1bea621f..1b25e3a4 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -46,7 +46,6 @@ find_package(KF5 5.31 REQUIRED COMPONENTS
+ I18n
+ IconThemes
+ Init
+- KHtml
+ KIO
+ Parts
+ TextEditor
+diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
+index 77626894..e23480fd 100644
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -55,7 +55,6 @@ set(kile_SRCS
+ dialogs/usermenu/usermenuitem.cpp
+ dialogs/usermenu/usermenutree.cpp
+ dialogs/validatorinputdialog.cpp
+- docpart.cpp
+ documentinfo.cpp
+ editorcommands.cpp
+ editorextension.cpp
+@@ -238,7 +237,6 @@ PUBLIC
+ KF5::Crash
+ KF5::DBusAddons
+ KF5::GuiAddons
+- KF5::KHtml
+ KF5::I18n
+ KF5::IconThemes
+ KF5::KIOCore
+diff --git a/src/kilelauncher.cpp b/src/kilelauncher.cpp
+index c0bcdf9d..24a1f5b4 100644
+--- a/src/kilelauncher.cpp
++++ b/src/kilelauncher.cpp
+@@ -16,7 +16,6 @@
+
+ #include <config.h>
+
+-#include "docpart.h"
+ #include "kileconfig.h"
+ #include "kileinfo.h"
+ #include "kiletool.h"
+--
+GitLab
+
diff --git a/app-editors/kile/kile-2.9.93.ebuild b/app-editors/kile/kile-2.9.93-r1.ebuild
index e13393daca2f..23b5ae2d2557 100644
--- a/app-editors/kile/kile-2.9.93.ebuild
+++ b/app-editors/kile/kile-2.9.93-r1.ebuild
@@ -1,15 +1,16 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
ECM_HANDBOOK="forceoptional"
-KFMIN=5.60.0
-QTMIN=5.12.3
+KDE_ORG_CATEGORY="office"
+KFMIN=5.74.0
+QTMIN=5.14.2
inherit ecm kde.org
DESCRIPTION="Latex Editor and TeX shell based on KDE Frameworks"
-HOMEPAGE="https://kile.sourceforge.io/"
+HOMEPAGE="https://apps.kde.org/en/kile https://kile.sourceforge.io/"
if [[ ${KDE_BUILD_TYPE} == release ]]; then
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
@@ -25,14 +26,13 @@ DEPEND="
>=dev-qt/qtscript-${QTMIN}:5
>=dev-qt/qttest-${QTMIN}:5
>=dev-qt/qtwidgets-${QTMIN}:5
- >=kde-apps/okular-19.04.3:5
+ kde-apps/okular:5
>=kde-frameworks/kconfig-${KFMIN}:5
>=kde-frameworks/kcoreaddons-${KFMIN}:5
>=kde-frameworks/kcrash-${KFMIN}:5
>=kde-frameworks/kdbusaddons-${KFMIN}:5
>=kde-frameworks/kdoctools-${KFMIN}:5
>=kde-frameworks/kguiaddons-${KFMIN}:5
- >=kde-frameworks/khtml-${KFMIN}:5
>=kde-frameworks/ki18n-${KFMIN}:5
>=kde-frameworks/kiconthemes-${KFMIN}:5
>=kde-frameworks/kinit-${KFMIN}:5
@@ -44,14 +44,13 @@ DEPEND="
pdf? ( app-text/poppler[qt5] )
"
RDEPEND="${DEPEND}
- !app-editors/kile:4
- >=kde-apps/konsole-19.04.3:5
- >=kde-apps/okular-19.04.3:5[pdf?]
+ kde-apps/konsole:5
+ kde-apps/okular:5[pdf?]
virtual/latex-base
virtual/tex-base
pdf? (
- >=app-text/texlive-core-2014
app-text/ghostscript-gpl
+ app-text/texlive-core
)
png? (
app-text/dvipng
@@ -61,7 +60,13 @@ RDEPEND="${DEPEND}
DOCS=( AUTHORS ChangeLog kile-remote-control.txt README{,.cwl} )
-PATCHES=( "${FILESDIR}/${P}-cmake.patch" )
+PATCHES=(
+ "${FILESDIR}/${P}-cmake.patch"
+ "${FILESDIR}/${P}-no-khtml.patch"
+ "${FILESDIR}/${P}-fix-crash-when-deleting-templates.patch"
+ "${FILESDIR}/${P}-fix-overriding-existing-templates.patch"
+ "${FILESDIR}/${P}-fix-ktoolbar-usage.patch"
+)
src_configure() {
local mycmakeargs=(