Magellan Linux

Contents of /trunk/core/iproute2/iproute2-3.2.0-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 10127 - (show annotations) (download)
Tue Jan 17 09:55:26 2012 UTC (12 years, 5 months ago) by niro
File size: 1434 byte(s)
-removed deprecated patches
1 # $Id$
2
3 PNAME="iproute2"
4 PVER="3.2.0"
5 PBUILD="r1"
6
7 PCAT="sys-apps"
8
9 DESCRIPTION="Collection of utilities for controlling TCP/IP networking and Traffic Control."
10 HOMEPAGE="http://linux-net.osdl.org/index.php/Iproute2"
11
12 # arpd needs db
13 DEPEND=">= dev-db/db-5.3
14 >= net-misc/iptables-1.4"
15
16 SDEPEND=">= virtual/kernel-headers
17 >= sys-apps/sed-4"
18
19 # get the right pver
20 if [[ ${PVER} != ${PVER%.*.*.*} ]]
21 then
22 MYPVER="${PVER%.*}-${PVER##*.}"
23 else
24 MYPVER="${PVER}"
25 fi
26
27 SRCFILE="${PNAME}-${MYPVER}.tar.xz"
28 SRCDIR="${BUILDDIR}/${PNAME}-${MYPVER}"
29
30 sminclude mbuild
31
32 SRC_URI=(
33 http://www.kernel.org/pub/linux/utils/net/${PNAME}/${SRCFILE}
34 http://devresources.linux-foundation.org/dev/${PNAME}/download/${SRCFILE}
35 http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/distfiles/${SRCFILE}
36 mirror://${PNAME}/${SRCFILE}
37 )
38
39 UP2DATE="updatecmd 'http://www.kernel.org/pub/linux/utils/net/${PNAME}/?C=M;O=A' | lasttarball xz"
40
41 src_prepare()
42 {
43 munpack ${SRCFILE} || die
44 cd ${SRCDIR}
45
46 # fix cflags
47 sed -i "s:-O2:${CFLAGS}:" Makefile || die
48
49 # fix libdir
50 sed -i "/^LIBDIR/s:=.*:=/$(mlibdir):" Makefile || die
51 }
52
53 src_compile()
54 {
55 cd ${SRCDIR}
56 mmake IPT_LIB_DIR=$(pkg-config xtables --variable=xtlibdir) SBINDIR=/sbin || die
57 }
58
59 src_install()
60 {
61 cd ${SRCDIR}
62 make DESTDIR=${BINDIR} \
63 DOCDIR=/usr/share/doc/${PNAME}-${PVER} \
64 MANDIR=/usr/share/man \
65 SBINDIR=/sbin install || die
66 minstalldocs ABOUT-NLS COPYING README* TODO || die
67 }