]> git.ipfire.org Git - people/stevee/ipfire-3.x.git/commitdiff
pakfire: Add some patches from upstream.
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 7 Mar 2012 23:08:56 +0000 (00:08 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Wed, 7 Mar 2012 23:08:56 +0000 (00:08 +0100)
Those patches fix the sharedstatedir variable,
fix a the library check on GCC updates and
don't download mirror lists inside the build root
unless they are needed.

pakfire/pakfire.nm
pakfire/patches/pakfire-0.9.20-dont-download-mirrorlists.patch [new file with mode: 0644]
pakfire/patches/pakfire-0.9.20-fix-library-check.patch [new file with mode: 0644]
pakfire/patches/pakfire-0.9.20-sharedstatedir.patch [new file with mode: 0644]

index 8490682718db6cab98385b53a010f4874c1e01c6..c5b65e3f57b727339cbee0c81c49677f8daddde8 100644 (file)
@@ -5,7 +5,7 @@
 
 name       = pakfire
 version    = 0.9.20
-release    = 2
+release    = 3
 
 maintainer = Michael Tremer <michael.tremer@ipfire.org>
 groups     = System/Packaging
diff --git a/pakfire/patches/pakfire-0.9.20-dont-download-mirrorlists.patch b/pakfire/patches/pakfire-0.9.20-dont-download-mirrorlists.patch
new file mode 100644 (file)
index 0000000..c8cafc6
--- /dev/null
@@ -0,0 +1,53 @@
+From 90919c62214dd821048027cce5752a8d7f64d437 Mon Sep 17 00:00:00 2001
+From: Michael Tremer <michael.tremer@ipfire.org>
+Date: Wed, 29 Feb 2012 18:37:50 +0100
+Subject: [PATCH] Don't download mirrorlist at repository initialization.
+
+---
+ python/pakfire/downloader.py |    9 +++++++--
+ 1 files changed, 7 insertions(+), 2 deletions(-)
+
+diff --git a/python/pakfire/downloader.py b/python/pakfire/downloader.py
+index 3bfbff2..f89681f 100644
+--- a/python/pakfire/downloader.py
++++ b/python/pakfire/downloader.py
+@@ -190,8 +190,6 @@ class MirrorList(object):
+               # Save URL to more mirrors.
+               self.mirrorlist = repo._mirrors
+-              self.update(force=False)
+-
+       @property
+       def distro(self):
+               return self.repo.distro
+@@ -245,6 +243,7 @@ class MirrorList(object):
+                       f.close()
+               # Read mirrorlist from cache and parse it.
++              self.forget_mirrors()
+               with self.cache.open(cache_filename) as f:
+                       self.parse_mirrordata(f.read())
+@@ -259,6 +258,9 @@ class MirrorList(object):
+               self.__mirrors.append(mirror)
++      def forget_mirrors(self):
++              self.__mirrors = []
++
+       @property
+       def preferred(self):
+               """
+@@ -289,6 +291,9 @@ class MirrorList(object):
+               """
+                       Return a MirrorGroup object for the given grabber.
+               """
++              # Make sure the mirrorlist is up to date.
++              self.update()
++
+               # A list of mirrors that is passed to MirrorGroup.
+               mirrors = []
+-- 
+1.7.3.4
+
diff --git a/pakfire/patches/pakfire-0.9.20-fix-library-check.patch b/pakfire/patches/pakfire-0.9.20-fix-library-check.patch
new file mode 100644 (file)
index 0000000..8bde631
--- /dev/null
@@ -0,0 +1,36 @@
+From 1f2968430df446dcbf0e27ff870ac7aa6e8113cd Mon Sep 17 00:00:00 2001
+From: Michael Tremer <michael.tremer@ipfire.org>
+Date: Tue, 6 Mar 2012 16:11:01 +0100
+Subject: [PATCH] Fix library check when updating GCC.
+
+As it only happens on ARM, the new GCC libdir is not found.
+---
+ tools/quality-agent.d/003-libs-location |    7 +++++--
+ 1 files changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/tools/quality-agent.d/003-libs-location b/tools/quality-agent.d/003-libs-location
+index 48b2521..ce5ba72 100755
+--- a/tools/quality-agent.d/003-libs-location
++++ b/tools/quality-agent.d/003-libs-location
+@@ -16,13 +16,16 @@ esac
+ # Find gcc libdir.
+ gcc_libdir=$(gcc -print-libgcc-file-name)
+-gcc_libdir=$(dirname ${gcc_libdir})
++for i in 1 2; do
++      gcc_libdir=$(dirname ${gcc_libdir})
++done
++gcc_libdir=$(ls ${BUILDROOT}${gcc_libdir}/* 2>/dev/null | tail -n1)
+ function check() {
+       local failed=0
+       local found
+-      for lib in $(find ${BUILDROOT}/${libdir} -type f -name "lib*.so.*" 2>/dev/null); do
++      for lib in $(find ${BUILDROOT}/{,usr/}${libdir} -type f -name "lib*.so.*" 2>/dev/null); do
+               lib=${lib##*/}
+               lib=${lib%%.so*}
+-- 
+1.7.3.4
+
diff --git a/pakfire/patches/pakfire-0.9.20-sharedstatedir.patch b/pakfire/patches/pakfire-0.9.20-sharedstatedir.patch
new file mode 100644 (file)
index 0000000..8c582bd
--- /dev/null
@@ -0,0 +1,25 @@
+From 7cefdc0a2cb917e16c95d522fb1e3d4ed600faca Mon Sep 17 00:00:00 2001
+From: Michael Tremer <michael.tremer@ipfire.org>
+Date: Wed, 7 Mar 2012 17:11:37 +0100
+Subject: [PATCH] Fix definition of sharedstatedir.
+
+---
+ macros/arch.macro |    2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
+diff --git a/macros/arch.macro b/macros/arch.macro
+index e756b8e..536e9d2 100644
+--- a/macros/arch.macro
++++ b/macros/arch.macro
+@@ -8,7 +8,7 @@ sbindir           = %{exec_prefix}/sbin
+ libexecdir        = %{exec_prefix}/lib
+ datadir           = %{prefix}/share
+ sysconfdir        = /etc
+-sharedstatedir    = %{prefix}/com
++sharedstatedir    = %{localstatedir}/lib
+ localstatedir     = /var
+ lib               = lib
+ libdir            = %{exec_prefix}/%{lib}
+-- 
+1.7.3.4
+