[arch-commits] Commit in kservice/trunk (PKGBUILD timestamp.patch)

Antonio Rojas arojas at archlinux.org
Sat Sep 19 09:04:43 UTC 2015


    Date: Saturday, September 19, 2015 @ 11:04:43
  Author: arojas
Revision: 246566

Fix kbuildsycoca loop (FS#46320)

Added:
  kservice/trunk/timestamp.patch
Modified:
  kservice/trunk/PKGBUILD

-----------------+
 PKGBUILD        |   11 ++++++++---
 timestamp.patch |   27 +++++++++++++++++++++++++++
 2 files changed, 35 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2015-09-19 00:40:05 UTC (rev 246565)
+++ PKGBUILD	2015-09-19 09:04:43 UTC (rev 246566)
@@ -4,7 +4,7 @@
 
 pkgname=kservice
 pkgver=5.14.2
-pkgrel=1
+pkgrel=2
 pkgdesc='Advanced plugin and service introspection'
 arch=('i686' 'x86_64')
 url='https://projects.kde.org/projects/frameworks/kservice'
@@ -12,11 +12,16 @@
 depends=('ki18n' 'kconfig' 'kcrash' 'kdbusaddons')
 makedepends=('extra-cmake-modules' 'kdoctools' 'python')
 groups=('kf5')
-source=("http://download.kde.org/stable/frameworks/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz")
-md5sums=('eca764e18afbcef5496183c96c613c91')
+source=("http://download.kde.org/stable/frameworks/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz" timestamp.patch)
+md5sums=('eca764e18afbcef5496183c96c613c91'
+         'b77b056fb6bb5adba72702fddf0feff8')
 
 prepare() {
   mkdir -p build
+
+# Fix kbuildsycoca infinite loop https://bugs.kde.org/show_bug.cgi?id=352854
+  cd $pkgname-$pkgver
+  patch -p1 -i ../timestamp.patch
 }
 
 build() {

Added: timestamp.patch
===================================================================
--- timestamp.patch	                        (rev 0)
+++ timestamp.patch	2015-09-19 09:04:43 UTC (rev 246566)
@@ -0,0 +1,27 @@
+diff --git a/src/kbuildsycoca/kbuildsycoca.cpp b/src/kbuildsycoca/kbuildsycoca.cpp
+index 827ac96..6d34235 100644
+--- a/src/kbuildsycoca/kbuildsycoca.cpp
++++ b/src/kbuildsycoca/kbuildsycoca.cpp
+@@ -515,7 +515,7 @@ void KBuildSycoca::save(QDataStream *str)
+     (*str) << qint32(0); // No more factories.
+     // Write XDG_DATA_DIRS
+     (*str) << QStandardPaths::standardLocations(QStandardPaths::GenericDataLocation).join(QString(QLatin1Char(':')));
+-    (*str) << (quint32)newTimestamp / 1000; // TODO just newTimestamp when using a new filename
++    (*str) << (quint32)(newTimestamp / 1000); // TODO just newTimestamp when using a new filename
+     (*str) << QLocale().bcp47Name();
+     // This makes it possible to trigger a ksycoca update for all users (KIOSK feature)
+     (*str) << calcResourceHash(QStringLiteral("kservices5"), QStringLiteral("update_ksycoca"));
+diff --git a/src/sycoca/ksycoca.cpp b/src/sycoca/ksycoca.cpp
+index 81c875d..44984fa 100644
+--- a/src/sycoca/ksycoca.cpp
++++ b/src/sycoca/ksycoca.cpp
+@@ -505,7 +505,7 @@ KSycoca::KSycocaHeader KSycocaPrivate::readSycocaHeader()
+     KSycocaUtilsPrivate::read(*str, header.prefixes);
+     quint32 oldTimeStamp; // compat code --> TODO remove this when switching to a different fileName
+     *str >> oldTimeStamp;
+-    header.timeStamp = oldTimeStamp * 1000;
++    header.timeStamp = static_cast<quint64>(oldTimeStamp) * 1000;
+     KSycocaUtilsPrivate::read(*str, header.language);
+     *str >> header.updateSignature;
+     KSycocaUtilsPrivate::read(*str, allResourceDirs);
+



More information about the arch-commits mailing list