summaryrefslogtreecommitdiff
path: root/community/deja-dup
diff options
context:
space:
mode:
authorNicolás Reynolds <fauno@kiwwwi.com.ar>2012-11-06 13:53:51 -0300
committerNicolás Reynolds <fauno@kiwwwi.com.ar>2012-11-06 13:53:51 -0300
commita41239c941341e3c2017c6d3644e2cce0f1badf2 (patch)
treeefc401addf8099fa96ecaff2dea962b2cdbc813b /community/deja-dup
parentd333dde0a4d6295e9530ab8e988efa1d654e8716 (diff)
parent85e0e667660650d70269432a90401d4288776d9d (diff)
Merge branch 'master' of ssh://vparabola/home/parabola/abslibre-pre-mips64el
Conflicts: community/frei0r-plugins/PKGBUILD extra/cairo/PKGBUILD extra/libxml++/PKGBUILD
Diffstat (limited to 'community/deja-dup')
-rw-r--r--community/deja-dup/PKGBUILD21
-rw-r--r--community/deja-dup/new-u1backend-support.patch50
-rw-r--r--community/deja-dup/not-check-ubuntuone-couch.patch45
3 files changed, 111 insertions, 5 deletions
diff --git a/community/deja-dup/PKGBUILD b/community/deja-dup/PKGBUILD
index ba17e9c0b..158a9ff8c 100644
--- a/community/deja-dup/PKGBUILD
+++ b/community/deja-dup/PKGBUILD
@@ -1,25 +1,36 @@
-# $Id: PKGBUILD 77901 2012-10-15 17:33:17Z bgyorgy $
+# $Id: PKGBUILD 79462 2012-11-05 20:10:47Z bgyorgy $
# Maintainer: Balló György <ballogyor+arch at gmail dot com>
pkgname=deja-dup
pkgver=24.0
-pkgrel=1
+pkgrel=2
pkgdesc="Simple backup tool, that hides the complexity of backing up the Right Way and uses duplicity as the backend"
arch=('i686' 'x86_64' 'mips64el')
url="https://launchpad.net/deja-dup"
license=('GPL')
depends=('duplicity' 'libgnome-keyring' 'libpeas' 'libnotify' 'python2-gobject2' 'dconf' 'xdg-utils')
makedepends=('vala' 'intltool' 'itstool' 'nautilus')
-optdepends=('nautilus: backup extension')
+optdepends=('nautilus: backup extension'
+ 'ubuntuone-client: backup into Ubuntu One storage')
options=('!libtool')
install=$pkgname.install
-source=(http://launchpad.net/$pkgname/${pkgver%.*}/$pkgver/+download/$pkgname-$pkgver.tar.xz)
-md5sums=('335131d1f3c85615339fa8b212db50ae')
+source=(http://launchpad.net/$pkgname/${pkgver%.*}/$pkgver/+download/$pkgname-$pkgver.tar.xz
+ new-u1backend-support.patch
+ not-check-ubuntuone-couch.patch)
+md5sums=('335131d1f3c85615339fa8b212db50ae'
+ '944a4c62f042b240feba98f8d9a893b2'
+ '8d59798638982c2bdb55b2e415087245')
build() {
cd "$srcdir/$pkgname-$pkgver"
sed -i 's/\"python\", \"-c\"/\"python2\", \"-c\"/' common/PythonChecker.vala
+ # Add support for the new Ubuntu One backend
+ patch -Np0 -i "$srcdir/new-u1backend-support.patch"
+
+ # Now we don't need ubuntuone-couch for Ubuntu One support
+ patch -Np1 -i "$srcdir/not-check-ubuntuone-couch.patch"
+
./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var --libexecdir=/usr/lib/$pkgname \
--disable-static --disable-schemas-compile --without-unity
make
diff --git a/community/deja-dup/new-u1backend-support.patch b/community/deja-dup/new-u1backend-support.patch
new file mode 100644
index 000000000..08b918cb9
--- /dev/null
+++ b/community/deja-dup/new-u1backend-support.patch
@@ -0,0 +1,50 @@
+=== modified file 'common/BackendU1.vala'
+--- common/BackendU1.vala 2012-08-06 22:41:13 +0000
++++ common/BackendU1.vala 2012-11-03 21:35:53 +0000
+@@ -212,21 +212,41 @@
+
+ public override async void get_envp() throws Error
+ {
+- bool found = false;
+ var obj = get_creds_proxy();
+ if (obj.get_name_owner() == null) {
+ ask_password();
+ return;
+ }
+
++ var found = false;
++ var envp = new List<string>();
+ var listener = new Listener(obj, "find_credentials", null, (name, args) => {
+- if (name == "CredentialsFound")
+- found = true;
++ if (name == "CredentialsFound") {
++ VariantIter iter;
++ args.get("(a{ss})", out iter);
++ string key, val;
++ string consumer_key = null, consumer_secret = null, token = null, token_secret = null;
++ while (iter.next("{ss}", out key, out val)) {
++ if (key == "consumer_key")
++ consumer_key = val;
++ else if (key == "consumer_secret")
++ consumer_secret = val;
++ else if (key == "token")
++ token = val;
++ else if (key == "token_secret")
++ token_secret = val;
++ }
++ if (consumer_key != null && consumer_secret != null && token != null && token_secret != null) {
++ warning("appending: %s", "FTP_PASSWORD=%s:%s:%s:%s".printf(consumer_key, consumer_secret, token, token_secret));
++ envp.append("FTP_PASSWORD=%s:%s:%s:%s".printf(consumer_key, consumer_secret, token, token_secret));
++ found = true;
++ }
++ }
+ });
+ listener.run();
+
+ if (found)
+- envp_ready(true, null);
++ envp_ready(true, envp);
+ else
+ ask_password();
+ }
+
diff --git a/community/deja-dup/not-check-ubuntuone-couch.patch b/community/deja-dup/not-check-ubuntuone-couch.patch
new file mode 100644
index 000000000..d7fb903a1
--- /dev/null
+++ b/community/deja-dup/not-check-ubuntuone-couch.patch
@@ -0,0 +1,45 @@
+diff -Naur deja-dup-24.0.orig/common/BackendU1.vala deja-dup-24.0/common/BackendU1.vala
+--- deja-dup-24.0.orig/common/BackendU1.vala 2012-08-07 00:20:51.000000000 +0200
++++ deja-dup-24.0/common/BackendU1.vala 2012-11-05 16:39:34.140104977 +0100
+@@ -75,11 +75,14 @@
+
+ class U1Checker : Checker
+ {
+- PythonChecker pyu1;
+ construct {
+ try {
+ var proxy = BackendU1.get_creds_proxy();
+- if (proxy.get_name_owner() == null) {
++ if (proxy.get_name_owner() != null) {
++ available = true;
++ complete = true;
++ }
++ else {
+ available = false;
+ complete = true;
+ }
+@@ -89,24 +92,6 @@
+ available = false;
+ complete = true;
+ }
+-
+- if (!complete) {
+- // A bit of abstraction leakage here; we have to keep these imports in
+- // line with what duplicity uses. Maybe we should add to duplicity a way
+- // to ask 'can I use this backend?'
+- pyu1 = PythonChecker.get_checker("ubuntuone.platform.credentials, ubuntuone.couch.auth");
+- if (pyu1.complete) {
+- available = pyu1.available;
+- complete = pyu1.complete;
+- }
+- else {
+- pyu1.notify["complete"].connect(() => {
+- available = pyu1.available;
+- complete = pyu1.complete;
+- pyu1 = null;
+- });
+- }
+- }
+ }
+ }
+