summaryrefslogtreecommitdiff
path: root/dev-python/python-blivet
diff options
context:
space:
mode:
authorBlackNoxis <steven.darklight@gmail.com>2015-06-26 10:58:48 +0300
committerBlackNoxis <steven.darklight@gmail.com>2015-06-26 10:58:48 +0300
commit8f45c5954f01fcc14edc375e1597c9fcdccad0ab (patch)
tree8b4995437d72dfac1aa3b66ffa21b2b212afcd89 /dev-python/python-blivet
parent66c035f64fef20199fad12fb75285aec3ffe8b33 (diff)
[dev-python/*] added missing packages
Diffstat (limited to 'dev-python/python-blivet')
-rw-r--r--dev-python/python-blivet/Manifest1
-rw-r--r--dev-python/python-blivet/files/0001-Update-package-names-to-reflect-Gentoo-ones.patch144
-rw-r--r--dev-python/python-blivet/files/0001-devices-enable-UUID-for-dm-based-devices-in-fstab.patch28
-rw-r--r--dev-python/python-blivet/files/python-blivet-commit-to-disk-settle.patch12
-rw-r--r--dev-python/python-blivet/files/python-blivet-udev-path.patch11
-rw-r--r--dev-python/python-blivet/files/python-blivet-workaround-disable-multipath.patch9
-rw-r--r--dev-python/python-blivet/metadata.xml5
-rw-r--r--dev-python/python-blivet/python-blivet-0.23.9-r3.ebuild55
8 files changed, 265 insertions, 0 deletions
diff --git a/dev-python/python-blivet/Manifest b/dev-python/python-blivet/Manifest
new file mode 100644
index 00000000..50286488
--- /dev/null
+++ b/dev-python/python-blivet/Manifest
@@ -0,0 +1 @@
+DIST blivet-0.23.9-1.tar.gz 230824 SHA256 4cf312640c7cf040e621f997cd16496b67b84f98a70cb9aee4adce4f3353abd7 SHA512 8ca5484291b1531c7af7f2122b6a05177b685f3f112d146d382fdd6e940c8e9c51c200439d7f0fe0fd9d80e5ae0bd1ae53c07d90159c1c63aa5fa6c739789b3e WHIRLPOOL ab1bf6d45f43172e15f8f149528fb02c615677b634cfde3780c2ff5f40b63e7c67d1ca844531aaeb4f33fa39404677268de1d7ecc8bf0e432ac0143138237a97
diff --git a/dev-python/python-blivet/files/0001-Update-package-names-to-reflect-Gentoo-ones.patch b/dev-python/python-blivet/files/0001-Update-package-names-to-reflect-Gentoo-ones.patch
new file mode 100644
index 00000000..142ad49c
--- /dev/null
+++ b/dev-python/python-blivet/files/0001-Update-package-names-to-reflect-Gentoo-ones.patch
@@ -0,0 +1,144 @@
+From 149d6e87069036aec413834ff93fa59fb9db2ab6 Mon Sep 17 00:00:00 2001
+From: Fabio Erculiani <lxnay@sabayon.org>
+Date: Sat, 10 May 2014 14:01:13 +0100
+Subject: [PATCH] Update package names to reflect Gentoo ones
+
+---
+ blivet/devices.py | 10 +++++-----
+ blivet/formats/fs.py | 4 ++--
+ blivet/formats/luks.py | 2 +-
+ blivet/formats/multipath.py | 2 +-
+ blivet/platform.py | 6 +++---
+ 5 files changed, 12 insertions(+), 12 deletions(-)
+
+diff --git a/blivet/devices.py b/blivet/devices.py
+index 1af4e00..137a61b 100644
+--- a/blivet/devices.py
++++ b/blivet/devices.py
+@@ -1987,7 +1987,7 @@ class DMCryptDevice(DMDevice):
+ class LUKSDevice(DMCryptDevice):
+ """ A mapped LUKS device. """
+ _type = "luks/dm-crypt"
+- _packages = ["cryptsetup-luks"]
++ _packages = ["cryptsetup"]
+
+ def __init__(self, name, format=None, size=None, uuid=None,
+ exists=False, sysfsPath='', parents=None):
+@@ -3612,7 +3612,7 @@ class DMRaidArrayDevice(DMDevice):
+ class MultipathDevice(DMDevice):
+ """ A multipath device """
+ _type = "dm-multipath"
+- _packages = ["device-mapper-multipath"]
++ _packages = ["multipath-tools"]
+ _services = ["multipathd"]
+ _partitionable = True
+ _isDisk = True
+@@ -3990,7 +3990,7 @@ class LoopDevice(StorageDevice):
+ class iScsiDiskDevice(DiskDevice, NetworkStorageDevice):
+ """ An iSCSI disk. """
+ _type = "iscsi"
+- _packages = ["iscsi-initiator-utils", "dracut-network"]
++ _packages = ["open-iscsi"]
+
+ def __init__(self, device, **kwargs):
+ self.node = kwargs.pop("node")
+@@ -4055,7 +4055,7 @@ class iScsiDiskDevice(DiskDevice, NetworkStorageDevice):
+ class FcoeDiskDevice(DiskDevice, NetworkStorageDevice):
+ """ An FCoE disk. """
+ _type = "fcoe"
+- _packages = ["fcoe-utils", "dracut-network"]
++ _packages = ["fcoe-utils"]
+
+ def __init__(self, device, **kwargs):
+ self.nic = kwargs.pop("nic")
+@@ -4227,7 +4227,7 @@ class DASDDevice(DiskDevice):
+ class NFSDevice(StorageDevice, NetworkStorageDevice):
+ """ An NFS device """
+ _type = "nfs"
+- _packages = ["dracut-network"]
++ _packages = []
+
+ def __init__(self, device, format=None, parents=None):
+ # we could make host/ip, path, &c but will anything use it?
+diff --git a/blivet/formats/fs.py b/blivet/formats/fs.py
+index 103717e..a03d3b6 100644
+--- a/blivet/formats/fs.py
++++ b/blivet/formats/fs.py
+@@ -1153,7 +1153,7 @@ class ReiserFS(FS):
+ _supported = False
+ _dump = True
+ _check = True
+- _packages = ["reiserfs-utils"]
++ _packages = ["reiserfsprogs"]
+ _infofs = "debugreiserfs"
+ _defaultInfoOptions = []
+ _existingSizeFields = ["Count of blocks on the device:", "Blocksize:"]
+@@ -1255,7 +1255,7 @@ class HFSPlus(FS):
+ _udevTypes = ["hfsplus"]
+ _mkfs = "mkfs.hfsplus"
+ _fsck = "fsck.hfsplus"
+- _packages = ["hfsplus-tools"]
++ _packages = ["hfsutils"]
+ _formattable = True
+ _mountType = "hfsplus"
+ _minSize = 1
+diff --git a/blivet/formats/luks.py b/blivet/formats/luks.py
+index 8f9ae7b..0eea209 100644
+--- a/blivet/formats/luks.py
++++ b/blivet/formats/luks.py
+@@ -49,7 +49,7 @@ class LUKS(DeviceFormat):
+ _formattable = True # can be formatted
+ _supported = False # is supported
+ _linuxNative = True # for clearpart
+- _packages = ["cryptsetup-luks"] # required packages
++ _packages = ["cryptsetup"] # required packages
+ _minSize = crypto.LUKS_METADATA_SIZE
+
+ def __init__(self, *args, **kwargs):
+diff --git a/blivet/formats/multipath.py b/blivet/formats/multipath.py
+index 2d6a5f3..b5c808b 100644
+--- a/blivet/formats/multipath.py
++++ b/blivet/formats/multipath.py
+@@ -39,7 +39,7 @@ class MultipathMember(DeviceFormat):
+ _formattable = False # can be formatted
+ _supported = True # is supported
+ _linuxNative = False # for clearpart
+- _packages = ["device-mapper-multipath"] # required packages
++ _packages = ["multipath-tools"] # required packages
+ _resizable = False # can be resized
+ _maxSize = 0 # maximum size in MB
+ _minSize = 0 # minimum size in MB
+diff --git a/blivet/platform.py b/blivet/platform.py
+index 31c4f50..f5d4dda 100644
+--- a/blivet/platform.py
++++ b/blivet/platform.py
+@@ -129,7 +129,7 @@ class Platform(object):
+ def packages (self):
+ _packages = self._packages
+ if flags.boot_cmdline.get('fips', None) == '1':
+- _packages.append('dracut-fips')
++ _packages.append('sys-kernel/dracut')
+ return _packages
+
+ def setDefaultPartitioning(self):
+@@ -211,7 +211,7 @@ class MacEFI(EFI):
+ _boot_stage1_format_types = ["macefi"]
+ _boot_efi_description = N_("Apple EFI Boot Partition")
+ _non_linux_format_types = ["macefi"]
+- _packages = ["mactel-boot"]
++ _packages = []
+
+ def setDefaultPartitioning(self):
+ ret = Platform.setDefaultPartitioning(self)
+@@ -276,7 +276,7 @@ class PS3(PPC):
+ pass
+
+ class S390(Platform):
+- _packages = ["s390utils"]
++ _packages = ["sys-apps/s390-tools"]
+ _disklabel_types = ["msdos", "dasd"]
+ _boot_stage1_device_types = ["disk", "partition"]
+ _boot_dasd_description = N_("DASD")
+--
+1.9.2
+
diff --git a/dev-python/python-blivet/files/0001-devices-enable-UUID-for-dm-based-devices-in-fstab.patch b/dev-python/python-blivet/files/0001-devices-enable-UUID-for-dm-based-devices-in-fstab.patch
new file mode 100644
index 00000000..5b795345
--- /dev/null
+++ b/dev-python/python-blivet/files/0001-devices-enable-UUID-for-dm-based-devices-in-fstab.patch
@@ -0,0 +1,28 @@
+From f026c2980c7c82599427645f7cd36e18bc02536f Mon Sep 17 00:00:00 2001
+From: Fabio Erculiani <lxnay@sabayon.org>
+Date: Sun, 11 May 2014 21:18:37 +0100
+Subject: [PATCH] devices: enable UUID= for dm-based devices in fstab
+
+---
+ blivet/devices.py | 5 -----
+ 1 file changed, 5 deletions(-)
+
+diff --git a/blivet/devices.py b/blivet/devices.py
+index 137a61b..714c849 100644
+--- a/blivet/devices.py
++++ b/blivet/devices.py
+@@ -1820,11 +1820,6 @@ class DMDevice(StorageDevice):
+ return d
+
+ @property
+- def fstabSpec(self):
+- """ Return the device specifier for use in /etc/fstab. """
+- return self.path
+-
+- @property
+ def mapName(self):
+ """ This device's device-mapper map name """
+ return self.name
+--
+1.9.2
+
diff --git a/dev-python/python-blivet/files/python-blivet-commit-to-disk-settle.patch b/dev-python/python-blivet/files/python-blivet-commit-to-disk-settle.patch
new file mode 100644
index 00000000..17de6606
--- /dev/null
+++ b/dev-python/python-blivet/files/python-blivet-commit-to-disk-settle.patch
@@ -0,0 +1,12 @@
+diff --git a/blivet/formats/disklabel.py b/blivet/formats/disklabel.py
+index 5015548..9071596 100644
+--- a/blivet/formats/disklabel.py
++++ b/blivet/formats/disklabel.py
+@@ -304,6 +304,7 @@ class DiskLabel(DeviceFormat):
+ raise DiskLabelCommitError(msg)
+ else:
+ self.updateOrigPartedDisk()
++ udev_settle()
+
+ def addPartition(self, *args, **kwargs):
+ partition = kwargs.get("partition", None)
diff --git a/dev-python/python-blivet/files/python-blivet-udev-path.patch b/dev-python/python-blivet/files/python-blivet-udev-path.patch
new file mode 100644
index 00000000..013080b8
--- /dev/null
+++ b/dev-python/python-blivet/files/python-blivet-udev-path.patch
@@ -0,0 +1,11 @@
+--- a/blivet/pyudev.py
++++ b/blivet/pyudev.py
+@@ -9,7 +9,7 @@ from ctypes import CDLL, c_char_p, c_int
+ # XXX this one may need some tweaking...
+ def find_library(name, somajor=0):
+ env = os.environ.get("LD_LIBRARY_PATH")
+- common = ["/lib64", "/lib"]
++ common = ["/lib64", "/lib", "/usr/lib64", "/usr/lib"]
+
+ if env:
+ libdirs = env.split(":") + common
diff --git a/dev-python/python-blivet/files/python-blivet-workaround-disable-multipath.patch b/dev-python/python-blivet/files/python-blivet-workaround-disable-multipath.patch
new file mode 100644
index 00000000..0102e10d
--- /dev/null
+++ b/dev-python/python-blivet/files/python-blivet-workaround-disable-multipath.patch
@@ -0,0 +1,9 @@
+--- a/blivet/devicelibs/mpath.py
++++ b/blivet/devicelibs/mpath.py
+@@ -11,4 +11,5 @@ def flush_mpaths():
+ log.error("multipath: some devices could not be flushed")
+
+ def is_multipath_member(path):
+- return (util.run_program(["multipath", "-c", path]) == 0)
++ return False
++ # return (util.run_program(["multipath", "-c", path]) == 0)
diff --git a/dev-python/python-blivet/metadata.xml b/dev-python/python-blivet/metadata.xml
new file mode 100644
index 00000000..de483c53
--- /dev/null
+++ b/dev-python/python-blivet/metadata.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>python</herd>
+</pkgmetadata>
diff --git a/dev-python/python-blivet/python-blivet-0.23.9-r3.ebuild b/dev-python/python-blivet/python-blivet-0.23.9-r3.ebuild
new file mode 100644
index 00000000..db930029
--- /dev/null
+++ b/dev-python/python-blivet/python-blivet-0.23.9-r3.ebuild
@@ -0,0 +1,55 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="5"
+SUPPORT_PYTHON_ABIS="1"
+
+inherit eutils distutils
+
+REAL_PN="${PN/python-}"
+
+DESCRIPTION="python module for examining and modifying storage configuration."
+HOMEPAGE="https://fedoraproject.org/wiki/Blivet"
+SRC_URI="https://github.com/Sabayon/${REAL_PN}/archive/${REAL_PN}-${PV}-1.tar.gz"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND=">=dev-util/pykickstart-1.99.22
+ >=sys-apps/util-linux-2.15.1
+ >=sys-block/parted-1.8.1
+ sys-fs/cryptsetup
+ >=dev-python/python-cryptsetup-0.1.1
+ sys-fs/mdadm
+ sys-fs/dosfstools
+ >=sys-fs/e2fsprogs-1.41.0
+ sys-fs/btrfs-progs
+ >=dev-python/pyblock-0.45
+ sys-fs/multipath-tools
+ sys-process/lsof
+ "
+DEPEND="${RDEPEND}"
+
+S="${WORKDIR}/${REAL_PN}-${REAL_PN}-${PV}-1"
+
+src_prepare() {
+ # libudev in Gentoo is in /usr/lib64 if systemd
+ epatch "${FILESDIR}/${PN}-udev-path.patch"
+
+ # multipath -c hangs on x86 due to a libc bug
+ # Temporarily disable this
+ use x86 && epatch "${FILESDIR}/${PN}-workaround-disable-multipath.patch"
+
+ # Fix package names
+ epatch "${FILESDIR}/0001-Update-package-names-to-reflect-Gentoo-ones.patch"
+ # enable UUID= support for dm-based devices (dmcrypt, md, etc)
+ epatch "${FILESDIR}/0001-devices-enable-UUID-for-dm-based-devices-in-fstab.patch"
+
+ # Sabayon: commitToDisk should wait on udev. There is a missing udev_settle() call.
+ epatch "${FILESDIR}/${PN}-commit-to-disk-settle.patch"
+
+ distutils_src_prepare
+}