summaryrefslogtreecommitdiff
blob: aaa41483fb5c8476496519ef9371186156a66462 (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
47
48
49
50
51
52
53
54
55
56
57
# Copyright 1999-2000 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License, v2 or later
# Author Daniel Robbins <drobbins@gentoo.org>
# $Header: /var/cvsroot/gentoo-x86/sys-apps/util-linux/util-linux-2.11g.ebuild,v 1.1 2001/07/10 06:46:44 drobbins Exp $

S=${WORKDIR}/${P}
DESCRIPTION="Various useful Linux utilities"
SRC_URI="ftp://ftp.win.tue.nl/pub/linux-local/utils/util-linux/${P}.tar.gz"

DEPEND="virtual/glibc >=sys-libs/ncurses-5.2-r2"

RDEPEND="$DEPEND
	 sys-devel/perl"

src_unpack() {

    unpack ${P}.tar.gz
    cd ${S}
    cp MCONFIG MCONFIG.orig
    sed -e "s:-pipe -O2 $(CPUOPT) -fomit-frame-pointer:${CFLAGS}:" \
        -e "s:CPU=.*:CPU=${CHOST%%-*}:" \
        -e "s:HAVE_PAM=no:HAVE_PAM=yes:" \
	-e "s:HAVE_SLN=no:HAVE_SLN=yes:" \
	-e "s:HAVE_TSORT=no:HAVE_TSORT=yes:" \
        -e "s:usr/man:usr/share/man:" \
        -e "s:usr/info:usr/share/info:" \
	MCONFIG.orig > MCONFIG.orig2
     if [ "`use simpleinit`" ]
     then
	sed -e "s:HAVE_SYSVINIT=yes:HAVE_SYSVINIT=no:" \
	    -e "s:HAVE_SYSVINIT_UTILS=yes:HAVE_SYSVINIT_UTILS=no:" \
	MCONFIG.orig2 > MCONFIG
     else
        mv MCONFIG.orig2 MCONFIG
     fi

}

src_compile() {

	try ./configure
	try make ${MAKEOPTS} LDFLAGS=\"\"
}


src_install() {

	try make DESTDIR=${D} install

	dodoc HISTORY MAINTAINER README VERSION
	docinto licenses
	dodoc licenses/* HISTORY
	docinto examples
	dodoc example.files/*
}