summaryrefslogtreecommitdiff
blob: 8e26b30cfde6842405311808c0a8201274c327c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-fs/mtd-utils/mtd-utils-9999.ebuild,v 1.1 2007/12/27 21:13:10 vapier Exp $

ECVS_USER="anoncvs"
ECVS_PASS="anoncvs"
ECVS_SERVER="cvs.infradead.org:/home/cvs"
ECVS_MODULE="mtd"
inherit toolchain-funcs flag-o-matic cvs

DESCRIPTION="MTD userspace tools"
HOMEPAGE="http://sources.redhat.com/jffs2/"
SRC_URI=""

LICENSE="GPL-2"
SLOT="0"
KEYWORDS=""
IUSE=""

S=${WORKDIR}/mtd/util

DEPEND="!sys-fs/mtd
	sys-libs/zlib"

src_unpack() {
	cvs_src_unpack
	sed -i \
		-e 's!^MANDIR.*!MANDIR = /usr/share/man!g' \
		-e 's!-include.*!!g' \
		"${S}"/Makefile
}

src_compile() {
	emake \
		CFLAGS="${CFLAGS} -I../include -Wall" \
		LDFLAGS="${LDFLAGS}" \
		CC="$(tc-getCC)" \
		DESTDIR="${D}" \
		|| die
}

src_install() {
	emake install DESTDIR="${D}" || die
	rm -r "${D}"/usr/include || die
	dodoc *.txt
}