summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoe Peterson <lavajoe@gentoo.org>2011-06-05 16:34:06 +0000
committerJoe Peterson <lavajoe@gentoo.org>2011-06-05 16:34:06 +0000
commit6688973f6b101e7729a832c39efdeff17bd1e30e (patch)
tree1176f9f6f9d29c7b27e1ea07098105db37de24d9
parentPackages, depending on <ghc-6.10 were removed from the tree. Removed masks. (diff)
downloadgentoo-2-6688973f6b101e7729a832c39efdeff17bd1e30e.tar.gz
gentoo-2-6688973f6b101e7729a832c39efdeff17bd1e30e.tar.bz2
gentoo-2-6688973f6b101e7729a832c39efdeff17bd1e30e.zip
Fix underlinking (bug #369451)
(Portage version: 2.1.9.48/cvs/Linux x86_64)
-rw-r--r--sys-fs/btrfs-progs/ChangeLog10
-rw-r--r--sys-fs/btrfs-progs/btrfs-progs-0.19-r3.ebuild100
-rw-r--r--sys-fs/btrfs-progs/files/btrfs-progs-0.19-fix-underlinking.patch11
3 files changed, 119 insertions, 2 deletions
diff --git a/sys-fs/btrfs-progs/ChangeLog b/sys-fs/btrfs-progs/ChangeLog
index 5df60dabb49c..6c9ee80b80cc 100644
--- a/sys-fs/btrfs-progs/ChangeLog
+++ b/sys-fs/btrfs-progs/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for sys-fs/btrfs-progs
-# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-fs/btrfs-progs/ChangeLog,v 1.32 2010/11/07 22:49:51 lavajoe Exp $
+# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/sys-fs/btrfs-progs/ChangeLog,v 1.33 2011/06/05 16:34:06 lavajoe Exp $
+
+*btrfs-progs-0.19-r3 (05 Jun 2011)
+
+ 05 Jun 2011; Joe Peterson <lavajoe@gentoo.org> +btrfs-progs-0.19-r3.ebuild,
+ +files/btrfs-progs-0.19-fix-underlinking.patch:
+ Fix underlinking (bug #369451)
*btrfs-progs-0.19-r2 (07 Nov 2010)
diff --git a/sys-fs/btrfs-progs/btrfs-progs-0.19-r3.ebuild b/sys-fs/btrfs-progs/btrfs-progs-0.19-r3.ebuild
new file mode 100644
index 000000000000..b01409f3aaeb
--- /dev/null
+++ b/sys-fs/btrfs-progs/btrfs-progs-0.19-r3.ebuild
@@ -0,0 +1,100 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-fs/btrfs-progs/btrfs-progs-0.19-r3.ebuild,v 1.1 2011/06/05 16:34:06 lavajoe Exp $
+
+inherit eutils
+
+DESCRIPTION="Btrfs filesystem utilities"
+HOMEPAGE="http://btrfs.wiki.kernel.org/"
+SRC_URI="http://www.kernel.org/pub/linux/kernel/people/mason/btrfs/${P}.tar.bz2
+ mirror://gentoo/${P}-redhat.patch.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ppc64 ~x86"
+IUSE="acl debug-utils"
+
+DEPEND="debug-utils? ( dev-python/matplotlib )
+ acl? (
+ sys-apps/acl
+ sys-fs/e2fsprogs
+ )"
+RDEPEND="${DEPEND}"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+
+ # Apply patch from Josef Bacik (btrfs developer at RedHat)
+ # that brings version 0.19 up to the version used in RedHat/Fedora.
+ # Includes the previous convert-remove-used-space-update patch.
+ # Also includes the "-D" option in btrfsctl (bug #331121).
+ epatch "${WORKDIR}"/${P}-redhat.patch
+
+ epatch "${FILESDIR}"/${P}-glibc212.patch
+
+ # Fix underlinking (bug #369451): add -lcom_err when linking "convert"
+ epatch "${FILESDIR}"/${P}-fix-underlinking.patch
+
+ # Fix hardcoded "gcc" and "make"
+ sed -i -e 's:gcc $(CFLAGS):$(CC) $(CFLAGS):' Makefile
+ sed -i -e 's:make:$(MAKE):' Makefile
+}
+
+src_compile() {
+ emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" \
+ all || die
+ emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" \
+ btrfstune btrfs-image || die
+ if use acl; then
+ emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" \
+ convert || die
+ fi
+}
+
+src_install() {
+ into /
+ dosbin btrfs
+ dosbin btrfs-show
+ dosbin btrfs-vol
+ dosbin btrfsctl
+ dosbin btrfsck
+ dosbin btrfstune
+ dosbin btrfs-image
+ # fsck will segfault if invoked at boot, so do not make this link
+ #dosym btrfsck /sbin/fsck.btrfs
+ newsbin mkfs.btrfs mkbtrfs
+ dosym mkbtrfs /sbin/mkfs.btrfs
+ if use acl; then
+ dosbin btrfs-convert
+ else
+ ewarn "Note: btrfs-convert not built/installed (requires acl USE flag)"
+ fi
+
+ if use debug-utils; then
+ dobin btrfs-debug-tree
+ else
+ ewarn "Note: btrfs-debug-tree not installed (requires debug-utils USE flag)"
+ fi
+
+ into /usr
+ newbin bcp btrfs-bcp
+
+ if use debug-utils; then
+ newbin show-blocks btrfs-show-blocks
+ else
+ ewarn "Note: btrfs-show-blocks not installed (requires debug-utils USE flag)"
+ fi
+
+ dodoc INSTALL
+ emake prefix="${D}/usr/share" install-man
+}
+
+pkg_postinst() {
+ ewarn "WARNING: This version of btrfs-progs corresponds to and should only"
+ ewarn " be used with the version of btrfs included in the"
+ ewarn " Linux kernel (2.6.31 and above)."
+ ewarn ""
+ ewarn " This version should NOT be used with earlier versions"
+ ewarn " of the standalone btrfs module!"
+}
diff --git a/sys-fs/btrfs-progs/files/btrfs-progs-0.19-fix-underlinking.patch b/sys-fs/btrfs-progs/files/btrfs-progs-0.19-fix-underlinking.patch
new file mode 100644
index 000000000000..38a0a18dbc61
--- /dev/null
+++ b/sys-fs/btrfs-progs/files/btrfs-progs-0.19-fix-underlinking.patch
@@ -0,0 +1,11 @@
+--- btrfs-progs-0.19/Makefile~ 2011-06-05 10:21:04.000000000 -0600
++++ btrfs-progs-0.19/Makefile 2011-06-05 10:21:46.000000000 -0600
+@@ -75,7 +75,7 @@ quick-test: $(objects) quick-test.o
+ gcc $(CFLAGS) -o quick-test $(objects) quick-test.o $(LDFLAGS) $(LIBS)
+
+ convert: $(objects) convert.o
+- gcc $(CFLAGS) -o btrfs-convert $(objects) convert.o -lext2fs $(LDFLAGS) $(LIBS)
++ gcc $(CFLAGS) -o btrfs-convert $(objects) convert.o -lext2fs -lcom_err $(LDFLAGS) $(LIBS)
+
+ ioctl-test: $(objects) ioctl-test.o
+ gcc $(CFLAGS) -o ioctl-test $(objects) ioctl-test.o $(LDFLAGS) $(LIBS)