/[gentoo-x86]/sys-fs/btrfs-progs/btrfs-progs-0.19-r3.ebuild
Gentoo

Contents of /sys-fs/btrfs-progs/btrfs-progs-0.19-r3.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.9 - (show annotations) (download)
Fri May 11 14:15:00 2012 UTC (2 years, 5 months ago) by lavajoe
Branch: MAIN
CVS Tags: HEAD
Changes since 1.8: +2 -4 lines
Revert homepage (it is back to original now)

(Portage version: 2.1.10.57/cvs/Linux x86_64)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sys-fs/btrfs-progs/btrfs-progs-0.19-r3.ebuild,v 1.8 2012/04/09 13:04:05 lavajoe Exp $
4
5 inherit eutils
6
7 DESCRIPTION="Btrfs filesystem utilities"
8 HOMEPAGE="https://btrfs.wiki.kernel.org"
9 SRC_URI="mirror://gentoo/${P}.tar.bz2
10 mirror://gentoo/${P}-redhat.patch.bz2"
11
12 LICENSE="GPL-2"
13 SLOT="0"
14 KEYWORDS="amd64 ~arm ~mips ~ppc ~ppc64 x86"
15 IUSE="acl debug-utils"
16
17 DEPEND="sys-libs/zlib
18 debug-utils? ( dev-python/matplotlib )
19 acl? (
20 sys-apps/acl
21 sys-fs/e2fsprogs
22 )"
23 RDEPEND="${DEPEND}"
24
25 src_unpack() {
26 unpack ${A}
27 cd "${S}"
28
29 # Apply patch from Josef Bacik (btrfs developer at RedHat)
30 # that brings version 0.19 up to the version used in RedHat/Fedora.
31 # Includes the previous convert-remove-used-space-update patch.
32 # Also includes the "-D" option in btrfsctl (bug #331121).
33 epatch "${WORKDIR}"/${P}-redhat.patch
34
35 epatch "${FILESDIR}"/${P}-glibc212.patch
36
37 # Fix underlinking (bug #369451): add -lcom_err when linking "convert"
38 epatch "${FILESDIR}"/${P}-fix-underlinking.patch
39
40 # Fix hardcoded "gcc" and "make"
41 sed -i -e 's:gcc $(CFLAGS):$(CC) $(CFLAGS):' Makefile
42 sed -i -e 's:make:$(MAKE):' Makefile
43 }
44
45 src_compile() {
46 emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" \
47 all || die
48 emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" \
49 btrfstune btrfs-image || die
50 if use acl; then
51 emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" \
52 convert || die
53 fi
54 }
55
56 src_install() {
57 into /
58 dosbin btrfs
59 dosbin btrfs-show
60 dosbin btrfs-vol
61 dosbin btrfsctl
62 dosbin btrfsck
63 dosbin btrfstune
64 dosbin btrfs-image
65 # fsck will segfault if invoked at boot, so do not make this link
66 #dosym btrfsck /sbin/fsck.btrfs
67 newsbin mkfs.btrfs mkbtrfs
68 dosym mkbtrfs /sbin/mkfs.btrfs
69 if use acl; then
70 dosbin btrfs-convert
71 else
72 ewarn "Note: btrfs-convert not built/installed (requires acl USE flag)"
73 fi
74
75 if use debug-utils; then
76 dobin btrfs-debug-tree
77 else
78 ewarn "Note: btrfs-debug-tree not installed (requires debug-utils USE flag)"
79 fi
80
81 into /usr
82 newbin bcp btrfs-bcp
83
84 if use debug-utils; then
85 newbin show-blocks btrfs-show-blocks
86 else
87 ewarn "Note: btrfs-show-blocks not installed (requires debug-utils USE flag)"
88 fi
89
90 dodoc INSTALL
91 emake prefix="${D}/usr/share" install-man
92 }
93
94 pkg_postinst() {
95 ewarn "WARNING: This version of btrfs-progs corresponds to and should only"
96 ewarn " be used with the version of btrfs included in the"
97 ewarn " Linux kernel (2.6.31 and above)."
98 ewarn ""
99 ewarn " This version should NOT be used with earlier versions"
100 ewarn " of the standalone btrfs module!"
101 }

  ViewVC Help
Powered by ViewVC 1.1.20