summaryrefslogtreecommitdiff
path: root/core/util-linux
diff options
context:
space:
mode:
authorNicolás Reynolds <fauno@endefensadelsl.org>2013-12-27 23:55:53 +0000
committerNicolás Reynolds <fauno@endefensadelsl.org>2013-12-27 23:55:53 +0000
commit65eeff79fff8a1bfdf67ca51d147384f46f4d5c0 (patch)
treefbfdff322b28d9a3c37e6e31c94caf1d8e48dac1 /core/util-linux
parentd53c44f055929b18d7d1b25f8367ee5836c435fc (diff)
Fri Dec 27 23:54:04 UTC 2013
Diffstat (limited to 'core/util-linux')
-rw-r--r--core/util-linux/0001-lsblk-fix-D-segfault.patch45
-rw-r--r--core/util-linux/0001-pylibmount-correctly-import-from-pylibmount.so.patch30
-rw-r--r--core/util-linux/PKGBUILD15
3 files changed, 88 insertions, 2 deletions
diff --git a/core/util-linux/0001-lsblk-fix-D-segfault.patch b/core/util-linux/0001-lsblk-fix-D-segfault.patch
new file mode 100644
index 000000000..8e4d7c6d2
--- /dev/null
+++ b/core/util-linux/0001-lsblk-fix-D-segfault.patch
@@ -0,0 +1,45 @@
+From 71d842c01992b3678de4da4773ed54f08c0ab4f6 Mon Sep 17 00:00:00 2001
+From: Karel Zak <kzak@redhat.com>
+Date: Mon, 18 Nov 2013 11:27:35 +0100
+Subject: [PATCH] lsblk: fix -D segfault
+
+References: https://bugzilla.redhat.com/show_bug.cgi?id=1031262
+Signed-off-by: Karel Zak <kzak@redhat.com>
+---
+ misc-utils/lsblk.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/misc-utils/lsblk.c b/misc-utils/lsblk.c
+index 9f7f1b6..9b53be3 100644
+--- a/misc-utils/lsblk.c
++++ b/misc-utils/lsblk.c
+@@ -903,7 +903,7 @@ static void set_tt_data(struct blkdev_cxt *cxt, int col, int id, struct tt_line
+ if (cxt->discard && p)
+ tt_line_set_data(ln, col, p);
+ else
+- tt_line_set_data(ln, col, "0");
++ tt_line_set_data(ln, col, xstrdup("0"));
+ break;
+ case COL_DGRAN:
+ if (lsblk->bytes)
+@@ -936,7 +936,7 @@ static void set_tt_data(struct blkdev_cxt *cxt, int col, int id, struct tt_line
+ if (cxt->discard && p)
+ tt_line_set_data(ln, col, p);
+ else
+- tt_line_set_data(ln, col, "0");
++ tt_line_set_data(ln, col, xstrdup("0"));
+ break;
+ case COL_WSAME:
+ if (lsblk->bytes)
+@@ -948,7 +948,7 @@ static void set_tt_data(struct blkdev_cxt *cxt, int col, int id, struct tt_line
+ "queue/write_same_max_bytes", &x) == 0)
+ p = size_to_human_string(SIZE_SUFFIX_1LETTER, x);
+ }
+- tt_line_set_data(ln, col, p ? p : "0");
++ tt_line_set_data(ln, col, p ? p : xstrdup("0"));
+ break;
+ };
+ }
+--
+1.8.4.2
+
diff --git a/core/util-linux/0001-pylibmount-correctly-import-from-pylibmount.so.patch b/core/util-linux/0001-pylibmount-correctly-import-from-pylibmount.so.patch
new file mode 100644
index 000000000..34040b9eb
--- /dev/null
+++ b/core/util-linux/0001-pylibmount-correctly-import-from-pylibmount.so.patch
@@ -0,0 +1,30 @@
+From c8e5e6e7323642f7e6f12ee5f5231b0ec44c40ab Mon Sep 17 00:00:00 2001
+From: Dave Reisner <dreisner@archlinux.org>
+Date: Thu, 21 Nov 2013 12:25:27 -0500
+Subject: [PATCH] pylibmount: correctly import from pylibmount.so
+
+Without this, python is unable to find the module:
+
+$ python -c 'import libmount'
+Traceback (most recent call last):
+ File "<string>", line 1, in <module>
+ File "/usr/lib/python3.3/site-packages/libmount/__init__.py", line 1, in <module>
+ from pylibmount import *
+ImportError: No module named 'pylibmount'
+
+Signed-off-by: Dave Reisner <dreisner@archlinux.org>
+---
+ libmount/python/libmount/__init__.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libmount/python/libmount/__init__.py b/libmount/python/libmount/__init__.py
+index 243c639..09104e2 100644
+--- a/libmount/python/libmount/__init__.py
++++ b/libmount/python/libmount/__init__.py
+@@ -1,2 +1,2 @@
+-from pylibmount import *
++from .pylibmount import *
+
+--
+1.8.4.2
+
diff --git a/core/util-linux/PKGBUILD b/core/util-linux/PKGBUILD
index 27df08ea7..d72a68384 100644
--- a/core/util-linux/PKGBUILD
+++ b/core/util-linux/PKGBUILD
@@ -1,11 +1,11 @@
-# $Id: PKGBUILD 197844 2013-10-30 11:07:21Z allan $
+# $Id: PKGBUILD 201467 2013-12-12 15:33:24Z dreisner $
# Maintainer: Tom Gundersen <teg@jklm.no>
# Maintainer: Dave Reisner <dreisner@archlinux.org>
# Contributor: judd <jvinet@zeroflux.org>
pkgname=util-linux
pkgver=2.24
-pkgrel=1
+pkgrel=2
pkgdesc="Miscellaneous system utilities for Linux"
url="http://www.kernel.org/pub/linux/utils/util-linux/"
arch=('i686' 'x86_64')
@@ -19,6 +19,8 @@ provides=("util-linux-ng=$pkgver" 'eject')
license=('GPL2')
options=('strip' 'debug')
source=("ftp://ftp.kernel.org/pub/linux/utils/$pkgname/v2.24/$pkgname-$pkgver.tar.xz"
+ 0001-lsblk-fix-D-segfault.patch
+ 0001-pylibmount-correctly-import-from-pylibmount.so.patch
uuidd.tmpfiles
pam-login
pam-common
@@ -30,11 +32,20 @@ backup=(etc/pam.d/chfn
etc/pam.d/su-l)
install=util-linux.install
md5sums=('4fac6443427f575fc5f3531a4ad2ca01'
+ '1899fe3b853a5835c76cca0501b6b518'
+ 'a18a1e89ffdfa3bc96ae976646a723ec'
'a39554bfd65cccfd8254bb46922f4a67'
'4368b3f98abd8a32662e094c54e7f9b1'
'a31374fef2cba0ca34dfc7078e2969e4'
'fa85e5cce5d723275b14365ba71a8aad')
+prepare() {
+ cd "$pkgname-$pkgver"
+
+ patch -Np1 <"$srcdir"/0001-lsblk-fix-D-segfault.patch
+ patch -Np1 <"$srcdir"/0001-pylibmount-correctly-import-from-pylibmount.so.patch
+}
+
build() {
cd "$pkgname-$pkgver"