[arch-commits] Commit in kup/trunk (PKGBUILD kup-libgit-1.0.patch)

Antonio Rojas arojas at archlinux.org
Wed Apr 1 21:24:09 UTC 2020


    Date: Wednesday, April 1, 2020 @ 21:24:08
  Author: arojas
Revision: 609267

libgit 1.0 rebuild

Added:
  kup/trunk/kup-libgit-1.0.patch
Modified:
  kup/trunk/PKGBUILD

----------------------+
 PKGBUILD             |    9 ++++---
 kup-libgit-1.0.patch |   63 +++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 69 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2020-04-01 21:23:57 UTC (rev 609266)
+++ PKGBUILD	2020-04-01 21:24:08 UTC (rev 609267)
@@ -4,7 +4,7 @@
 
 pkgname=kup
 pkgver=0.7.3
-pkgrel=4
+pkgrel=5
 pkgdesc="A KDE bup backup software for helping people to keep up-to-date backups"
 arch=(x86_64)
 url="https://www.linux-apps.com/p/1127689/"
@@ -14,9 +14,11 @@
 optdepends=('bup: support for incremental backups'
             'rsync: support for synced backups')
 source=("https://github.com/spersson/Kup/archive/$pkgname-$pkgver.tar.gz"
-        kup-cmake-build-type.patch::"https://patch-diff.githubusercontent.com/raw/spersson/Kup/pull/81.patch")
+        kup-cmake-build-type.patch::"https://patch-diff.githubusercontent.com/raw/spersson/Kup/pull/81.patch"
+        kup-libgit-1.0.patch)
 sha256sums=('47b97314dd11579a6ecc723de687c9ebe7cafb300d2ce39f2510d36c17de2f3b'
-            '5ba2786dc43436774f24c72ca7abdc887bdf7e739bfe97b71f89c64912441f99')
+            '5ba2786dc43436774f24c72ca7abdc887bdf7e739bfe97b71f89c64912441f99'
+            '830045783bf76f260c935df0709f61ff6bb55e75fe9e02b5b8cd2f87eabe200b')
 
 prepare() {
   mkdir -p build
@@ -23,6 +25,7 @@
 
   cd Kup-$pkgname-$pkgver
   patch -p1 -i ../kup-cmake-build-type.patch # Fix build when CMAKE_BUILD_TYPE is not specified
+  patch -p1 -i ../kup-libgit-1.0.patch # Fix build with libgit 1.0
 }
 
 build() {

Added: kup-libgit-1.0.patch
===================================================================
--- kup-libgit-1.0.patch	                        (rev 0)
+++ kup-libgit-1.0.patch	2020-04-01 21:24:08 UTC (rev 609267)
@@ -0,0 +1,63 @@
+diff --git a/filedigger/main.cpp b/filedigger/main.cpp
+index 6682985..43fe9ae 100644
+--- a/filedigger/main.cpp
++++ b/filedigger/main.cpp
+@@ -21,11 +21,7 @@
+ #include "filedigger.h"
+ #include "mergedvfs.h"
+ 
+-#if LIBGIT2_VER_MAJOR == 0 && LIBGIT2_VER_MINOR >= 24
+ #include <git2/global.h>
+-#else
+-#include <git2/threads.h>
+-#endif
+ 
+ #include <KAboutData>
+ #include <KLocalizedString>
+@@ -66,19 +62,11 @@ int main(int pArgCount, char **pArgArray) {
+ 	}
+ 
+ 	// This needs to be called first thing, before any other calls to libgit2.
+-	#if LIBGIT2_VER_MAJOR == 0 && LIBGIT2_VER_MINOR >= 24
+ 	git_libgit2_init();
+-	#else
+-	git_threads_init();
+-	#endif
+ 
+ 	FileDigger *lFileDigger = new FileDigger(lRepoPath, lParser.value(QStringLiteral("branch")));
+ 	lFileDigger->show();
+ 	int lRetVal = lApp.exec();
+-	#if LIBGIT2_VER_MAJOR == 0 && LIBGIT2_VER_MINOR >= 24
+ 	git_libgit2_shutdown();
+-	#else
+-	git_threads_shutdown();
+-	#endif
+ 	return lRetVal;
+ }
+diff --git a/kioslave/bupslave.cpp b/kioslave/bupslave.cpp
+index 1a7e1a3..0812658 100644
+--- a/kioslave/bupslave.cpp
++++ b/kioslave/bupslave.cpp
+@@ -64,22 +64,14 @@ BupSlave::BupSlave(const QByteArray &pPoolSocket, const QByteArray &pAppSocket)
+ {
+ 	mRepository = nullptr;
+ 	mOpenFile = nullptr;
+-	#if LIBGIT2_VER_MAJOR == 0 && LIBGIT2_VER_MINOR >= 24
+ 	git_libgit2_init();
+-	#else
+-	git_threads_init();
+-	#endif
+ }
+ 
+ BupSlave::~BupSlave() {
+ 	if(mRepository != nullptr) {
+ 		delete mRepository;
+ 	}
+-	#if LIBGIT2_VER_MAJOR == 0 && LIBGIT2_VER_MINOR >= 24
+ 	git_libgit2_shutdown();
+-	#else
+-	git_threads_shutdown();
+-	#endif
+ }
+ 
+ void BupSlave::close() {



More information about the arch-commits mailing list