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-devel/patch/patch-2.6.1.ebuild,v 1.11 2012/01/25 18:25:49 ssuominen Exp $ |
4 |
|
5 |
inherit flag-o-matic |
6 |
|
7 |
DESCRIPTION="Utility to apply diffs to files" |
8 |
HOMEPAGE="http://www.gnu.org/software/patch/patch.html" |
9 |
SRC_URI="mirror://gnu/patch/${P}.tar.bz2" |
10 |
|
11 |
LICENSE="GPL-2" |
12 |
SLOT="0" |
13 |
KEYWORDS="alpha amd64 arm hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd" |
14 |
IUSE="static test" |
15 |
|
16 |
RDEPEND="" |
17 |
DEPEND="${RDEPEND} |
18 |
test? ( sys-apps/ed )" |
19 |
|
20 |
src_unpack() { |
21 |
unpack ${A} |
22 |
cd "${S}" |
23 |
# this file is missing from the tarball bug #300845 |
24 |
cp "${FILESDIR}"/gnulib_strnlen.c gl/lib/strnlen.c || die |
25 |
} |
26 |
|
27 |
src_compile() { |
28 |
use static && append-ldflags -static |
29 |
|
30 |
local myconf="" |
31 |
[[ ${USERLAND} != "GNU" ]] && myconf="--program-prefix=g" |
32 |
econf ${myconf} |
33 |
|
34 |
emake || die |
35 |
} |
36 |
|
37 |
src_install() { |
38 |
emake DESTDIR="${D}" install || die |
39 |
dodoc AUTHORS ChangeLog NEWS README |
40 |
} |