Merge branch 'master' into f16
Conflicts: kdelibs.spec
This commit is contained in:
commit
12c8e1938b
@ -1,5 +1,5 @@
|
||||
From 1ce984bda1bb6a06f237240069a9f3a554cbbf37 Mon Sep 17 00:00:00 2001
|
||||
Message-Id: <1ce984bda1bb6a06f237240069a9f3a554cbbf37.1313890335.git.kevin.kofler@chello.at>
|
||||
From 89e4767148110a5566e463a03b3ed594276b7da0 Mon Sep 17 00:00:00 2001
|
||||
Message-Id: <89e4767148110a5566e463a03b3ed594276b7da0.1317166378.git.kevin.kofler@chello.at>
|
||||
From: Kevin Kofler <kevin.kofler@chello.at>
|
||||
Date: Wed, 17 Aug 2011 04:54:37 +0200
|
||||
Subject: [PATCH] Implement automatic scanning of source code for required
|
||||
@ -20,11 +20,11 @@ fill in X-Plasma-RequiredDataEngines manually. (Please note that the list is
|
||||
expected to be comma-separated.)
|
||||
---
|
||||
plasma/CMakeLists.txt | 15 ++++
|
||||
plasma/depextractor/depextractor.cpp | 115 +++++++++++++++++++++++++++++++++
|
||||
plasma/depextractor/depextractor.cpp | 125 +++++++++++++++++++++++++++++++++
|
||||
plasma/package.cpp | 11 +++
|
||||
plasma/private/componentinstaller.cpp | 68 +++++++++++++++++++
|
||||
plasma/private/componentinstaller_p.h | 17 +++++-
|
||||
5 files changed, 225 insertions(+), 1 deletions(-)
|
||||
plasma/private/componentinstaller.cpp | 71 +++++++++++++++++++
|
||||
plasma/private/componentinstaller_p.h | 17 ++++-
|
||||
5 files changed, 238 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/plasma/CMakeLists.txt b/plasma/CMakeLists.txt
|
||||
index f929967..9a760ef 100644
|
||||
@ -58,10 +58,10 @@ index f929967..9a760ef 100644
|
||||
+endif(NOT PLASMA_NO_PACKAGEKIT)
|
||||
diff --git a/plasma/depextractor/depextractor.cpp b/plasma/depextractor/depextractor.cpp
|
||||
new file mode 100644
|
||||
index 0000000..221b88b
|
||||
index 0000000..c489de7
|
||||
--- /dev/null
|
||||
+++ b/plasma/depextractor/depextractor.cpp
|
||||
@@ -0,0 +1,115 @@
|
||||
@@ -0,0 +1,125 @@
|
||||
+/* Plasma Data Engine dependency extractor
|
||||
+ Copyright (C) 2011 Kevin Kofler <kevin.kofler@chello.at>
|
||||
+
|
||||
@ -92,6 +92,21 @@ index 0000000..221b88b
|
||||
+
|
||||
+#include "private/componentinstaller_p.h"
|
||||
+
|
||||
+static QString scriptingApi(const QString &desktopFile)
|
||||
+{
|
||||
+ KDesktopFile desktop(desktopFile);
|
||||
+ KConfigGroup desktopGroup = desktop.desktopGroup();
|
||||
+ if (desktopGroup.readEntry("X-KDE-ServiceTypes", QStringList())
|
||||
+ .contains("Plasma/ScriptEngine")
|
||||
+ || desktopGroup.readEntry("ServiceTypes", QStringList())
|
||||
+ .contains("Plasma/ScriptEngine")) {
|
||||
+ /* Script engines are always written in C++. Their X-Plasma-API is the
|
||||
+ API they export, not the language they're written in. */
|
||||
+ return QString();
|
||||
+ }
|
||||
+ return desktopGroup.readEntry("X-Plasma-API", QString());
|
||||
+}
|
||||
+
|
||||
+static void writeDataEngineDependencies(const QStringList &deps,
|
||||
+ const QString &desktopFile)
|
||||
+{
|
||||
@ -105,16 +120,13 @@ index 0000000..221b88b
|
||||
+{
|
||||
+ KAboutData aboutData("plasma-dataengine-depextractor", QByteArray(),
|
||||
+ ki18n("Plasma Data Engine dependency extractor"),
|
||||
+ "1",
|
||||
+ "2",
|
||||
+ ki18n("Plasma Data Engine dependency extractor"));
|
||||
+ aboutData.addAuthor(ki18n("Kevin Kofler"), ki18n("Author"),
|
||||
+ "kevin.kofler@chello.at");
|
||||
+
|
||||
+ KCmdLineArgs::init(argc, argv, &aboutData);
|
||||
+ KCmdLineOptions options;
|
||||
+ options.add("a")
|
||||
+ .add("api <name>",
|
||||
+ ki18n("Sets the name of the scripting API/language"));
|
||||
+ options.add("+[path]",
|
||||
+ ki18n("Source path (default: .)"));
|
||||
+ options.add("+[file]",
|
||||
@ -129,10 +141,7 @@ index 0000000..221b88b
|
||||
+
|
||||
+ int exitCode = 0;
|
||||
+
|
||||
+ QString api, path, desktopFile;
|
||||
+ if (args->isSet("api")) {
|
||||
+ api = args->getOption("api");
|
||||
+ }
|
||||
+ QString path, desktopFile;
|
||||
+ int argCount = args->count();
|
||||
+ switch (argCount) {
|
||||
+ case 0:
|
||||
@ -159,12 +168,13 @@ index 0000000..221b88b
|
||||
+
|
||||
+ if (!exitCode) {
|
||||
+ if (QFileInfo(desktopFile).isRelative())
|
||||
+ desktopFile = QDir(path).filePath(desktopFile);
|
||||
+ desktopFile = QDir(path).absoluteFilePath(desktopFile);
|
||||
+
|
||||
+ if (QFileInfo(desktopFile).exists()) {
|
||||
+ writeDataEngineDependencies(Plasma::ComponentInstaller::self()
|
||||
+ ->extractDataEngineDependencies(path,
|
||||
+ api),
|
||||
+ ->extractDataEngineDependencies(
|
||||
+ path,
|
||||
+ scriptingApi(desktopFile)),
|
||||
+ desktopFile);
|
||||
+ } else {
|
||||
+ QTextStream err(stderr, QIODevice::WriteOnly | QIODevice::Text);
|
||||
@ -200,7 +210,7 @@ index 0a45c87..131f204 100644
|
||||
QStringList knownDataEngines = DataEngineManager::self()->listAllEngines(meta.application());
|
||||
foreach (const QString &requiredDataEngine, requiredDataEngines) {
|
||||
diff --git a/plasma/private/componentinstaller.cpp b/plasma/private/componentinstaller.cpp
|
||||
index 870667f..2c8c2dd 100644
|
||||
index 870667f..087d1c6 100644
|
||||
--- a/plasma/private/componentinstaller.cpp
|
||||
+++ b/plasma/private/componentinstaller.cpp
|
||||
@@ -28,6 +28,10 @@
|
||||
@ -228,7 +238,7 @@ index 870667f..2c8c2dd 100644
|
||||
QStringList resources;
|
||||
resources.append(searchString);
|
||||
packageKit.asyncCall(QLatin1String("InstallResources"), (unsigned int) wid,
|
||||
@@ -100,4 +108,64 @@ void ComponentInstaller::installMissingComponent(const QString &type,
|
||||
@@ -100,4 +108,67 @@ void ComponentInstaller::installMissingComponent(const QString &type,
|
||||
#endif
|
||||
}
|
||||
|
||||
@ -251,6 +261,9 @@ index 870667f..2c8c2dd 100644
|
||||
+ nameFilters.append("*.hxx");
|
||||
+ nameFilters.append("*.hh");
|
||||
+ nameFilters.append("*.H");
|
||||
+ } else if (api == "declarativeappletscript") {
|
||||
+ nameFilters.append("*.qml");
|
||||
+ searchRegExp = QRegExp("(?:^\\s*engine:\\s*|dataEngine *\\( *)\"([^\"]+)\"");
|
||||
+ } else if (api == "javascript") {
|
||||
+ nameFilters.append("*.js");
|
||||
+ } else if (api == "python") {
|
||||
@ -329,5 +342,5 @@ index f85cbb6..d0d9c75 100644
|
||||
/**
|
||||
* Default constructor. The singleton method self() is the
|
||||
--
|
||||
1.7.4.4
|
||||
1.7.6.2
|
||||
|
||||
|
81
kdelibs.spec
81
kdelibs.spec
@ -20,7 +20,7 @@
|
||||
|
||||
Summary: KDE Libraries
|
||||
Version: 4.7.1
|
||||
Release: 2%{?dist}.1
|
||||
Release: 6%{?dist}
|
||||
|
||||
Name: kdelibs
|
||||
Epoch: 6
|
||||
@ -147,51 +147,51 @@ Conflicts: kile < 2.1-0.9
|
||||
Conflicts: rkward < 0.5.4
|
||||
|
||||
BuildRequires: qt4-devel >= %{qt4_ver}
|
||||
BuildRequires: qt4-webkit-devel
|
||||
BuildRequires: pkgconfig(QtWebKit)
|
||||
%{?_qt4_version:Requires: qt4%{?_isa} >= %{_qt4_version}}
|
||||
Requires: xdg-utils
|
||||
Requires: redhat-menus
|
||||
Requires(post): /sbin/ldconfig
|
||||
Requires(postun): /sbin/ldconfig
|
||||
|
||||
BuildRequires: alsa-lib-devel
|
||||
BuildRequires: attica-devel >= %{attica_ver}
|
||||
BuildRequires: automoc4 >= 0.9.88
|
||||
BuildRequires: avahi-devel
|
||||
BuildRequires: bison flex
|
||||
BuildRequires: bzip2-devel
|
||||
BuildRequires: cmake >= 2.6.4
|
||||
BuildRequires: cups-devel cups
|
||||
BuildRequires: enchant-devel
|
||||
BuildRequires: gamin-devel
|
||||
BuildRequires: gettext-devel
|
||||
BuildRequires: giflib-devel
|
||||
BuildRequires: grantlee-devel
|
||||
BuildRequires: herqq-devel
|
||||
BuildRequires: jasper-devel
|
||||
BuildRequires: krb5-devel
|
||||
BuildRequires: libacl-devel libattr-devel
|
||||
BuildRequires: libjpeg-devel
|
||||
BuildRequires: libpng-devel
|
||||
BuildRequires: libtiff-devel
|
||||
BuildRequires: libxslt-devel libxml2-devel
|
||||
BuildRequires: libudev-devel
|
||||
BuildRequires: libutempter-devel
|
||||
BuildRequires: OpenEXR-devel
|
||||
BuildRequires: openssl-devel
|
||||
BuildRequires: pcre-devel
|
||||
BuildRequires: phonon-devel >= %{phonon_ver}
|
||||
BuildRequires: polkit-qt-devel >= 0.98.1
|
||||
BuildRequires: qca2-devel
|
||||
BuildRequires: shared-desktop-ontologies-devel >= %{shared_desktop_ontologies_ver}
|
||||
BuildRequires: pkgconfig(alsa)
|
||||
BuildRequires: pkgconfig(avahi-core)
|
||||
BuildRequires: pkgconfig(dbusmenu-qt)
|
||||
BuildRequires: pkgconfig(enchant)
|
||||
BuildRequires: pkgconfig(gamin)
|
||||
BuildRequires: pkgconfig(jasper)
|
||||
BuildRequires: pkgconfig(libattica) >= %{attica_ver}
|
||||
BuildRequires: pkgconfig(liblzma)
|
||||
BuildRequires: pkgconfig(libpcre)
|
||||
BuildRequires: pkgconfig(libstreams) >= %{strigi_ver}
|
||||
BuildRequires: pkgconfig(libudev)
|
||||
BuildRequires: pkgconfig(libxslt) pkgconfig(libxml-2.0)
|
||||
BuildRequires: pkgconfig(OpenEXR)
|
||||
BuildRequires: pkgconfig(openssl)
|
||||
BuildRequires: pkgconfig(phonon) >= %{phonon_ver}
|
||||
BuildRequires: pkgconfig(polkit-qt-1)
|
||||
BuildRequires: pkgconfig(qca2)
|
||||
BuildRequires: pkgconfig(shared-desktop-ontologies) >= %{shared_desktop_ontologies_ver}
|
||||
BuildRequires: pkgconfig(soprano) >= %{soprano_ver}
|
||||
BuildRequires: shared-mime-info
|
||||
BuildRequires: soprano-devel >= %{soprano_ver}
|
||||
BuildRequires: strigi-devel >= %{strigi_ver}
|
||||
BuildRequires: xz-devel
|
||||
BuildRequires: zlib-devel
|
||||
BuildRequires: dbusmenu-qt-devel
|
||||
# extra X deps (seemingly needed and/or checked-for by most kde4 buildscripts)
|
||||
%define x_deps libSM-devel libXcomposite-devel libXdamage-devel libxkbfile-devel libXpm-devel libXScrnSaver-devel libXtst-devel libXv-devel libXxf86misc-devel
|
||||
#define x_deps libSM-devel libXcomposite-devel libXdamage-devel libxkbfile-devel libXpm-devel libXScrnSaver-devel libXtst-devel libXv-devel libXxf86misc-devel
|
||||
%define x_deps pkgconfig(sm) pkgconfig(xcomposite) pkgconfig(xdamage) pkgconfig(xkbfile) pkgconfig(xpm) pkgconfig(xscrnsaver) pkgconfig(xtst) pkgconfig(xv) pkgconfig(xxf86misc)
|
||||
%{?x_deps:BuildRequires: %{x_deps}}
|
||||
|
||||
Requires: udisks upower
|
||||
@ -236,23 +236,24 @@ Summary: Header files for compiling KDE 4 applications
|
||||
Obsoletes: webkitkde-devel < 0.0.6
|
||||
%endif
|
||||
Provides: plasma-devel = %{version}-%{release}
|
||||
Provides: nepomuk-devel = %{version}-%{release}
|
||||
Requires: %{name} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
Obsoletes: kdelibs4-devel < %{version}-%{release}
|
||||
Provides: kdelibs4-devel = %{version}-%{release}
|
||||
%{?_isa:Provides: kdelibs4-devel%{?_isa} = %{version}-%{release}}
|
||||
Requires: attica-devel >= %{attica_ver}
|
||||
Requires: automoc4 >= 0.9.88
|
||||
Requires: cmake >= 2.6.4
|
||||
Requires: openssl-devel
|
||||
Requires: phonon-devel
|
||||
Provides: nepomuk-devel = %{version}-%{release}
|
||||
Requires: pkgconfig(libattica) >= %{attica_ver}
|
||||
Requires: pkgconfig(openssl)
|
||||
Requires: pkgconfig(phonon)
|
||||
# considered part of nepomuk-devel
|
||||
Requires: shared-desktop-ontologies-devel soprano-devel
|
||||
Requires: pkgconfig(shared-desktop-ontologies) pkgconfig(soprano)
|
||||
Requires: qt4-devel
|
||||
Requires: qt4-webkit-devel
|
||||
Requires: pkgconfig(QtWebKit)
|
||||
# do we really still need all these below? -- Rex
|
||||
Requires: strigi-devel
|
||||
Requires: bzip2-devel gamin-devel libacl-devel
|
||||
Requires: pkgconfig(libstreams)
|
||||
Requires: pkgconfig(gamin)
|
||||
Requires: bzip2-devel libacl-devel
|
||||
%{?x_deps:Requires: %{x_deps}}
|
||||
|
||||
%description devel
|
||||
@ -465,6 +466,7 @@ rm -rf %{buildroot}
|
||||
%{_kde4_appsdir}/kcharselect/
|
||||
%{_kde4_appsdir}/kcm_componentchooser/
|
||||
%{_kde4_appsdir}/kconf_update/
|
||||
%{_kde4_appsdir}/kdewidgets/
|
||||
%{_kde4_appsdir}/khtml/
|
||||
%{_kde4_appsdir}/kjava/
|
||||
%{_kde4_appsdir}/knewstuff/
|
||||
@ -547,7 +549,6 @@ rm -rf %{buildroot}
|
||||
%endif
|
||||
%{_kde4_bindir}/kde4-doxygen.sh
|
||||
%{_kde4_appsdir}/cmake/
|
||||
%{_kde4_appsdir}/kdewidgets/
|
||||
%{_kde4_includedir}/*
|
||||
%{_kde4_libdir}/kde4/devel/
|
||||
|
||||
@ -565,9 +566,23 @@ rm -rf %{buildroot}
|
||||
|
||||
|
||||
%changelog
|
||||
* Tue Oct 04 2011 Lukas Tinkl <ltinkl@redhat.com> - 4.7.1-2
|
||||
* Tue Oct 04 2011 Lukas Tinkl <ltinkl@redhat.com> - 4.7.1-6
|
||||
- Resolves #743056 - CVE-2011-3365 kdelibs: input validation failure in KSSL
|
||||
|
||||
* Wed Sep 28 2011 Rex Dieter <rdieter@fedoraproject.org> 4.7.1-5
|
||||
- -devel: s/pkgconfig(attica)/pkgconfig(libattica)/
|
||||
|
||||
* Tue Sep 27 2011 Kevin Kofler <Kevin@tigcc.ticalc.org> 4.7.1-4
|
||||
- updated Plasma data engine dependency extraction patch:
|
||||
- added support for declarativeappletscript QML code
|
||||
- plasma-dataengine-depextractor command-line tool:
|
||||
- make sure we pass an absolute path to KDesktopFile
|
||||
- autodetect the API/language used, drop --api command-line argument
|
||||
|
||||
* Thu Sep 22 2011 Rex Dieter <rdieter@fedoraproject.org> 4.7.1-3
|
||||
- pkgconfig-style deps
|
||||
- move kde4_appsdir/kdewidgets to main pkg (pairs with kdewidgets designer plugin)
|
||||
|
||||
* Fri Sep 02 2011 Than Ngo <than@redhat.com> - 4.7.1-1
|
||||
- 4.7.1
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user